From f6969ecfd56653fdac043d5301a1bc04f20b0437 Mon Sep 17 00:00:00 2001 From: Phil Kunz Date: Wed, 14 Oct 2015 21:14:20 +0200 Subject: [PATCH] improved readme --- README.md | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index d0274ba..c5d713a 100644 --- a/README.md +++ b/README.md @@ -6,12 +6,24 @@ nodejs wrapper for CLI related tasks [![Build Status](https://travis-ci.org/pushrocks/smartcli.svg?branch=master)](https://travis-ci.org/pushrocks/smartcli) [![devDependency Status](https://david-dm.org/pushrocks/smartcli/dev-status.svg)](https://david-dm.org/pushrocks/smartcli#info=devDependencies) +### Install the package + npm install smartcli + ### Usage ```js +var smartcli = require("smartcli"); -//returns true for terminal command "node yourjs.js jazz" +//returns true for terminal command "node myjs.js jazz" smartcli.checkCommand('jazz'); +/** +* returns an object for terminal command "node myjs.js --myoption something like so +* { +* name: 'myoption', +* specified: true, +* value: 'something' +* } +*/ smartcli.getOption('myoption'); ``