Skip to content
This repository has been archived by the owner on Sep 15, 2023. It is now read-only.

Commit

Permalink
Add -v, --version switch to command line
Browse files Browse the repository at this point in the history
  • Loading branch information
kapouer authored and isaacs committed Feb 10, 2017
1 parent 6449c76 commit c78e945
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions bin/cmd.js
Expand Up @@ -40,6 +40,9 @@ args.forEach(function (arg, i) {
usage()
else
console.error('Unrecognized arg: %j', arg)

if (arg === '-v' || arg === '--version')
console.log(require('../package.json').version)
})

function usage () {
Expand Down

0 comments on commit c78e945

Please sign in to comment.