Skip to content

Instantly share code, notes, and snippets.

View jwietelmann's full-sized avatar

Joel Wietelmann jwietelmann

View GitHub Profile
layout author title
post
edward
Getting Good at Vim

I have used Vim to write code for about a year, and I can confidently say that Vim does two things for me well. The most obvious thing is that it cuts down on my text editing time. If you consider the amount of time you spend highlighting with the mouse and then returning back to the keyboard to edit text, daily, over the course of a year that time begins to adds up.
var sys = require('child_process');
function commandExists(cmd) {
var exists = false;
sys.exec(cmd, function(err) {
if(err === null) // of maybe: if(!err instanceof Error)
exists = true;
});