-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathGruntfile.js
50 lines (43 loc) · 1.09 KB
/
Gruntfile.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
50
/*
* Assemble, component generator for Grunt.js
* https://github.com/assemble/
*
* Copyright (c) 2013 Upstage
* Licensed under the MIT license.
*/
'use strict';
module.exports = function(grunt) {
// Project configuration.
grunt.initConfig({
// pkg : grunt.file.readJSON('package.json'),
// site: grunt.file.readYAML('src/data/site.yml'),
assemble: {
// Task-level options
options: {
assets: "./assets",
prettify: {indent: 2},
marked: {sanitize: false},
engine: 'handlebars'
},
site: {
// Target-level options
options: {
data: 'data.json'
},
files: [
{ src: ['index.html.mustache'], dest: 'index.html' }
]
}
},
// Before generating any new files,
// remove any previously-created files.
clean: {
all: ['index.{html}']
}
});
// Load npm plugins to provide necessary tasks.
grunt.loadNpmTasks('assemble');
grunt.loadNpmTasks('grunt-contrib-clean');
// Default task to be run.
grunt.registerTask('default', ['clean', 'assemble']);
};