forked from 5afe/eip4337-diatomic
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit 123fd47
Showing
35 changed files
with
12,226 additions
and
0 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,6 @@ | ||
MNEMONIC="" | ||
# Used for infura based network | ||
INFURA_KEY="" | ||
# Used for custom network | ||
NODE_URL="" | ||
ETHERSCAN_API_KEY="" |
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 @@ | ||
*.sol linguist-language=Solidity |
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,34 @@ | ||
--- | ||
name: Bug report | ||
about: Bug report about the Safe smart contracts | ||
|
||
--- | ||
|
||
## Prerequisites | ||
|
||
- First, many thanks for taking part in the community and helping us improve. We appreciate that a lot. | ||
- Support questions are better asked in our Gitter chat: https://gitter.im/gnosis/Safe | ||
- Please ensure the issue isn't already reported. | ||
|
||
*Please delete the above section and the instructions in the sections below before submitting* | ||
|
||
## Description | ||
|
||
Please describe considely the bug you have found, and what you expect instead. | ||
|
||
## Environment | ||
|
||
- Compiler version: | ||
- Compiler options (if applicable, e.g. optimizer enabled): | ||
- Framework/IDE (e.g. Truffle or Remix): | ||
- EVM execution environment / backend / blockchain client: | ||
- Operating system: | ||
|
||
## Steps to reproduce | ||
|
||
If applicable, please provide a *minimal* source code example to trigger the bug you have found. | ||
Provide as much information as necessary to reproduce the bug. | ||
|
||
## Additional context | ||
|
||
Add any other context about the problem here. |
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,29 @@ | ||
--- | ||
name: Feature request | ||
about: Suggest an idea or feature request for the Safe smart contracts project | ||
|
||
--- | ||
|
||
## Prerequisites | ||
|
||
- First, many thanks for taking part in the community and helping us improve. We appreciate that a lot. | ||
- Support questions are better asked in our Gitter chat: https://gitter.im/gnosis/Safe | ||
- Please ensure the issue isn't already reported. | ||
|
||
*Please delete the above section and the instructions in the sections below before submitting* | ||
|
||
## Context / issue | ||
|
||
In case your feature request related to a problem, please add clear and concise description of what the issue is. | ||
|
||
## Proposed solution | ||
|
||
Please add a clear and concise description of what you want to happen. | ||
|
||
## Alternatives | ||
|
||
Please add a clear and concise description of any alternative solutions or features you've considered. | ||
|
||
## Additional context | ||
|
||
Add any other context or screenshots about the feature request here. |
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,81 @@ | ||
name: safe-contracts | ||
on: [push] | ||
|
||
jobs: | ||
tests: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-node@v2 | ||
with: | ||
node-version: 16.7.0 | ||
- uses: actions/cache@v2 | ||
with: | ||
path: "**/node_modules" | ||
key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }} | ||
- run: yarn --frozen-lockfile | ||
- run: yarn build | ||
- run: yarn coverage | ||
- name: Coveralls | ||
uses: coverallsapp/github-action@master | ||
with: | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
lint: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-node@v2 | ||
with: | ||
node-version: 16.7.0 | ||
- uses: actions/cache@v2 | ||
with: | ||
path: "**/node_modules" | ||
key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }} | ||
- run: yarn --frozen-lockfile | ||
- run: yarn lint:sol | ||
tests-other: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
contract-name: ["GnosisSafeL2"] | ||
env: | ||
SAFE_CONTRACT_UNDER_TEST: ${{ matrix.contract-name }} | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-node@v2 | ||
with: | ||
node-version: 16.7.0 | ||
- uses: actions/cache@v2 | ||
with: | ||
path: "**/node_modules" | ||
key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }} | ||
- run: yarn --frozen-lockfile | ||
- run: yarn build | ||
- run: yarn coverage | ||
- name: Coveralls | ||
uses: coverallsapp/github-action@master | ||
with: | ||
github-token: ${{ secrets.GITHUB_TOKEN }} | ||
benchmarks: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
solidity: ["0.7.6", "0.8.2"] | ||
include: | ||
- solidity: "0.8.2" | ||
settings: '{"viaIR":true,"optimizer":{"enabled":true,"runs":10000}}' | ||
env: | ||
SOLIDITY_VERSION: ${{ matrix.solidity }} | ||
SOLIDITY_SETTINGS: ${{ matrix.settings }} | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- uses: actions/setup-node@v2 | ||
with: | ||
node-version: 16.7.0 | ||
- uses: actions/cache@v2 | ||
with: | ||
path: "**/node_modules" | ||
key: ${{ runner.os }}-modules-${{ hashFiles('**/yarn.lock') }} | ||
- run: (yarn --frozen-lockfile && yarn build && yarn hardhat codesize --contractname GnosisSafe && yarn benchmark) || echo "Benchmark failed" |
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,14 @@ | ||
build/ | ||
node_modules/ | ||
.DS_Store | ||
.zos.session | ||
.openzeppelin/.session | ||
deployments/ | ||
env/ | ||
dist/ | ||
.env | ||
bin/ | ||
solc | ||
coverage/ | ||
coverage.json | ||
yarn-error.log |
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 @@ | ||
_ |
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,21 @@ | ||
#!/bin/sh | ||
. "$(dirname "$0")/_/husky.sh" | ||
|
||
# Redirect output to stderr. | ||
exec 1>&2 | ||
|
||
# prevent it.only or describe.only commited | ||
if [ "$allowonlytests" != "true" ] && | ||
test $(git diff --cached | grep -E "\b(it|describe).only\(" | wc -l) != 0 | ||
then | ||
cat <<\EOF | ||
Error: Attempt to add it.only or describe.only - which may disable all other tests | ||
If you know what you are doing you can disable this check using: | ||
git config hooks.allowonlytests true | ||
EOF | ||
exit 1 | ||
fi | ||
|
||
exit 0 |
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 @@ | ||
v16.7.0 |
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,20 @@ | ||
{ | ||
"overrides": [ | ||
{ | ||
"files": "*.sol", | ||
"options": { | ||
"printWidth": 140, | ||
"tabWidth": 4, | ||
"useTabs": false, | ||
"singleQuote": false, | ||
"bracketSpacing": false, | ||
"explicitTypes": "always" | ||
} | ||
} | ||
], | ||
"tabWidth": 2, | ||
"printWidth": 140, | ||
"trailingComma": "all", | ||
"singleQuote": true, | ||
"semi": false | ||
} |
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,10 @@ | ||
module.exports = { | ||
skipFiles: [], | ||
mocha: { | ||
grep: '@skip-on-coverage', // Find everything with this tag | ||
invert: true, // Run the grep's inverse set. | ||
}, | ||
providerOptions: { | ||
callGasLimit: '0x6691b7', | ||
}, | ||
} |
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,20 @@ | ||
{ | ||
"extends": "solhint:recommended", | ||
"plugins": [ | ||
"prettier" | ||
], | ||
"rules": { | ||
"compiler-version": "off", | ||
"func-visibility": [ | ||
"warn", | ||
{ | ||
"ignoreConstructors": true | ||
} | ||
], | ||
"prettier/prettier": "error", | ||
"not-rely-on-time": "off", | ||
"reason-string": "off", | ||
"no-empty-blocks": "off", | ||
"avoid-low-level-calls": "off" | ||
} | ||
} |
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,18 @@ | ||
{ | ||
"version": "0.2.0", | ||
"configurations": [ | ||
{ | ||
"name": "truffle test (ganache running)", | ||
"type": "node", | ||
"request": "launch", | ||
"program": "${workspaceRoot}/node_modules/truffle/build/cli.bundled.js", | ||
"args": [ | ||
"test" | ||
], | ||
"cwd": "${workspaceRoot}", | ||
"outFiles": [ | ||
"${workspaceRoot}/test/**/*" | ||
], | ||
}, | ||
] | ||
} |
Oops, something went wrong.