Use CommonJS idiom to detect if being run as a command