Skip to content

Commit

Permalink
configure CI so it runs the defined linters
Browse files Browse the repository at this point in the history
  • Loading branch information
plaintextpaco committed Oct 31, 2022
1 parent 2b1970f commit 308d288
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 36 deletions.
48 changes: 15 additions & 33 deletions .github/workflows/node.js.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,38 +6,20 @@ on:
pull_request:
branches: ['main']
jobs:
build:

monolith:
runs-on: ubuntu-latest

# strategy:
# matrix:
# node-version: [12.x, 14.x, 16.x]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/

env:
DEV_MNEMONIC: ${{ secrets.DEV_MNEMONIC }}
MUMBAI_URL: ${{secrets.MUMBAI_URL}}
FORK_URL: ${{ secrets.FORK_URL }}
steps:
- uses: actions/checkout@v2
- uses: borales/[email protected]
name: install
with:
cmd: install
- uses: borales/[email protected]
name: compile
with:
cmd: hardhat compile
- uses: borales/[email protected]
name: tests
with:
cmd: hardhat test --network hardhat
env:
FORK_URL: ${{ secrets.FORK_URL }}
DEV_MNEMONIC: ${{ secrets.DEV_MNEMONIC }}

- uses: borales/[email protected]
name: deploy
with:
cmd: rimraf deployments/mumbai/AludelFactory.json && yarn hardhat deploy --network mumbai --write true --tags templates
env:
DEV_MNEMONIC: ${{ secrets.DEV_MNEMONIC }}
MUMBAI_URL: ${{secrets.MUMBAI_URL}}
DEPLOY_CHAIN: mumbai
- uses: actions/checkout@v2
- uses: actions/setup-node@v3
with:
node-version: '16'
- run: yarn install --dev
- run: yarn compile
- run: yarn lint-sol
- run: yarn lint-ts
- run: yarn test-ts
- run: rm deployments/mumbai/AludelFactory.json && yarn hardhat deploy --network mumbai --tags templates
7 changes: 4 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@
"license": "MIT",
"scripts": {
"lint-sol": "git ls-files |grep '\\.sol$' |xargs ./node_modules/.bin/solhint",
"lint-ts": "git ls-files |grep '\\.[tj]s$'| xargs ./node_modules/.bin/eslint"
"lint-ts": "git ls-files |grep '\\.[tj]s$'| xargs ./node_modules/.bin/eslint",
"compile": "hardhat compile",
"test-ts": "hardhat --network hardhat test"
},
"devDependencies": {
"@nomiclabs/hardhat-ethers": "2.0.6",
Expand Down Expand Up @@ -64,7 +66,6 @@
"ds-math": "https://github.com/dapphub/ds-math",
"ds-test": "https://github.com/dapphub/ds-test",
"ds-token": "https://github.com/dapphub/ds-token",
"forge-std": "https://github.com/foundry-rs/forge-std",
"rimraf": "^3.0.2"
"forge-std": "https://github.com/foundry-rs/forge-std"
}
}

0 comments on commit 308d288

Please sign in to comment.