Disallow trailing whitespace

// FREEBIE
This commit is contained in:
lilia 2016-02-17 16:46:32 -08:00
parent 18e9ded296
commit b09cb228f7
3 changed files with 17 additions and 4 deletions

View file

@ -1,3 +1,4 @@
{ {
"disallowMixedSpacesAndTabs": true "disallowMixedSpacesAndTabs": true,
} "disallowTrailingWhitespace": true
}

View file

@ -134,7 +134,15 @@ module.exports = function(grunt) {
}, },
jscs: { jscs: {
all: { all: {
src: ['js/**/*.js', '!js/libtextsecure.js', '!js/libaxolotl-worker.js', '!js/components.js', 'test/**/*.js'] src: [
'Gruntfile',
'js/**/*.js',
'!js/libtextsecure.js',
'!js/libaxolotl-worker.js',
'!js/components.js',
'test/**/*.js',
'!test/blanket_mocha.js',
]
} }
}, },
watch: { watch: {
@ -142,6 +150,10 @@ module.exports = function(grunt) {
files: ['<%= jshint.files %>', './js/**/*.js'], files: ['<%= jshint.files %>', './js/**/*.js'],
tasks: ['jshint'] tasks: ['jshint']
}, },
style: {
files: ['<%= jscs.all.src %>', './js/**/*.js'],
tasks: ['jscs']
},
sass: { sass: {
files: ['./stylesheets/*.scss'], files: ['./stylesheets/*.scss'],
tasks: ['sass'] tasks: ['sass']

View file

@ -87,7 +87,7 @@
message = messages.add({type: 'incoming'}); message = messages.add({type: 'incoming'});
assert.ok(message.isIncoming()); assert.ok(message.isIncoming());
}); });
it('checks if is outgoing message', function() { it('checks if is outgoing message', function() {
var messages = new Whisper.MessageCollection(); var messages = new Whisper.MessageCollection();
var message = messages.add(attributes); var message = messages.add(attributes);