Skip to content
Draft
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
12 changes: 11 additions & 1 deletion constructor/briefcase/run_installation.bat
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,8 @@ rem Set CONDA_QUIET primarily to disable the spinners
set CONDA_QUIET={{ 0 if add_debug else 1 }}

rem Get the name of the install directory
for %%I in ("%INSTDIR%") do set "APPNAME=%%~nxI"
for %%I in ("%INSTDIR%") do set "DISTRIBUTION_NAME=%%~nxI"
set MENUINST_DISTRIBUTION_NAME=%DISTRIBUTION_NAME%
set "LOG=%INSTDIR%\install.log"

{%- if script_env_variables %}
Expand Down Expand Up @@ -128,6 +129,15 @@ if "%ALLUSERS%"=="0" (
if errorlevel 1 ( exit /b %errorlevel% )
)

rem Persist distribution_name to menuinst.toml before installing packages.
rem This ensures the value is captured even if no packages have shortcuts.
rem Must run before conda install to avoid creating shortcuts twice.
"%CONDA_EXE%" menuinst --install -p "%BASE_PATH%" --root-prefix "%BASE_PATH%"
if errorlevel 1 ( exit /b %errorlevel% )
if not exist "%BASE_PATH%\Menu\menuinst.toml" (
{{ error_block('Failed to initialize shortcut configuration', 14) }}
)

{%- if has_pre_install %}
rem Run user-supplied pre-install script
{%- if has_pre_install_desc %}
Expand Down
Loading