Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improvements to environment template #1701

Merged
merged 3 commits into from
Mar 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions Bonsai.Templates/Bonsai.EnvironmentTemplate/.bonsai/Setup.cmd
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
@echo off
pushd %~dp0
powershell -ExecutionPolicy Bypass -File ./Setup.ps1
popd
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
Push-Location $PSScriptRoot
if (!(Test-Path "./Bonsai.exe")) {
$release = "https://github.com/bonsai-rx/bonsai/releases/latest/download/Bonsai.zip"
$configPath = "./Bonsai.config"
Expand All @@ -10,10 +11,11 @@ if (!(Test-Path "./Bonsai.exe")) {
}
}
Invoke-WebRequest $release -OutFile "temp.zip"
Move-Item -Path "NuGet.config" "temp.config"
Move-Item -Path "NuGet.config" "temp.config" -ErrorAction SilentlyContinue
Expand-Archive "temp.zip" -DestinationPath "." -Force
Move-Item -Path "temp.config" "NuGet.config" -Force
Move-Item -Path "temp.config" "NuGet.config" -Force -ErrorAction SilentlyContinue
Remove-Item -Path "temp.zip"
Remove-Item -Path "Bonsai32.exe"
}
& .\Bonsai.exe --no-editor
& .\Bonsai.exe --no-editor
Pop-Location
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,13 @@
}],
"args": {
"executable": "powershell",
"args": "-File Setup.ps1",
"args": "-File .bonsai/Setup.ps1",
"redirectStandardOutput": false
}
},
"applyFileRenamesToArgs": [ "args" ]
}],
"sourceName": ".bonsai",
"defaultName": ".bonsai",
"shortName": "bonsaienv",
"preferNameDirectory": true
"preferDefaultName": true
}
1 change: 0 additions & 1 deletion Bonsai.Templates/Bonsai.EnvironmentTemplate/Setup.cmd

This file was deleted.

2 changes: 1 addition & 1 deletion Bonsai.Templates/Bonsai.Templates.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<PackageType>Template</PackageType>
<PackageVersion>2.8.0</PackageVersion>
<PackageVersion>2.8.1</PackageVersion>
<PackageId>Bonsai.Templates</PackageId>
<Title>Bonsai Templates</Title>
<Authors>Bonsai</Authors>
Expand Down
Loading