Skip to content

Commit ae2980b

Browse files
justuswilhelmnventuro
authored andcommitted
Add EditorConfig (#1119)
* Add EditorConfig file. This allows users with a wide variety of editors to easily code in OpenZeppelin's preferred 2 space indentation code style. See https://editorconfig.org for more information. * Eslint: Always disallow trailing space * Eslint: Error on missing EOL at file end
1 parent f5b0bb3 commit ae2980b

File tree

3 files changed

+15
-3
lines changed

3 files changed

+15
-3
lines changed

.editorconfig

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
# EditorConfig is awesome: https://EditorConfig.org
2+
3+
# top-most EditorConfig file
4+
root = true
5+
6+
[*]
7+
charset = utf-8
8+
end_of_line = lf
9+
indent_size = 2
10+
indent_style = space
11+
insert_final_newline = true
12+
trim_trailing_whitespace = true

.eslintrc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
"comma-dangle": ["warn", "always-multiline"],
2929
"comma-spacing": ["error", {"before": false, "after": true}],
3030
"dot-notation": ["error", {"allowKeywords": true, "allowPattern": ""}],
31-
"eol-last": "warn",
31+
"eol-last": ["error", "always"],
3232
"eqeqeq": ["error", "smart"],
3333
"generator-star-spacing": ["error", "before"],
3434
"indent": ["error", 2],
@@ -38,7 +38,7 @@
3838
"no-dupe-keys": "error",
3939
"no-mixed-spaces-and-tabs": ["error", "smart-tabs"],
4040
"no-redeclare": ["error", {"builtinGlobals": true}],
41-
"no-trailing-spaces": ["error", { "skipBlankLines": true }],
41+
"no-trailing-spaces": ["error", { "skipBlankLines": false }],
4242
"no-undef": "error",
4343
"no-use-before-define": "off",
4444
"no-var": "error",

test/Bounty.test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ contract('Bounty', function ([_, owner, researcher]) {
2525

2626
it('can set reward', async function () {
2727
await sendReward(owner, this.bounty.address, reward);
28-
28+
2929
const balance = await ethGetBalance(this.bounty.address);
3030
balance.should.be.bignumber.eq(reward);
3131
});

0 commit comments

Comments
 (0)