Skip to content

Commit

Permalink
chore: enable prettier in solhint
Browse files Browse the repository at this point in the history
  • Loading branch information
0xtekgrinder committed Oct 27, 2023
1 parent 2c86b64 commit 17b9afb
Show file tree
Hide file tree
Showing 6 changed files with 167 additions and 65 deletions.
8 changes: 8 additions & 0 deletions .prettierignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
lib
artifacts
node_modules
cache-forge
cache-hh
export
out
typechain
3 changes: 1 addition & 2 deletions .prettierrc
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,7 @@
"options": {
"printWidth": 120,
"singleQuote": false,
"bracketSpacing": true,
"explicitTypes": "always"
"bracketSpacing": true
}
}
]
Expand Down
3 changes: 2 additions & 1 deletion .solhint.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,15 @@
"const-name-snakecase": "warn",
"contract-name-camelcase": "warn",
"imports-on-top": "warn",
"prettier/prettier": "off",
"prettier/prettier": "error",
"ordering": "off",
"max-states-count": "off",
"mark-callable-contracts": "off",
"no-empty-blocks": "off",
"no-global-import": "off",
"not-rely-on-time": "off",
"compiler-version": "off",
"explicit-types": ["error","explicit"],
"private-vars-leading-underscore": "warn",
"reentrancy": "warn",
"no-inline-assembly": "off",
Expand Down
15 changes: 15 additions & 0 deletions .solhintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
// Doesn't need to lint dev files
lib
scripts
test
mock
deprecated

// Doesn't need to lint build files
artifacts
node_modules
cache-forge
cache-hh
export
out
typechain
18 changes: 9 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,15 @@
"sources": "hardhat deploy --tags LayerZeroSources --network",
"license": "hardhat prepend-spdx-license",
"lint": "yarn lint:sol && yarn lint:js",
"lint:js": "eslint --ignore-path .gitignore --max-warnings 30 'test/**/*.{js,ts}' '*.{js,ts}'",
"lint:sol": "solhint --max-warnings 20 \"contracts/**/*.sol\"",
"lint:js": "yarn lint:js:check --fix",
"lint:sol": "yarn lint:sol:check --fix",
"lint:check": "yarn lint:sol:check && yarn lint:js:check",
"lint:js:check": "yarn lint:js --fix",
"lint:sol:check": "yarn lint:sol --fix",
"lint:js:check": "eslint --ignore-path .gitignore --max-warnings 30 'test/**/*.{js,ts}' '*.{js,ts}'",
"lint:sol:check": "solhint --max-warnings 20 \"**/*.sol\"",
"mainnetForkRemote:deploy": "rm -rf ./deployments/mainnetForkRemote && hardhat deploy --network mainnetForkRemote --tags unpausing",
"node:fork": "FORK=true hardhat node --tags",
"prettier": "yarn prettier:js && yarn prettier:sol",
"prettier:sol": "prettier --write 'contracts/**/*.sol'",
"prettier:sol": "prettier --write '**/*.sol'",
"prettier:js": "prettier --write 'test/**/*.{js,ts}' '*.{js,ts}'",
"size": "yarn hardhat:compile && hardhat size-contracts",
"hardhat:test": "hardhat test",
Expand Down Expand Up @@ -107,11 +107,11 @@
"merkle-tree-solidity": "1.0.8",
"merkletreejs": "0.2.32",
"mocha": "^9.2.1",
"prettier": "2.3.2",
"prettier-plugin-solidity": "1.0.0-beta.17",
"prettier": "^2.0.0",
"prettier-plugin-solidity": "1.1.3",
"qs": "6.10.3",
"solhint": "3.3.6",
"solhint-plugin-prettier": "0.0.5",
"solhint": "3.6.2",
"solhint-plugin-prettier": "^0.0.5",
"solidity-coverage": "0.7.20",
"solidity-docgen": "0.5.13",
"ts-node": "10.1.0",
Expand Down
Loading

0 comments on commit 17b9afb

Please sign in to comment.