- back to README.md
Command line interface to the Globalization Pipeline. Example usage:
const Cli = require('g11n-pipeline/lib/gpcli');
new Cli(Cli.parseArgs(process.argv)).run().then(…);
Kind: global class
- Cli
- new Cli(argv)
- instance
- .filter()
- .run() ⇒
Promise.<Object>
- .getCredentials(argv) ⇒
Object
- static
To use from a script: new Cli(Cli.parseArgs(process.argv))
Param | Type | Description |
---|---|---|
argv | Object |
a minimist-compatible argv array (i.e. { "config": "config.json", "_": [ "list" ] }) |
argv._ | Array.<String> |
array of non-option arguments (i.e. 'list', 'ping', etc.) |
Filter the result according to the --outputFormat option.
Use: cli.run().then((result) => cli.filter(result))
Kind: instance method of Cli
Run the verb, returning a Promise with the result. If you call this multiple times, it will run multiple times.
Kind: instance method of Cli
Returns: Promise.<Object>
- the result (verb dependent)
Kind: instance method of Cli
Returns: Object
- credentials
Param | Type | Description |
---|---|---|
argv | Object |
args |
Options to be used with minimist. See https://www.npmjs.com/package/minimist#var-argv--parseargsargs-opts
Kind: static property of Cli
Parse the args with miminist
Kind: static method of Cli
Param | Type | Description |
---|---|---|
argv | Object |
argv from process.argv |
docs autogenerated via jsdoc2md
- View or file GitHub Issues
- Connect with the open source community on developerWorks Open
See CONTRIBUTING.md.
Apache 2.0. See LICENSE.txt
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.