-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(ethers): change to ethers and updgrade dependencies
feat(upgrade): re-create project with hardhat & ethers removing truffle and web3 chore: re-adds contracts chore: adds dev rules chore(contracts): fixes solidity lint errors chore(test): re-adds tests chore(upgrade): adds deployment tools chore(upgrade): add smock for contract mocking chore(upgrade): removes sol tests chore(upgrade): fixe pre-commit and update readme chore(upgrade): add more eslint rules chore(deps): move typechain to deps chore(upgrade): unignore dist from npm i chore(ethers): return util token for manual testing 👿
- Loading branch information
Showing
111 changed files
with
5,264 additions
and
16,767 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
import type { UserConfig } from '@commitlint/types'; | ||
|
||
const Configuration: UserConfig = { | ||
/* | ||
* Resolve and load @commitlint/config-conventional from node_modules. | ||
* Referenced packages must be installed | ||
*/ | ||
extends: ['@commitlint/config-conventional'], | ||
/* | ||
* Resolve and load conventional-changelog-atom from node_modules. | ||
* Referenced packages must be installed | ||
*/ | ||
// parserPreset: 'conventional-changelog-atom', | ||
/* | ||
* Resolve and load @commitlint/format from node_modules. | ||
* Referenced package must be installed | ||
*/ | ||
// formatter: '@commitlint/format', | ||
/* | ||
* Any rules defined here will override rules from @commitlint/config-conventional | ||
*/ | ||
rules: {}, | ||
/* | ||
* Functions that return true if commitlint should ignore the given message. | ||
*/ | ||
// ignores: [(commit) => commit === ''], | ||
/* | ||
* Whether commitlint uses the default ignore rules. | ||
*/ | ||
// defaultIgnores: true, | ||
/* | ||
* Custom URL to show upon failure | ||
*/ | ||
helpUrl: | ||
'https://github.com/conventional-changelog/commitlint/#what-is-commitlint', | ||
/* | ||
* Custom prompt configs | ||
*/ | ||
// prompt: { | ||
// messages: {}, | ||
// questions: { | ||
// type: { | ||
// description: 'please input type:', | ||
// }, | ||
// }, | ||
// }, | ||
}; | ||
|
||
export default Configuration; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
node_modules | ||
dist | ||
types/truffle-contracts | ||
artifacts | ||
cache | ||
coverage |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,56 @@ | ||
module.exports = { | ||
extends: [ | ||
"eslint:recommended", | ||
"plugin:mocha/recommended", | ||
"plugin:@typescript-eslint/eslint-recommended", | ||
"plugin:@typescript-eslint/recommended", | ||
"plugin:@typescript-eslint/recommended-requiring-type-checking", | ||
"prettier", | ||
], | ||
env: { | ||
browser: false, | ||
es2021: true, | ||
mocha: true, | ||
node: true, | ||
}, | ||
// root: true, | ||
plugins: ["@typescript-eslint", "mocha"], | ||
parser: "@typescript-eslint/parser", | ||
parserOptions: { | ||
ecmaVersion: "latest", | ||
sourceType: "module", | ||
tsconfigRootDir: __dirname, | ||
project: "./tsconfig.json", | ||
}, | ||
rules: { | ||
"lines-between-class-members": "error", | ||
"padding-line-between-statements": [ | ||
"error", | ||
{ blankLine: "always", prev: "*", next: "return" }, | ||
], | ||
"prefer-const": [ | ||
"error", | ||
{ | ||
destructuring: "any", | ||
ignoreReadBeforeAssign: false, | ||
}, | ||
], | ||
"@typescript-eslint/no-unused-vars": ["error", { argsIgnorePattern: "^_" }], | ||
"@typescript-eslint/naming-convention": [ | ||
"error", | ||
{ | ||
selector: ["variable", "function"], | ||
format: ["camelCase"], | ||
}, | ||
{ | ||
selector: ["variable"], | ||
modifiers: ["const"], | ||
format: ["camelCase", "UPPER_CASE"], | ||
}, | ||
], | ||
"mocha/no-skipped-tests": "warn", | ||
"mocha/no-empty-description": "off", | ||
"mocha/no-exclusive-tests": "error", | ||
"@typescript-eslint/no-unsafe-member-access": "warn" | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,16 @@ | ||
node_modules/ | ||
build/ | ||
dist/ | ||
package-lock.json | ||
.npmignore | ||
.eslintcache | ||
|
||
node_modules | ||
.env | ||
coverage | ||
coverage.json | ||
typechain | ||
typechain-types | ||
|
||
#Hardhat files | ||
cache | ||
artifacts | ||
/build | ||
/dist | ||
/contracts-exposed |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#!/usr/bin/env sh | ||
. "$(dirname -- "$0")/_/husky.sh" | ||
|
||
npx --no -- commitlint --edit |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,6 @@ | ||
#!/bin/sh | ||
. "$(dirname "$0")/_/husky.sh" | ||
#!/usr/bin/env sh | ||
. "$(dirname -- "$0")/_/husky.sh" | ||
|
||
if [ -d "$HOME/.nvm" ]; then | ||
export NVM_DIR="$HOME/.nvm" | ||
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" | ||
fi | ||
|
||
npm run lint:ts | ||
npm run lint:sol | ||
npm run prettier:fix | ||
npm run format | ||
npm run lint | ||
npx lint-staged |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
#!/usr/bin/env sh | ||
. "$(dirname -- "$0")/_/husky.sh" | ||
|
||
npm run compile | ||
npm run test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
coverage | ||
.gitignore | ||
!dist | ||
!typechain-types | ||
test |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,6 @@ | ||
.gitignore | ||
.prettierignore | ||
package.json | ||
package-lock.json | ||
prettierrc.json5 | ||
Readme.md | ||
tsconfig.json | ||
.eslintignore | ||
.eslintrc | ||
node_modules | ||
.solhint.json | ||
.solhintignore | ||
webpack.config.js | ||
build | ||
dist | ||
types/truffle-contracts | ||
pull_request_template.md | ||
artifacts | ||
cache | ||
coverage* | ||
gasReporterOutput.json | ||
typechain-types |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
{ | ||
"overrides": [ | ||
{ | ||
"files": "*.ts", | ||
"options": { | ||
"semi": true, | ||
"singleQuote": true, | ||
"tabWidth": 2, | ||
"trailingComma": "es5" | ||
} | ||
}, | ||
{ | ||
"files": "*.sol", | ||
"options": { | ||
"trailingComma": "none", | ||
"tabWidth": 4, | ||
"semi": true, | ||
"singleQuote": false | ||
} | ||
} | ||
] | ||
} |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,32 @@ | ||
{ | ||
"extends": "solhint:recommended", | ||
"rules": { | ||
"compiler-version": ["error","^0.6.12"], | ||
"mark-callable-contracts": ["off"], | ||
"reason-string": ["warn",{"maxLength":32}] | ||
} | ||
} | ||
"extends": "solhint:recommended", | ||
"plugins": [ | ||
"prettier" | ||
], | ||
"rules": { | ||
"prettier/prettier": "error", | ||
"compiler-version": [ | ||
"error", | ||
"^0.6.12" | ||
], | ||
"avoid-suicide": "error", | ||
"avoid-sha3": "warn", | ||
"private-vars-leading-underscore": [ | ||
"error", | ||
{ | ||
"strict": false | ||
} | ||
], | ||
"code-complexity": [ | ||
"error", | ||
7 | ||
], | ||
"constructor-syntax": "error", | ||
"func-visibility": [ | ||
"warn", | ||
{ | ||
"ignoreConstructors": true | ||
} | ||
] | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
contracts/0x | ||
node_modules |
Oops, something went wrong.