blah-code-cli
Advanced tools
Comparing version 1.0.2 to 2.0.0
26
cli.js
@@ -14,10 +14,11 @@ #!/usr/bin/env node | ||
' --decode, -d Returns regular text of the given blah code [Default: false]', | ||
' --ooks, -o Uses this weird ape language instead of blah code [Default: false]', | ||
' --help, -h Shows the help', | ||
'', | ||
'Examples', | ||
' $ blah-code Hi!', | ||
' blah blah blah blah blah blah blah blah blah, blah blah blah blah blah blah blah blah blah blah, blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah', | ||
' $ blah-code "Hi 👻"', | ||
' blaa bluh. blah bleh bluuh. blaah bluh. bluuh bluuh blaah bluuh blaa. bluuh blehh bleeh bleeh blaah', | ||
'', | ||
' $ blah-code --decode "blah blah blah blah blah blah blah blah blah, blah blah blah blah blah blah blah blah blah blah, blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah"', | ||
' hi!' | ||
' $ blah-code "blaa bluh. blah bleh bluuh. blaah bluh. bluuh bluuh blaah bluuh blaa. bluuh blehh bleeh bleeh blaah" --decode', | ||
' Hi 👻' | ||
], { | ||
@@ -27,3 +28,4 @@ alias: { | ||
e: 'encode', | ||
d: 'decode' | ||
d: 'decode', | ||
o: 'ooks' | ||
} | ||
@@ -33,7 +35,15 @@ }); | ||
if (cli.input[0] === undefined) { | ||
console.log(chalk.red('I need input. Enter `' + chalk.bold('blah-code --help') + '` if you need assistance`')); | ||
console.log(chalk.red('I need input. Enter `' + chalk.bold('blah-code --help') + '` if you need assistance.')); | ||
} else if (cli.flags.decode) { | ||
console.log(chalk.green(blahCode.decode(cli.input[0]))); | ||
if (cli.flags.ooks) { | ||
console.log(chalk.green(blahCode.decode(cli.input[0], 'ooks'))); | ||
} else { | ||
console.log(chalk.green(blahCode.decode(cli.input[0]))); | ||
} | ||
} else { | ||
console.log(chalk.green(blahCode.encode(cli.input[0]))); | ||
if (cli.flags.ooks) { // eslint-disable-line | ||
console.log(chalk.green(blahCode.encode(cli.input[0], 'ooks'))); | ||
} else { | ||
console.log(chalk.green(blahCode.encode(cli.input[0]))); | ||
} | ||
} |
{ | ||
"name": "blah-code-cli", | ||
"version": "1.0.2", | ||
"version": "2.0.0", | ||
"description": "Encode and decode blah code via the command line", | ||
@@ -22,3 +22,2 @@ "license": "MIT", | ||
"files": [ | ||
"index.js", | ||
"cli.js" | ||
@@ -33,3 +32,3 @@ ], | ||
"dependencies": { | ||
"blah-code": "^1.1.2", | ||
"blah-code": "^2.0.1", | ||
"chalk": "^1.1.1", | ||
@@ -39,5 +38,5 @@ "meow": "^3.6.0" | ||
"devDependencies": { | ||
"ava": "^0.9.1", | ||
"xo": "^0.12.1" | ||
"ava": "^0.12.0", | ||
"xo": "^0.13.0" | ||
} | ||
} |
@@ -24,3 +24,3 @@ [![very bullgit](https://img.shields.io/badge/very-bullgit-1393d5.svg?style=flat)](https://bullg.it/) | ||
``` | ||
$ blah-code --help | ||
$ blah-code --help | ||
@@ -34,11 +34,12 @@ Encode and decode blah code via the command line | ||
--encode, -e Returns the blah code representation of the given text input [Default: true] | ||
--decode, -e Returns regular text of the given blah code | ||
--decode, -d Returns regular text of the given blah code [Default: false] | ||
--ooks, -o Uses this weird ape language instead of blah code [Default: false] | ||
--help, -h Shows the help | ||
Examples | ||
$ blah-code Hi! | ||
blah blah blah blah blah blah blah blah blah, blah blah blah blah blah blah blah blah blah blah, blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah | ||
$ blah-code "Hi 👻" | ||
blaa bluh. blah bleh bluuh. blaah bluh. bluuh bluuh blaah bluuh blaa. bluuh blehh bleeh bleeh blaah | ||
$ blah-code --decode "blah blah blah blah blah blah blah blah blah, blah blah blah blah blah blah blah blah blah blah, blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah blah" | ||
hi! | ||
$ blah-code "blaa bluh. blah bleh bluuh. blaah bluh. bluuh bluuh blaah bluuh blaa. bluuh blehh bleeh bleeh blaah" --decode | ||
Hi 👻 | ||
``` | ||
@@ -45,0 +46,0 @@ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
44
52
5147
4
+ Addedblah-code@2.0.1(transitive)
- Removedblah-code@1.3.0(transitive)
Updatedblah-code@^2.0.1