sco

0.1.0 • Public • Published

sco (String COdec)

NPM version Build Status

Command line interface of string-codec

Installation

via npm (node package manager)

$ npm install -g sco

Usage Example

Encode to Base64:

$ sco -e base64 hello
$ aGVsbG8=

Decode from Base64:

$ sco -d base64 aGVsbG8=
$ hello

Encode to hex:

$ sco -e hex abc
$ 616263

Decode from hex:

$ sco -d hex 616263
$ abc
$ sco -d hex 0x616263
$ abc

Encode and Decode using pipes:

$ echo "hello world" | sco -e base64 | sco -d base64
$ hello world

Options

-h, --help

output usage information

-v, --version

output the version number

-e <algo>, --encode <algo>

encode input with specified algorithm

-d <algo>, --decode <algo>

decode input with specified algorithm

-l <enc|dec>, --list <enc|dec>

list all available encode/decode algorithm

Supported specifications

For further details, see string-codec

encoder

hex, ascii, base64, base85 (z85), ascii85, base91, rot5/rot13/rot18/rot47,
rev (reverse string), crc1/crc8/crc16/crc24/crc32, adler32, url (url encoding),
unixtime, lower, upper, punycode, md4, md5, sha, sha1, sha224, sha256,
sha384, sha512, rmd160, whirlpool, etc.

decoder

hex, ascii, base64, base85 (z85), ascii85, base91, rot5/rot13/rot18/rot47,
rev, url, unixtime, punycode, md5, etc.

Running tests

$ git clone https://github.com/knjcode/sco
$ cd sco
$ npm install
$ npm test

Readme

Keywords

Package Sidebar

Install

npm i sco

Weekly Downloads

14

Version

0.1.0

License

MIT

Last publish

Collaborators

  • knjcode