Skip to content

Commit

Permalink
VerifiedBlockchain fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
fanatid committed Dec 6, 2014
1 parent d41e80d commit fbfd971
Show file tree
Hide file tree
Showing 6 changed files with 176 additions and 59 deletions.
85 changes: 85 additions & 0 deletions .jscsrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,85 @@
{
"requireCurlyBraces": [
"if",
"else",
"for",
"while",
"do",
"try",
"catch"
],
"requireBlocksOnNewline": 1,
"requireOperatorBeforeLineBreak": true,
// Todo
//"requireCamelCaseOrUpperCaseIdentifiers": true,
"maximumLineLength": {
"value": 120,
"allowUrlComments": true,
"allowRegex": true
},
"validateIndentation": 2,
"validateQuoteMarks": "'",

"disallowMultipleLineStrings": true,
"disallowMixedSpacesAndTabs": true,
"disallowTrailingWhitespace": true,
"disallowSpaceAfterPrefixUnaryOperators": true,
"disallowMultipleVarDecl": true,

"requireSpaceAfterKeywords": [
"if",
"else",
"for",
"while",
"do",
"switch",
"return",
"try",
"catch"
],
"requireSpaceBeforeBinaryOperators": [
"=", "+=", "-=", "*=", "/=", "%=", "<<=", ">>=", ">>>=",
"&=", "|=", "^=", "+=",

"+", "-", "*", "/", "%", "<<", ">>", ">>>", "&",
"|", "^", "&&", "||", "===", "==", ">=",
"<=", "<", ">", "!=", "!=="
],
"requireSpaceAfterBinaryOperators": true,
"requireSpacesInConditionalExpression": true,
"requireSpaceBeforeBlockStatements": true,
"requireLineFeedAtFileEnd": true,

"requireParenthesesAroundIIFE": true,
"requireSpacesInFunctionDeclaration": {
"beforeOpeningCurlyBrace": true
},
"disallowSpacesInFunctionDeclaration": {
"beforeOpeningRoundBrace": true
},
"requireSpacesInAnonymousFunctionExpression": {
"beforeOpeningCurlyBrace": true,
"beforeOpeningRoundBrace": true
},
"requireSpacesInNamedFunctionExpression": {
"beforeOpeningCurlyBrace": true
},
"disallowSpacesInNamedFunctionExpression": {
"beforeOpeningRoundBrace": true
},

"disallowYodaConditions": true,
"requireDotNotation": true,
"disallowSpacesInsideObjectBrackets": "all",
"disallowSpacesInsideArrayBrackets": "all",
"disallowSpacesInsideParentheses": true,
"disallowEmptyBlocks": true,

"additionalRules": [
"node_modules/jscs-jsdoc/lib/rules/*.js"
],
"validateJSDoc": {
"checkParamNames": true,
"requireParamTypes": true
}
}
9 changes: 8 additions & 1 deletion Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,18 @@ module.exports = function(grunt) {
}
},
jshint: {
files: ['Gruntfile.js', 'src', 'test'],
src: ['Gruntfile.js', 'src', 'test'],
options: {
jshintrc: true,
reporter: require('jshint-stylish')
}
},
jscs: {
src: ['Gruntfile.js', 'src', 'test'],
options: {
config: '.jscsrc'
}
},
mocha_istanbul: {
coverage: {
src: 'test',
Expand Down Expand Up @@ -92,6 +98,7 @@ module.exports = function(grunt) {
grunt.loadNpmTasks('grunt-contrib-uglify')
grunt.loadNpmTasks('grunt-contrib-watch')
grunt.loadNpmTasks('grunt-mocha-istanbul')
grunt.loadNpmTasks('grunt-jscs')
grunt.loadNpmTasks('grunt-mocha-test')

grunt.registerTask('compile', ['browserify:production', 'uglify:production'])
Expand Down
3 changes: 2 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "cc-wallet-core",
"version": "0.2.7",
"version": "0.2.8",
"description": "",
"main": "./src/index.js",
"keywords": [],
Expand Down Expand Up @@ -39,6 +39,7 @@
"grunt-contrib-jshint": "^0.10.0",
"grunt-contrib-uglify": "^0.6.0",
"grunt-contrib-watch": "^0.6.1",
"grunt-jscs": "^1.0.0",
"grunt-mocha-istanbul": "^2.2.0",
"grunt-mocha-test": "git://github.com/pghalliday/grunt-mocha-test.git#master",
"istanbul": "^0.3.2",
Expand Down
Loading

0 comments on commit fbfd971

Please sign in to comment.