-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
verbfile.js
44 lines (37 loc) · 897 Bytes
/
verbfile.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
39
40
41
42
43
44
'use strict';
var generator = require('./');
var trees = require('verb-trees');
var del = require('delete');
/**
* Build docs: `$ verb`
*
* (verb takes ~2 sec to run, since it has to
* run all of the tasks to create file trees)
*/
module.exports = function(app) {
app.use(require('verb-generate-readme'));
app.option('check-directory', false);
app.option('overwrite', true);
app.option('prompt', false);
app.use(trees(generator, [
'default',
'minimal',
'gulp',
'base',
'generator',
'helper',
'files',
'rootfiles',
'dotfiles',
'index'
]));
app.task('docs', function(cb) {
return app.src('docs/trees.md', {cwd: __dirname})
.pipe(app.renderFile('*'))
.pipe(app.dest(app.cwd));
});
app.task('delete', function(cb) {
del('.temp-trees', cb);
});
app.task('default', ['trees', 'readme', 'docs', 'delete']);
};