Dear Lifehacker, I’m familiar with the Unix command line on Linux and OS X, but I’ve recently switched to Windows and the Command Prompt (
cmd.exe) feels, well, kind of crappy. How can I make it a bit more useful and user-friendly? Sincerely, Pissed at the Prompt
The Windows Command Prompt certainly isn’t the most friendly terminal around, and if you’re coming from a UNIX background, it can feel like moving from a Ferrari to Fred Flintstone’s car. Luckily, with a few tweaks, you can make the Command Prompt just as user-friendly as any other Terminal. Here’s how to do it.
You’ve probably heard us mention Cygwin before, and we really can’t recommend it enough. It takes the crappy Windows Command Prompt and turns it into the useful UNIX terminal Mac and Linux fans are used to. All the commands you remember from your UNIX days will work in Cygwin beautifully, and you can use UNIX-based scripts and programs (like our very own Gina Trapani’s Todo.sh) just like you can on Linux or OS X. We’ve gone through a more detailed guide to Cygwin before, so I won’t get too deep into it here. I’ll just tell you that your number one job should be installing it, as it’ll make your life so much better.
Install a Different Terminal Program
Cygwin isn’t actually a separate program, as it might appear to be. Instead, its a shell that loads in the regular Command Prompt program. Thus it solves half the problem of the Command Prompt — not having any of the same commands or syntax — but it doesn’t actually solve the other problems inherent to the program itself. If you want better text selection, better copy and paste, window transparency, and other useful features, you’ll want a new Terminal program entirely.
If you’re using Mintty, the best way to install it is through the Cygwin installer. Run the Cygwin installer again and check it off under “Shells” in the “Select Pacakges” screen. Then, you can access it from the Cygwin folder in your Start Menu.
Make Cygwin Your Default Shell (Console Only)
Obviously, if you want the Windows command line, you can still use the original Command Prompt application. Alternatively, if you head to the “Tabs” section of Console’s preferences, you can add a new tab under Tab Name, call it “Windows CMD” (or whatever you want), and set the shell to
%windir%\system32\cmd.exe. You can also change the startup directory to your User folder (e.g.
C:\Users\Whitson), since console will use its program folder by default. Now, when you open a new tab, you can choose to either open a Cygwin tab or a Windows Command Prompt tab, which is pretty convenient.
Tweak Your New Terminal’s Settings
Lastly, be sure to check out our three part guide to Cygwin (you can read through part II here and part III here), as well as our guide to time-saving terminal shortcuts.
P.S. Got any of your own favourite tips for improving the Windows command line? Share them with us in the comments.