Set history_io=3 in default Clink settings

Currently the "history" command in Cmder prints commands without any index associated with any command, so you can copy/paste a command or use "!!" to execute a command from the history but, unlike BASH, you can't do "!<command_index>".

"cat" has a switch, "-n", which prints line numbers of the file being printed. This, in conjunction with "history_io=3" in Clink settings (to read/write history when editing a command") works just like BASH, i.e., you can use the index printed next to a command in the history to execute that command as "!<command_index>".
This commit is contained in:
Shahzeb Ihsan 2017-03-17 10:59:12 +08:00 committed by GitHub
parent 0a5d1ac156
commit d8444dae97

1
vendor/init.bat vendored
View File

@ -26,6 +26,7 @@ if "%PROCESSOR_ARCHITECTURE%"=="x86" (
:: Tell the user about the clink config files...
if not exist "%CMDER_ROOT%\config\settings" (
set clink.history_io=3
echo Generating clink initial settings in "%CMDER_ROOT%\config\settings"
echo Additional *.lua files in "%CMDER_ROOT%\config" are loaded on startup.
)