Santhosh has uploaded a new change for review.

  https://gerrit.wikimedia.org/r/142482

Change subject: Use updated jscs and wikimedia preset
......................................................................

Use updated jscs and wikimedia preset

Change-Id: I77c150d08ac339a78d2b713a372594e8b2dd38c2
TODO: Fix all errors reported by jscs
---
M .jscsrc
M lineardoc/LinearDoc.js
M package.json
3 files changed, 4 insertions(+), 36 deletions(-)


  git pull ssh://gerrit.wikimedia.org:29418/mediawiki/services/cxserver 
refs/changes/82/142482/1

diff --git a/.jscsrc b/.jscsrc
index 8d8d0f7..9d22e3f 100644
--- a/.jscsrc
+++ b/.jscsrc
@@ -1,35 +1,3 @@
 {
-       "requireCurlyBraces": ["if", "else", "for", "while", "do", "try", 
"catch"],
-       "requireSpaceAfterKeywords": ["if", "else", "for", "while", "do", 
"switch", "return", "try", "catch", "function"],
-       "requireParenthesesAroundIIFE": true,
-       "disallowSpacesInNamedFunctionExpression": {
-               "beforeOpeningRoundBrace": true
-       },
-       "disallowSpacesInFunctionDeclaration": {
-               "beforeOpeningRoundBrace": true
-       },
-       "requireMultipleVarDecl": true,
-       "disallowEmptyBlocks": true,
-       "requireSpacesInsideObjectBrackets": "all",
-       "disallowQuotedKeysInObjects": true,
-       "disallowDanglingUnderscores": true,
-       "disallowSpaceAfterObjectKeys": true,
-       "disallowSpaceAfterPrefixUnaryOperators": ["++", "--", "+", "-", "~", 
"!"],
-       "disallowSpaceBeforePostfixUnaryOperators": ["++", "--"],
-       "disallowSpaceBeforeBinaryOperators": [","],
-       "requireSpaceBeforeBinaryOperators": ["=", "+", "-", "/", "*", "==", 
"===", "!=", "!==", ">", ">=", "<", "<="],
-       "requireSpaceAfterBinaryOperators": ["=", "+", "-", "/", "*", "==", 
"===", "!=", "!==", ">", ">=", "<", "<="],
-       "requireCamelCaseOrUpperCaseIdentifiers": true,
-       "disallowKeywords": [ "with" ],
-       "disallowMultipleLineBreaks": true,
-       "validateLineBreaks": "LF",
-       "validateQuoteMarks": "'",
-       "disallowMixedSpacesAndTabs": true,
-       "disallowTrailingWhitespace": true,
-       "disallowTrailingComma": true,
-       "disallowKeywordsOnNewLine": ["else"],
-       "requireLineFeedAtFileEnd": true,
-       "requireCapitalizedConstructors": true,
-       "requireDotNotation": true,
-       "disallowYodaConditions": true
+       "preset": "wikimedia"
 }
diff --git a/lineardoc/LinearDoc.js b/lineardoc/LinearDoc.js
index 1dd5f39..d14bcf5 100644
--- a/lineardoc/LinearDoc.js
+++ b/lineardoc/LinearDoc.js
@@ -229,7 +229,7 @@
        while ( boundaries[boundaryPtr] === 0 ) {
                boundaryPtr++;
        }
-       for( i = 0, len = chunks.length; i < len; i++ ) {
+       for ( i = 0, len = chunks.length; i < len; i++ ) {
                groupBoundaries = [];
                chunk = chunks[i];
                chunkLength = getLength( chunk );
@@ -443,7 +443,7 @@
                        {
                                name: 'span',
                                attributes: {
-                                       'class': 'cx-segment',
+                                       class: 'cx-segment',
                                        'data-segmentid': getNextId( 'segment' )
                                }
                        }
diff --git a/package.json b/package.json
index 9903083..fd7070f 100644
--- a/package.json
+++ b/package.json
@@ -39,7 +39,7 @@
                "grunt": "0.4.4",
                "grunt-contrib-watch": "0.6.1",
                "grunt-contrib-jshint": "0.10.0",
-               "grunt-jscs-checker": "0.4.4"
+               "grunt-jscs-checker": "0.6.0"
        },
        "bin": {
                "cxserver": "./Server.js"

-- 
To view, visit https://gerrit.wikimedia.org/r/142482
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I77c150d08ac339a78d2b713a372594e8b2dd38c2
Gerrit-PatchSet: 1
Gerrit-Project: mediawiki/services/cxserver
Gerrit-Branch: master
Gerrit-Owner: Santhosh <santhosh.thottin...@gmail.com>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to