Doskey (CMD Aliases)
October 16, 2023
# make a shorter-to-type copy available
doskey mm="C:\apps\micromamba\condabin\micromamba.bat" $*
reg add "hkcu\Software\Microsoft\Command Processor" /v AutoRun /d "(C:\apps\micromamba\condabin\mamba_hook.bat) & (doskey /macrofile=c:\bin\aliases_doskey.txt)"
The AutoRun value is the command line to run. You could simply append another command using the & operator.
Result:
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\Microsoft\Command Processor]
"AutoRun"="(\"C:\\apps\\micromamba\\condabin\\mamba_hook.bat\") & (doskey /macrofile=c:\\bin\\aliases_doskey.txt)"
Doskey aliases file:
https://github.com/maphew/mhwcode/blob/master/other/aliases_doskey.txt