Skip to content

Commit 1b10c47

Browse files
authored
Prompt user for AVX version in install.bat (#469)
1 parent 10495eb commit 1b10c47

File tree

1 file changed

+10
-2
lines changed

1 file changed

+10
-2
lines changed

install.bat

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,10 +7,18 @@ if exist "%APPDATA%\nitro" (
77
rmdir /S /Q "%APPDATA%\nitro"
88
)
99

10-
1110
:: Parse arguments
1211
set "VERSION=latest"
1312
set "GPU=false"
13+
set "AVX=-avx2"
14+
15+
echo Please specify the desired AVX version (avx, avx2, avx512), or leave it blank to use the default version (avx2):
16+
set /p USER_AVX=
17+
18+
if not "%USER_AVX%"=="" (
19+
set "AVX=-%USER_AVX%"
20+
)
21+
1422
:arg_loop
1523
if "%~1"=="" goto arg_loop_end
1624
if "%~1"=="--gpu" (
@@ -37,7 +45,7 @@ if "%VERSION%"=="latest" (
3745
)
3846

3947
:: Construct the download URL
40-
set "URL=https://github.com/janhq/nitro/releases/download/v%VERSION%/nitro-%VERSION%-win-amd64"
48+
set "URL=https://github.com/janhq/nitro/releases/download/v%VERSION%/nitro-%VERSION%-win-amd64%AVX%"
4149
if "%GPU%"=="true" (
4250
:: If --gpu option is provided, append -cuda to the URL
4351
set "URL=%URL%-cuda"

0 commit comments

Comments
 (0)