Skip to content

Commit

Permalink
Added dynamically set url and port for backend
Browse files Browse the repository at this point in the history
Build fixes
  • Loading branch information
Curtis Gray committed May 27, 2024
1 parent cfe0330 commit 645be00
Show file tree
Hide file tree
Showing 27 changed files with 509 additions and 269 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ wingman_history*.json
*.db
build
llama.log
.npm

ux/server/wingman/Windows
ux/server/wingman/Linux
Expand Down
14 changes: 9 additions & 5 deletions admin/build-ux-ci.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ param(
[switch]$Force,

[Parameter(Mandatory = $false)]
[switch]$SkipDeployment,
[switch]$SkipCopyTo,

[Parameter(Mandatory = $false)]
[switch]$SkipNpmInstall
Expand Down Expand Up @@ -78,15 +78,19 @@ try {
throw "npm run build failed"
}

if ($SkipDeployment) {
Write-Warning "Skipping deployment..."
if ($SkipCopyTo) {
Write-Warning "Skipping copy to destination..."
}
else {
# Copy the dist folder to wingman.cpp if the ../services/wingman.cpp/wingman folder exists
$distRoot = "../services/wingman.cpp/wingman"
$newDestination = Join-Path $distRoot "distadmin"
if (Test-Path $distRoot) {
Write-Host "Copying dist folder to wingman.cpp..."
Copy-Item -Recurse -Force -ErrorAction SilentlyContinue ./dist ../services/wingman.cpp/wingman/distadmin
Write-Host "Copying dist [admin] folder to wingman.cpp..."
if (Test-Path $newDestination) {
Remove-Item -Recurse -Force $newDestination # Delete the entire folder if it exists
}
Copy-Item -Recurse -Force -ErrorAction SilentlyContinue -Path ./dist -Destination $newDestination
}
else {
Write-Warning "wingman.cpp folder not found. Skipping copy of dist folder..."
Expand Down
125 changes: 124 additions & 1 deletion admin/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 7 additions & 3 deletions admin/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,19 +12,23 @@
},
"license": "MIT",
"dependencies": {
"@headlessui/react": "^1.7.18",
"@tabler/icons-react": "^2.9.0",
"react": "^18.2.0",
"react-copy-to-clipboard": "^5.1.0",
"react-dom": "^18.2.0"
},
"devDependencies": {
"@types/react": "^18.2.7",
"@types/react-copy-to-clipboard": "^5.0.7",
"@types/react-dom": "^18.2.4",
"@vitejs/plugin-react": "^4.2.1",
"babel-preset-nano-react-app": "^0.1.0",
"tailwindcss": "^3.4.3",
"typescript": "^5.0.4",
"vite": "^5.2.11",
"vite-tsconfig-paths": "^4.2.0",
"vite-plugin-top-level-await": "^1.4.1",
"vite-plugin-wasm": "^3.3.0"
"vite-plugin-wasm": "^3.3.0",
"vite-tsconfig-paths": "^4.2.0"
}
}
}
Loading

0 comments on commit 645be00

Please sign in to comment.