verb
Version:
Verb makes it easy to build project documentation using simple markdown templates, with zero configuration required.
21 lines (19 loc) • 554 B
JavaScript
/**
* Verb <https://github.com/assemble/verb>
* Generate markdown documentation for GitHub projects.
*
* Copyright (c) 2014 Jon Schlinkert, Brian Woodward, contributors.
* Licensed under the MIT license.
*/
var file = require('fs-utils');
var verb = require('../');
var opts = {verbrc: 'examples/.verbrc'};
var globOpts = {
cwd: 'docs',
ext: '.md',
destBase: 'test/actual/'
};
file.expandMapping(['docs/*.md'], globOpts).map(function(fp) {
file.writeFileSync(fp.dest, verb.read(fp.src, opts));
verb.log.success('Saved to', fp.dest);
});