-
-
Notifications
You must be signed in to change notification settings - Fork 7
/
verbfile.js
50 lines (39 loc) · 868 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
45
46
47
48
49
var fs = require('fs');
var path = require('path');
var verb = require('verb');
var async = require('async');
var extend = require('extend-shallow');
var relative = require('relative');
var mdu = require('markdown-utils');
var mm = require('micromatch');
/**
* custom template type
*/
verb.create('item');
verb.items('templates/*.md');
/**
* Data
*/
verb.data({templates: verb.views.items});
verb.data({
twitter: {username: 'jonschlinkert'},
github: {username: 'jonschlinkert'},
});
/**
* Helpers
*/
verb.helper('pre', function (name) {
return mdu.gfm('{%= include("' + name + '") %}', 'js');
});
/**
* Tasks
*/
verb.task('readme', function () {
verb.src('.verb.md')
.pipe(verb.dest('.'))
});
verb.task('docs', function () {
verb.src(['docs/_templates/*.md'])
.pipe(verb.dest('docs'))
});
verb.task('default', ['readme', 'docs']);