revert unnecessary changes.#3096
Conversation
|
@daxgames Thank you for the clean PR to fix my mistake 🙏🏻 The |
|
|
||
| :: Check if Clink is not present | ||
| if not exist "%CMDER_ROOT%\vendor\clink\clink_%clink_architecture%.exe" ( | ||
| %print_error% "Clink executable is not present in 'vendor\clink\clink_%clink_architecture%.exe'" |
There was a problem hiding this comment.
@daxgames Assuming the Cmder directory content hasn't changed, correct?
Also, I'm considering whether the if branch in batch causes slow downs, if it does, I need to pay more attention to usages like this in other places as well
| :: Cleanup legacy Clink Settings file | ||
| if exist "%CMDER_CONFIG_DIR%\settings" if exist "%CMDER_CONFIG_DIR%\clink_settings" ( | ||
| del "%CMDER_CONFIG_DIR%\settings" | ||
| ) | ||
|
|
||
| :: Cleanup legacy Clink history file | ||
| if exist "%CMDER_CONFIG_DIR%\.history" if exist "%CMDER_CONFIG_DIR%\clink_history" ( | ||
| del "%CMDER_CONFIG_DIR%\.history" | ||
| ) | ||
|
|
There was a problem hiding this comment.
@daxgames These legacy clean ups are one time jobs that meant to be executed from init.bat once instead of every time by init_user.cmd, correct?
| :: Add Windows Terminal shell integration support (OSC 133 sequences) | ||
| if defined WT_SESSION (prompt `$e]133;D`$e\`$e]133;A`$e\`$e]9;9;`$P`$e\%PROMPT%`$e]133;B`$e\) |
There was a problem hiding this comment.
@daxgames I think these OSC definitions should be moved before the :CLINK_FINISH and still be kept under :SKIP_CLINK, because Clink shells don't make use of native Windows prompt anyway, so they might add to the unnecessary command execution
There was a problem hiding this comment.
ok - you know more about it than I do.
There was a problem hiding this comment.
Rule of thumb, clink never uses the native Windows prompt.
In fact the prompt <...> command was removed in Cmder circa introduction of Clink, which is excellent. However on platforms where clink wasn't working (e.g. ARM) the native prompt was added as a fallback to avoid making the shell look vanilla instead of our own custom prompt.
It is still useful in my opinion when Clink isn't available, or disabled due to users' preferences.
|
Will come back to this PR later, have to take care of some tasks 🙏🏻 |
|
still cleaning it up - do not merge yet |
| ) else if exist "%GIT_INSTALL_ROOT%\mingw64" ( | ||
| set "git_mingw_bin=%GIT_INSTALL_ROOT%\mingw64\bin" | ||
| ) | ||
| :: TODO: Support for ARM |
There was a problem hiding this comment.
Related ARM for Clink are in #3018, I'm looking forward to getting that merged into development as well, especially with the relevance of more and more ARM machines, like Microsoft's own Surface line
Keeping these here for my own reference
No description provided.