@pika/plugin-simple-bin
A @pika/pack plugin: Adds a simple CLI wrapper.
Last updated 6 months ago by fredkschott .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install @pika/plugin-simple-bin 
SYNC missed versions from official npm registry.

@pika/plugin-simple-bin

A @pika/pack build plugin. Adds a simple CLI wrapper to your package and properly configures your package.json "bin" field to point to it. Useful for quickly adding a command line interface to your library.

Install

# npm:
npm install @pika/plugin-simple-bin --save-dev
# yarn:
yarn add @pika/plugin-simple-bin --dev

Usage

{
  "name": "example-package-json",
  "version": "1.0.0",
  "@pika/pack": {
    "pipeline": [
      ["@pika/plugin-standard-pkg"],
      ["@pika/plugin-build-node"],
      ["@pika/plugin-simple-bin", {"bin": "my-cli"}]
    ]
  }
}

For more information about @pika/pack & help getting started, check out the main project repo.

Result

  1. Adds a simple bin/CLI wrapper to your built package: dist-node/index.bin.js
  2. Built for Node.js
  3. Loads your library, and calls an exported run() method with the CLI args.
  4. Will load a bundled Node.js distribution if one exists.
  5. Configures the built package.json with a new "bin" entrypoint, so that npm knows to install your package as a CLI.

Current Tags

  • 0.9.2                                ...           latest (6 months ago)

28 Versions

  • 0.9.2                                ...           6 months ago
  • 0.9.1                                ...           6 months ago
  • 0.8.3                                ...           6 months ago
  • 0.9.0                                ...           6 months ago
  • 0.8.2                                ...           6 months ago
  • 0.8.1                                ...           9 months ago
  • 0.8.0                                ...           9 months ago
  • 0.7.1                                ...           10 months ago
  • 0.7.0                                ...           10 months ago
  • 0.6.1                                ...           a year ago
  • 0.6.0                                ...           a year ago
  • 0.5.1                                ...           a year ago
  • 0.5.0                                ...           a year ago
  • 0.4.0                                ...           a year ago
  • 0.3.16                                ...           a year ago
  • 0.3.15                                ...           a year ago
  • 0.3.14                                ...           a year ago
  • 0.3.13                                ...           a year ago
  • 0.3.12                                ...           a year ago
  • 0.3.11                                ...           2 years ago
  • 0.3.10                                ...           2 years ago
  • 0.3.9                                ...           2 years ago
  • 0.3.8                                ...           2 years ago
  • 0.3.7                                ...           2 years ago
  • 0.3.5                                ...           2 years ago
  • 0.3.4                                ...           2 years ago
  • 0.3.3                                ...           2 years ago
  • 0.3.2                                ...           2 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 2
Last Day 0
Last Week 1
Last Month 155
Dependencies (1)
Dev Dependencies (6)
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |