cmder
cmder copied to clipboard
alias with && doesn't work
I try to use & for an alias in order to execute more than one command e.g.
λ alias ctest=c: & cd c:\test
But get following error
The system cannot find the path specified.
although it's possible to make an entry in config/aliases that also works
See #632 -- same issue with the shell handling the & before it gets passed to alias.bat. You can use the doskey equivalent $T here:
alias ctest=c: $T cd c:\test
Note that in this case you can also just use the /D option to tell cd to change drives:
alias ctest=cd /D c:\test