-
-
Save knksmith57/e433fa7416e8530427a4054cfa22b5d3 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env node | |
'use strict' | |
require('yargs') | |
.command('hello <name>', 'say hello to <name>', {}, yargs => { | |
console.log(`hello, ${yargs.name}!`) | |
}) | |
.demandCommand(1) | |
.help() | |
.argv |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"bin": { | |
"hello": "bin/hello.js" | |
}, | |
"scripts": { | |
"lint": "eslint *.js **/*.js | snazzy" | |
}, | |
"eslintConfig": { | |
"extends": "standard", | |
"overrides": [ | |
{ | |
"files": ["bin/*.js"], | |
"rules": { | |
"no-unused-expressions": 0 | |
} | |
} | |
] | |
}, | |
"devDependencies": { | |
"eslint": "^4", | |
"eslint-config-standard": "^10", | |
"eslint-plugin-import": "^2", | |
"eslint-plugin-node": "^5", | |
"eslint-plugin-promise": "^3", | |
"eslint-plugin-standard": "^3", | |
"snazzy": "^7" | |
}, | |
"dependencies": { | |
"yargs": "^8" | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment