Skip to content

Commit

Permalink
detect if clink initialization failed
Browse files Browse the repository at this point in the history
  • Loading branch information
DRSDavidSoft committed Oct 18, 2022
1 parent c992215 commit 9399cbd
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions vendor/init.bat
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,8 @@ if "%CMDER_CLINK%" == "1" (
if exist "%CMDER_USER_CONFIG%\.history" if exist "%CMDER_USER_CONFIG%\clink_history" (
del "%CMDER_USER_CONFIG%\.history"
)
"%CMDER_ROOT%\vendor\clink\clink_%clink_architecture%.exe" inject --quiet --profile "%CMDER_USER_CONFIG%" --scripts "%CMDER_ROOT%\vendor"

"%CMDER_ROOT%\vendor\clink\clink_%clink_architecture%.exe" inject --quiet --profile "%CMDER_USER_CONFIG%" --scripts "%CMDER_ROOT%\vendor"
) else (
if not exist "%CMDER_ROOT%\config\settings" if not exist "%CMDER_ROOT%\config\clink_settings" (
echo Generating Clink initial settings in "%CMDER_ROOT%\config\clink_settings"
Expand All @@ -194,8 +195,12 @@ if "%CMDER_CLINK%" == "1" (

"%CMDER_ROOT%\vendor\clink\clink_%clink_architecture%.exe" inject --quiet --profile "%CMDER_ROOT%\config" --scripts "%CMDER_ROOT%\vendor"
)

if errorlevel 1 (
%print_error% "Failed to initialize Clink with error code: %errorlevel%"
)
) else (
%print_verbose% "WARNING: Incompatible 'ComSpec/Shell' Detetected Skipping Clink Injection!"
%print_verbose% "WARNING: Incompatible 'ComSpec/Shell' Detetected, Skipping Clink Injection!"
)

if "%CMDER_CONFIGURED%" GTR "1" (
Expand Down

0 comments on commit 9399cbd

Please sign in to comment.