Skip to content

Commit 4fa383e

Browse files
committed
Merge branch 'busticated-linting'
2 parents cbe10cd + 8862790 commit 4fa383e

File tree

3 files changed

+11
-2
lines changed

3 files changed

+11
-2
lines changed

Gruntfile.js

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,11 @@ module.exports = function(grunt) {
4848
src: ['src/Autolinker.js'],
4949
dest: 'dist/Autolinker.min.js',
5050
}
51+
},
52+
jshint: {
53+
files: {
54+
src: ['src/**/*.js', 'tests/**/*.js']
55+
}
5156
}
5257
});
5358

@@ -56,9 +61,11 @@ module.exports = function(grunt) {
5661
grunt.loadNpmTasks('grunt-contrib-jasmine');
5762
grunt.loadNpmTasks('grunt-contrib-concat');
5863
grunt.loadNpmTasks('grunt-contrib-uglify');
64+
grunt.loadNpmTasks('grunt-contrib-jshint');
5965

6066
// Tasks
61-
grunt.registerTask('default', ['test', 'build']);
67+
grunt.registerTask('default', ['lint', 'test', 'build']);
68+
grunt.registerTask('lint', ['jshint']);
6269
grunt.registerTask('test', ['jasmine']);
6370
grunt.registerTask('build', ['concat:development', 'uglify:production']);
6471
grunt.registerTask('serve', ['connect:server:keepalive']);

package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@
3333
"grunt-contrib-connect": "^0.7.1",
3434
"requirejs": "^2.1.11",
3535
"grunt-contrib-uglify": "^0.4.0",
36-
"grunt-contrib-concat": "^0.4.0"
36+
"grunt-contrib-concat": "^0.4.0",
37+
"grunt-contrib-jshint": "^0.10.0"
3738
}
3839
}

src/Autolinker.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
/*global define, module */
2+
/*jshint smarttabs:true */
23
// Set up Autolinker appropriately for the environment.
34
( function( root, factory ) {
45
if( typeof define === 'function' && define.amd ) {

0 commit comments

Comments
 (0)