Skip to content

Commit 2c9e739

Browse files
committed
chore: update dependencies and add ESLint configuration
- Bump versions of devDependencies including hardhat, solhint, eslint, prettier, and others. - Add .prettierignore file to exclude specific file types from formatting. - Introduce ESLint configuration file with recommended settings and custom rules for scripts and tests.
1 parent 53067c1 commit 2c9e739

File tree

7 files changed

+6908
-5017
lines changed

7 files changed

+6908
-5017
lines changed

packages/sharing-smart-contract/.env.template

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ WALLET_PRIVATE_KEY=...
55
ENV=prod
66

77
# IExec PoCo contract address override (deploy script only)
8-
# POCO_ADDRESS=0x...
8+
POCO_ADDRESS=...
99

1010
# DatasetRegistry contract address override (deploy script only)
11-
# DATASET_REGISTRY_ADDRESS=0x...
11+
DATASET_REGISTRY_ADDRESS=...
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
*.yml
2+
*json
3+
*.md
Lines changed: 13 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,19 @@
11
{
2-
"printWidth": 120,
2+
"printWidth": 100,
33
"singleQuote": true,
4-
"tabWidth": 2,
4+
"tabWidth": 4,
55
"trailingComma": "all",
6-
"arrowParens": "avoid",
7-
"plugins": ["prettier-plugin-organize-imports", "prettier-plugin-solidity"],
6+
"endOfLine": "auto",
7+
"plugins": [
8+
"prettier-plugin-organize-imports",
9+
"prettier-plugin-solidity"
10+
],
811
"overrides": [
9-
{
10-
"files": "*.sol",
11-
"options": {
12-
"singleQuote": false,
13-
"tabWidth": 4
14-
}
15-
}
12+
{
13+
"files": "*.sol",
14+
"options": {
15+
"singleQuote": false
16+
}
17+
}
1618
]
1719
}
Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,22 @@
11
{
2-
"extends": ["solhint:recommended"],
2+
"extends": [
3+
"solhint:recommended"
4+
],
35
"plugins": [],
46
"rules": {
5-
"func-visibility": ["warn", { "ignoreConstructors":true }],
6-
"quotes": ["double"]
7+
"compiler-version": [
8+
"error",
9+
"^0.8.19"
10+
],
11+
"func-visibility": [
12+
"warn",
13+
{
14+
"ignoreConstructors": true
15+
}
16+
],
17+
"quotes": [
18+
"error",
19+
"double"
20+
]
721
}
822
}
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
import eslint from '@eslint/js';
2+
import importPlugin from 'eslint-plugin-import';
3+
import prettier from 'eslint-config-prettier';
4+
5+
export default [
6+
eslint.configs.recommended,
7+
prettier,
8+
{
9+
languageOptions: {
10+
ecmaVersion: 'latest',
11+
sourceType: 'module',
12+
},
13+
plugins: { import: importPlugin },
14+
},
15+
{
16+
files: ['scripts/**/*.js', 'test/**/*.js', 'hardhat.config.cjs'],
17+
rules: {
18+
'import/no-extraneous-dependencies': ['error', { devDependencies: true }],
19+
'import/prefer-default-export': 'off',
20+
'import/extensions': ['error', 'always'],
21+
},
22+
},
23+
{
24+
files: ['test/**/*.js'],
25+
languageOptions: {
26+
globals: {
27+
describe: 'readonly',
28+
it: 'readonly',
29+
},
30+
},
31+
rules: {
32+
'no-unused-expressions': 'off',
33+
'no-shadow': 'off',
34+
},
35+
},
36+
{
37+
files: ['tools/**/*.js'],
38+
rules: {
39+
'no-undef': 'warn',
40+
},
41+
},];

0 commit comments

Comments
 (0)