Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
}
})
yargs.command(require('./command-start'))
yargs.command(require('./command-stop'))
yargs.command(require('./command-env'))
yargs.command('*', false, () => {
yargs.showHelp();
console.error("Non-existing or no command specified.");
process.exit(1);
})
yargs.demandCommand(1)
yargs.help('h')
yargs.alias('h', 'help')
yargs.alias('v', 'version')
yargs.env(meta.name.replace(/-/g, '').toUpperCase())
const argv = yargs.argv
}
#!/usr/bin/env node
const astGenerator = require('..');
const yargs = require('yargs');
const argv = yargs
.alias('f', 'files')
.alias('o', 'output-dir')
.demandOption(['files', 'output-dir'])
.usage('Usage: $0 -f -o ')
.example('$0 -f src/**/*.js -o result',
'parse all JS files in src dir and output ASTs in result dir')
.describe('files', 'Glob pattern of files to parse')
.describe('output-dir', 'The directory where to put the results')
.help('h')
.alias('h', 'help')
.argv;
astGenerator(argv, (err, count) => {
if (err !== null) {
console.error('failed: ' + err);
} else {
import webpack from 'webpack';
import yargs from 'yargs';
const { optimizeMinimize } = yargs.alias('p', 'optimize-minimize').argv;
const nodeEnv = optimizeMinimize ? 'production' : 'development';
export default {
entry: {
'ReactRouterBootstrap': './src/index.js'
},
output: {
path: './lib',
filename: optimizeMinimize ? '[name].min.js' : '[name].js',
library: 'ReactRouterBootstrap',
libraryTarget: 'umd'
},
module: {
loaders: [
{ test: /\.js$/, loader: 'babel', exclude: /node_modules/ }
]
var webpack =require('webpack');
var yargs = require('yargs');
const options = yargs
.alias('p', 'optimize-minimize')
.alias('d', 'debug')
.argv;
const jsLoader = 'babel?cacheDirectory';
module.exports = {
entry: {
'react-dynamic-style-loader': './src/index.js'
},
output: {
path: '.',
filename: options.optimizeMinimize ? 'index.min.js' : 'index.js',
library: 'ReactDynamicStyleLoader',
libraryTarget: 'umd'
},
require('babel-polyfill');
import {BagDump, Convert} from './cmds';
const StartEndOptions = {
start: {
alias: 's',
describe: 'Starting timestamp to begin conversion'
},
end: {
alias: 'e',
describe: 'Ending timestamp to stop conversion'
}
};
const yargs = require('yargs')
.alias('h', 'help')
.command(
'convert [-d output] ',
'Convert a rosbag to xviz',
{
...StartEndOptions,
dir: {
alias: 'd',
describe: 'Directory to save XVIZ data',
demandOption: true
}
},
Convert
)
.command(
'bagdump ',
const shell = require('shelljs')
const path = require('path')
const fs = require('fs')
const glob = require('glob')
const po2json = require('easygettext/src/compile').po2json
const argv = require('yargs')
.alias('output', 'o')
.describe('output', 'The output folder for translation JSON file(s)')
.alias('filename', 'f')
.describe('filename', 'The file name for translation JSON file(s)')
.default('filename', 'translation.json')
.alias('src', 's')
.describe('src', 'The source folder for PO files')
.alias('multiple', 'm')
.describe('multiple', 'Should it generate a single JSON file containing all translations, or multiple JSON files each for a translation')
.default('multiple', false)
.demand(['src', 'output'])
.argv
#!/usr/bin/env node
var path = require('path')
var MBTiles = require('mbtiles')
var list = require('./lib/list')
var argv = require('yargs')
.alias('output', 'o')
.alias('zoom', 'z')
.demand(['o', 'z'])
.demand(1)
.argv
var input = argv._[0]
var output = argv.output
var zoom = argv.zoom
input = path.resolve(process.cwd(), input)
output = path.resolve(process.cwd(), output)
var mbtiles = new MBTiles('mbtiles://' + input, function (err) {
if (err) { throw err }
list(mbtiles, zoom, function (err, tiles) {
#!/usr/bin/env node
'use strict';
const fs = require('fs');
const chalk = require('chalk');
const multiline = require('multiline');
const pkg = require('./package.json');
const pathExists = require('path-exists');
const argv = require('yargs')
.alias('t', 'type')
.alias('s', 'style')
.alias('l', 'size')
.alias('r', 'root')
.alias('w', 'whitespace')
.alias('m', 'maxline')
.alias('n', 'newline')
.alias('h', 'help')
.alias('v', 'version')
.argv;
let str = [];
let header = ['# editorconfig.org'];
let options = {
fileType : argv.type,
function createParameters() {
yargs.alias('t', 'token')
.alias('n', 'name')
.global('token')
.global('name');
}