Skip to content

Instantly share code, notes, and snippets.

@yuanqing
Created December 25, 2014 16:01
Show Gist options
  • Save yuanqing/1a4a0642ae3c3b5c561c to your computer and use it in GitHub Desktop.
Save yuanqing/1a4a0642ae3c3b5c561c to your computer and use it in GitHub Desktop.
'use strict';
module.exports = function($) {
$.opts({
linkPrefix: '/',
inDir: './in',
outDir: './out',
outFile: 'index.html',
tmplDir: './tmpl',
tmplEngine: 'ejs'
});
$.dataType('blog', {
in: 'blog/{date.year}-{date.month}-{date.day}-{slug}.md',
out: {
single: [
[ $.link('blog/{date.year}-{date.month:%02d}-{date.day:%02d}-{slug}/') ],
[ $.render('single.ejs'), $.write() ]
]
}
});
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment