Wondering what’s next for npm?Check out our public roadmap! »

    shellify

    0.0.5 • Public • Published

    Shellify

    NPM Version Downloads Build Status Code Coverage Dependencies Support

    Shellify is a module for creating command-line interfaces.

    Example

    var shellify = require('shellify');
     
    shellify({
      commands: {
        init: {
          note: 'Creates a new package using the Seattle Pub.js Standard',
          options: {
            name: '!Project name (can contain uppercase)',
            author: '!Author name and email|Sam Eubank<sameubank@gmail.com>',
            description: '!Package description'
          },
          alias: 'c'
        },
        space: {
          note: 'Converts tabs to 2 spaces and ensures standard line endings',
          alias: 's'
        },
        version: {
          note: 'Increments the major, minor or patch version by one',
          options: {
            number: '?Major, minor or patch|patch'
          },
          alias: 'v'
        },
        publish: {
          note: 'Publishes from the current working directory',
          alias: 'p'
        }
      }
    });

    API

    shellify(options)

    Shellify exports itself as a function, seen in the example above.

    shellify.logger

    The Cedar console logger used by shellify, complete with symbols and colors.

    shellify.base

    A string that turns your terminal text back to its default color.

    shellify.(red|yellow|green|cyan|blue|magenta|grey)

    A string that turns your terminal text red/yellow/green/cyan/blue/magenta/grey.

    shellify.mkdirp

    A reference to a copy of substack's mkdirp module, allowing the same functionality as mkdir -p.

    Keywords

    Install

    npm i shellify

    DownloadsWeekly Downloads

    4

    Version

    0.0.5

    License

    MIT

    Last publish

    Collaborators

    • avatar