Sha256: 80932275980e8aaacdb688d967aa0269ccad0d4353ce7fd11b3f95156fb8d7d5

Contents?: true

Size: 532 Bytes

Versions: 69

Compression:

Stored size: 532 Bytes

Contents

#!/usr/bin/env node
'use strict';
var pkg = require('./package.json');
var opn = require('./');

function help() {
	console.log([
		pkg.description,
		'',
		'Usage',
		'  $ opn <file|url> [app]',
		'',
		'Example',
		'  $ opn http://sindresorhus.com',
		'  $ opn http://sindresorhus.com firefox',
		'  $ opn unicorn.png'
	].join('\n'));
}

if (process.argv.indexOf('--help') !== -1) {
	help();
	return;
}

if (process.argv.indexOf('--version') !== -1) {
	console.log(pkg.version);
	return;
}

opn(process.argv[2], process.argv[3]);

Version data entries

69 entries across 69 versions & 2 rubygems

Version Path
trusty-festivity-extension-2.3.1 node_modules/bower/node_modules/opn/cli.js
trusty-festivity-extension-2.3.0 node_modules/bower/node_modules/opn/cli.js
entangled-0.0.16 spec/dummy/public/node_modules/bower/node_modules/opn/cli.js
entangled-0.0.15 spec/dummy/public/node_modules/bower/node_modules/opn/cli.js
entangled-0.0.14 spec/dummy/public/node_modules/bower/node_modules/opn/cli.js
entangled-0.0.13 spec/dummy/public/node_modules/bower/node_modules/opn/cli.js
entangled-0.0.12 spec/dummy/public/node_modules/bower/node_modules/opn/cli.js
entangled-0.0.11 spec/dummy/public/node_modules/bower/node_modules/opn/cli.js
entangled-0.0.10 spec/dummy/public/node_modules/bower/node_modules/opn/cli.js