-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.js
executable file
·38 lines (33 loc) · 947 Bytes
/
index.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
#!/usr/bin/env node --harmony
/**
* Importing Modules
*/
const program = require('commander');
const prompt = require('co-prompt');
const ProgressBar = require('progress');
const fs = require('fs');
const SVN = require('./modules/Svn');
const chalk = require('chalk');
const log = console.log;
/**
* Program Logic
*/
program
.description('A CLI for handling WordPress SVN functions.')
.version('0.0.1', '-v --version')
.option('-h, --help', null, {noHelp: true});
program
.description('SVN functions, like tag, push, etc.')
.command('svn [command]', null, {noHelp: true})
.option('-m, --message <message>', null, {noHelp: true})
.option('-h, --help', null, {noHelp: true})
.action(function(command, options) {
let s = new SVN(command, options);
s.parse();
});
program
.command('*')
.action(function(env){
log('deploying "%s"', env);
});
program.parse(process.argv);