-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathindex.js
More file actions
40 lines (37 loc) · 887 Bytes
/
index.js
File metadata and controls
40 lines (37 loc) · 887 Bytes
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
39
40
const chalk = require('chalk');
const frameworkLogo = require('./lib/frameworkLogo');
const commander = require('commander');
const buildAllTasks = require('./lib/tasks/build.js');
const watchTasks = require('./lib/tasks/watch.js');
const devTasks = require('./lib/tasks/dev.js');
module.exports = () => {
commander
.version('1.0.0')
.option('build', 'Build Static Site')
.option('watcher', 'Watching Files')
.option('dev', 'Development mode')
.parse(process.argv);
if (commander.build) {
// console.log(chalk.hex('#38ff34').bold(frameworkLogo));
console.log(
chalk.blue(`Started Building...
`)
);
buildAllTasks();
}
if (commander.watcher) {
console.log(
chalk.blue(`Watching Files...
`)
);
watchTasks();
}
if (commander.dev) {
console.log(
chalk.blue(`Watching Files...
`)
);
devTasks();
}
console.log('Welcome to dypsy!');
};