Skip to content

docs: add nethermind l1 audit report #14

docs: add nethermind l1 audit report

docs: add nethermind l1 audit report #14

on:
push:
branches:
- "master"
name: "Contract Artifacts (dev)"
jobs:
build:
name: "Push contract artifacts"
runs-on: "ubuntu-latest"
steps:
- name: "Checkout source code"
uses: "actions/checkout@v3"
with:
submodules: "recursive"
- name: "Install foundry nightly"
uses: "foundry-rs/foundry-toolchain@v1"
with:
version: "nightly"
- name: "Build L1 contracts"
run: |
forge build
- name: "Build L2 contracts"
run: |
./scripts/compile_l2_with_docker.sh
- name: "Set up deploy key for artifacts repo"
uses: "webfactory/[email protected]"
with:
ssh-private-key: "${{ secrets.ARTIFACTS_DEV_KEY }}"
- name: Push artifacts
run: |
COMMIT_HASH="$(git log -1 --format="%H")"
git clone --depth=1 "[email protected]:zkLend/zklend-contract-artifacts-dev" ./artifacts
mkdir -p ./artifacts/zend-token/$COMMIT_HASH
cp ./out/ZendToken.sol/ZendToken.json ./artifacts/zend-token/$COMMIT_HASH/
cp ./out/TokenEscrow.sol/TokenEscrow.json ./artifacts/zend-token/$COMMIT_HASH/
cp ./out/TransparentUpgradeableProxy.sol/TransparentUpgradeableProxy.json ./artifacts/zend-token/$COMMIT_HASH/
cp ./out/ProxyAdmin.sol/ProxyAdmin.json ./artifacts/zend-token/$COMMIT_HASH/
cp ./build/ERC20.json ./artifacts/zend-token/$COMMIT_HASH/StarknetERC20.json
(cd ./artifacts/zend-token/ && rm -rf ./latest && ln -s ./$COMMIT_HASH ./latest)
cd ./artifacts
git config user.name 'github-actions[bot]'
git config user.email 'github-actions[bot]@users.noreply.github.com'
git add .
git commit -m "artifacts: add contract artifacts from CI"
git push