Skip to content

Commit 8a1a245

Browse files
committed
feat(app): add grunt jscs task for maintaining consistent code style
1 parent 283d493 commit 8a1a245

File tree

3 files changed

+19
-0
lines changed

3 files changed

+19
-0
lines changed

app/templates/.jscs.json

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{
2+
"preset": "google"
3+
}

app/templates/Gruntfile.js

+15
Original file line numberDiff line numberDiff line change
@@ -192,6 +192,21 @@ module.exports = function (grunt) {
192192
}
193193
},
194194

195+
jscs: {
196+
options: {
197+
config: ".jscs.json"
198+
},
199+
main: {
200+
files: {
201+
src: [
202+
'<%%= yeoman.client %>/app/**/*.js',
203+
'<%%= yeoman.client %>/app/**/*.js',
204+
'server/**/*.js'
205+
]
206+
}
207+
}
208+
},
209+
195210
// Empties folders to start fresh
196211
clean: {
197212
dist: {

app/templates/_package.json

+1
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@
4848
"grunt-contrib-jade": "^0.11.0",<% } %><% if(filters.less) { %>
4949
"grunt-contrib-less": "^0.11.4",<% } %>
5050
"grunt-google-cdn": "~0.4.0",
51+
"grunt-jscs": "~0.7.1",
5152
"grunt-newer": "~0.7.0",
5253
"grunt-ng-annotate": "^0.2.3",
5354
"grunt-rev": "~0.1.0",

0 commit comments

Comments
 (0)