You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
nodebb/Gruntfile.js

65 lines
1.3 KiB
JavaScript

10 years ago
module.exports = function(grunt) {
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
express: {
10 years ago
dev: {
options: {
script: 'app.js',
node_env: 'development',
args: ['dev', 'from-file'],
10 years ago
output: "NodeBB Ready",
interrupt: true,
spawn: false,
interval: 100
10 years ago
}
},
minifyJS: {
options: {
script: 'app.js',
node_env: 'development',
args: ['dev', 'minify-js'],
10 years ago
output: "NodeBB Ready",
interrupt: true,
spawn: false,
interval: 100
10 years ago
}
},
compileLESS: {
10 years ago
options: {
script: 'app.js',
node_env: 'development',
args: ['dev', 'compile-less'],
10 years ago
output: "NodeBB Ready",
interrupt: true,
spawn: false,
interval: 100
10 years ago
}
}
10 years ago
},
less: {
development: {
files: {
"public/bin/manifest.css": "source/manifest.less"
10 years ago
}
}
},
watch: {
compileLESS: {
files: "**/*.less",
tasks: ['express:compileLESS'],
10 years ago
options: {
livereload: true,
10 years ago
}
}
}
});
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.loadNpmTasks('grunt-express-server');
grunt.registerTask('default', ['express:dev', 'watch']);
10 years ago
grunt.event.on('watch', function(action, filepath, target) {
grunt.log.writeln(target + ': ' + filepath + ' has ' + action);
});
10 years ago
};