forked from jln-pl/grunt-release-plugin
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathGruntfile.js
42 lines (34 loc) · 987 Bytes
/
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
/*
* git-tag-version
* https://github.com/bushee/git-tag-version
*
* Copyright (c) 2015 Jerzy Jelinek, 2016-2017 Krzysztof "Bushee" Nowaczyk
* Licensed under the MIT license.
*/
'use strict';
var gitVersion = require('./src/git-tag-version');
module.exports = function (grunt) {
grunt.initConfig({
jshint: {
all: [
'Gruntfile.js',
'src/*.js',
'test/*.js'
],
options: {
jshintrc: '.jshintrc',
reporterOutput: ''
}
},
nodeunit: {
tests: ['test/*.spec.js']
}
});
grunt.loadNpmTasks('grunt-contrib-jshint');
grunt.loadNpmTasks('grunt-contrib-nodeunit');
grunt.registerTask('current-version', function () {
console.log('Current project version is ' + gitVersion());
});
grunt.registerTask('test', ['nodeunit']);
grunt.registerTask('default', ['jshint', 'test']);
};