Skip to content

Commit

Permalink
chore(Gruntfile.js): use grunt-load-tasks to load tasks
Browse files Browse the repository at this point in the history
Also add spaces between sections to improve readability
  • Loading branch information
tivie committed May 31, 2015
1 parent f2f01fb commit fec5b8e
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ module.exports = function (grunt) {
// Project configuration.
var config = {
pkg: grunt.file.readJSON('package.json'),

concat: {
options: {
sourceMap: true,
Expand Down Expand Up @@ -34,16 +35,18 @@ module.exports = function (grunt) {
}
}
},

jshint: {
files: [
'Gruntfile.js',
'src/**/*.js',
'test/**/*.js'
]
},

jscs: {
options: {
config: '.jscs.json',
config: '.jscs.json'
},
files: {
src: [
Expand All @@ -53,12 +56,14 @@ module.exports = function (grunt) {
]
}
},

changelog: {
options: {
repository: 'http://github.com/showdownjs/showdown',
dest: 'CHANGELOG.md'
}
},

bump: {
options: {
files: ['package.json'],
Expand All @@ -77,6 +82,7 @@ module.exports = function (grunt) {
regExp: false
}
},

simplemocha: {
node: {
src: 'test/node/**/*.js',
Expand All @@ -98,13 +104,7 @@ module.exports = function (grunt) {

grunt.initConfig(config);

grunt.loadNpmTasks('grunt-contrib-concat');
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-contrib-jshint');
grunt.loadNpmTasks('grunt-simple-mocha');
grunt.loadNpmTasks('grunt-jscs');
grunt.loadNpmTasks('grunt-conventional-changelog');
grunt.loadNpmTasks('grunt-bump');
require('load-grunt-tasks')(grunt);

grunt.registerTask('lint', ['jshint', 'jscs']);
grunt.registerTask('test', ['lint', 'concat', 'simplemocha']);
Expand Down

0 comments on commit fec5b8e

Please sign in to comment.