Apr 11
Know your tools
icon1 Darrell Mozingo | icon2 Musings | icon4 April 11th, 2011| icon34 Comments »

Tools

How many carpenters do you think don’t know about kerf widths? How many plumbers don’t know the difference between MAPP and propane for soldering? Probably not many.

Masters of their craft know their tools inside and out. They don’t just skirt by barely knowing how to use them, and end up taking longer to complete a job because of that. We have the same situation in our craft. We use tools day in and day out – our IDE’s, debugging tools (for our main languages and web based ones), OS, browsers, websites, etc. They’re all tools of our trade. Learning how to really use them is just another stepping stone on the path to being a craftsman.

The best way to really make use of your tools and increase your programming speed is to ditch the mouse. Use the keyboard as much as possible, which can be almost everything. Really get good with the keyboard and you’ll be amazed at how much more efficiently you can pump out code and navigate around.

I use Windows and Visual Studio, so I’ll use that as an example. Visual Studio itself has a metric ton of built-in keyboard shortcuts, but add ReSharper to the mix, and you’re golden. Check out the keyboard shortcut cheat sheet, it’s ridiculous, and overwhelming. Pick one or two shortcuts you think you’ll use, then use those exclusively for a week. Make sure to purposely use them as much as possible until they become muscle memory. It won’t take long.

Look at Tools -> Settings -> Keyboard. There’s lots of stuff you can key bind on your own that doesn’t come setup by default. Create a key combination to run your unit tests rather than reaching for the mouse. If a default key combo feels unnatural for you, rebind it. Find something that works for you, and don’t be afraid to experiment.

Start learning keyboard shortcuts in other programs you use on a regular basis. There’s cheat sheets for GMail and Google Reader. For your mouse-free text editing needs (and IDE needs if you’re super experimentative and working with .NET) there’s the grand-daddies themselves: VIM and Emacs. There’s even plugins for Firefox (Vimperator) and Chrome (Vimium) to make each browser navigable in a VIM-esque way, and other plugins for each browser to simply add more keyboard navigation tricks. Heck, there’s even a few VIM plugins for Visual Studio itself if you want to go all the way, including ViEmu (paid) and VsVim (free).

It’s also super helpful to get a keystroke launcher on your box, such as Executor (my personal favorite) or Launchy. These guys basically give you the standard Windows Run dialog on steroids – letting you make custom launch commands and scripts. Definitely play around with one of these and work it into your normal workflow. I find myself leaning on it all the time.

So start practicing with a keyboard-only setup today. Disable your mouse driver and force yourself. It’ll kill your productivity in the short term for sure, but it’ll pay dividends every day for the rest of your career once you get used to it. You’ll thank me in a few weeks. Seriously, I’m marking my calendar.