|
|
||
Dueling Consoles—Working in Both Windows and GNU/Linux© Copyright Darrell Anderson. Like many people I spend computer time in both Windows and GNU/Linux. I also spend sufficient time in console mode when using both platforms. Unfortunately, the commands used in either world are not the same and occasionally I type a command usable in one operating system but not the other. With only a nominal amount of effort I reduced the disruption caused by these mind burps. I used aliases. Create a command alias in GNU/Linux with the obvious command called alias. Create a command alias in Windows with the not-so-obvious doskey command. As the sole user of my computer boxes I store my GNU/Linux aliases in /etc/bashrc. However, users who do not possess access to modifying global configuration files can just as easily store their aliases in $HOME/.bashrc. My short list looks like this: alias cls="clear"alias copy="cp -i" alias cp="cp -i" alias ifconfig="ifconfig -a" alias mc="mc -d" alias md="mkdir" alias mv="mv -i" alias lo="logout" alias ping="ping -c 3" alias rm="rm -i" alias sd="shutdown -h now" alias vi="vim" alias x="exit" In Windows I configured a doskey batch file that is invoked whenever I open a DOS shell. My short list looks like this: doskey e=editdoskey x=exit doskey d=dir $1 doskey ls=dir $1 doskey alias=doskey /m doskey cat=type $1 doskey cp=copy $1 $2 doskey top=pmon doskey ifconfig=ipconfig /all Just another tip toward working a wee bit more efficiently and with less frustration! Finis. |
||