Windows optimize

NirCmd: Take control of Windows at the Command Line

Sometimes you want to modify the Windows user interface, manipulate connected hardware, and create interesting Windows boot-time configurations.

As a systems administrator junkie myself, I really have a huge fondness for the command line. For anyone that has used a UNIX or Linux powered system, the command line is an essential conduit to working the operating system to its fullest potential. Windows also sports a command-line interface which gets the job done well enough, but sometimes you want a little bit more. For example, say you want to modify the Windows user interface, manipulate connected hardware, and create interesting Windows boot-time configurations. There's a small tool out there that delivers surprisingly interesting results for these tasks.

Command line

NirCmd by NirSoft is the ultimate command-line-based Windows task tool. According to the company website for the product, NirCmd can:

"Write and delete values and keys in the Registry, write values into an INI file, dial to your Internet account or connect to a VPN network, restart windows or shut down the computer, create shortcut to a file, change the created/modified date of a file, change your display settings, turn off your monitor, open the door of your CD-ROM drive, and more."

It's pretty neat that NirCmd is so versatile, and quite frankly, the available options with each task it can do are too vast to cover here. Installation is quite simple as well. Simply run the nircmd.exe file from the desktop as an administrator and then click the button "Copy to Windows Directory". Once this is done, you can then invoke the NirCmd utility from anywhere when you are on the command-line.

However, I'd like to give a really neat example of something I did with NirCmd. I wanted my computer to speak a greeting to me out loud every time I logged into Windows. To do this, I simply fired up Notepad and entered the line nircmd speak text "Hello Matt! Welcome to Windows!" in the file. I then saved the file to my Documents folder as an NT CMD file (under the Save As... context menu, change the "Save as type" to All Files (*.*) and save the file as voice.cmd).

With the new file, I created a shortcut to voice.cmd inside my Startup folder in the Start Menu and set the shortcut to run as a minimized window. That's it! Of course, I merely scraped the tip of the iceberg with this nifty little gem of an app. All of the different commands that you can pass to NirCmd can be found in the NirCmd.chm help file provided with the exe.

Bottom line

With this tool being very small in size and available for absolutely free (as well as the other tools made by Nir Sofer), it's definitely worth a shot and, if nothing else, will provide you with nice customizability and even entertainment. Since NirCmd comes in both 32-bit and 64-bit flavors, be sure to download the right edition for your version of Windows for best results.

Also read:

About

An avid technology writer and an IT guru, Matthew is here to help bring the best in software, hardware and the web to the collective consciousness of TechRepublic's readership. In addition to writing for TechRepublic, Matthew currently works as a Cus...

4 comments
JustinF
JustinF

I love nircmd but I can't find a workaround for the UAC prompt which makes it unsuitable to use in a student lab environment. If anyone has a workaround so that you can avoid the UAC prompt for standard users it would be much appreciated.

Mark W. Kaelin
Mark W. Kaelin

Do you find yourself working in the command line interface more often than you thought you would?

Matt Nawrocki
Matt Nawrocki

I will contact Nir Sofer for details on this to see whether or not this conundrum can be resolved somehow.

RNR1995
RNR1995

yes, and it looks to get worse