Skip to content

Merge pull request #86 from bandohq/chore/proxies-setup #3

Merge pull request #86 from bandohq/chore/proxies-setup

Merge pull request #86 from bandohq/chore/proxies-setup #3

Workflow file for this run

name: Build ABIs
on:
push:
branches: [main]
paths:
- '**/*.sol'
- 'deployments/**'
jobs:
build-abis:
runs-on: ubuntu-latest
name: Build ABIs
steps:
- uses: actions/checkout@v3
with:
submodules: recursive
- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
- name: Install packages
uses: actions/setup-node@v3
with:
node-version: '20.x'
- name: Build ABIs
run: |
yarn
forge build
- name: Checkout contract-abis
uses: actions/checkout@v3
with:
repository: bandohq/contract-abis
token: ${{ secrets.GH_PAT }}
path: abis_repo
- name: Copy and commit ABIs
run: |
rm -rf abis_repo/
mkdir -p abis_repo/abis
mkdir -p abis_repo/contracts
cp -r out/* abis_repo/abis/
cp -r deployments/* abis_repo/contracts/
cd abis
git config user.name "bando-bot"
git config user.email "[email protected]"
git add .
DATE=$(date '+%Y-%m-%d')
git diff --staged --quiet || git commit -m "Update BFP EVM Contracts $DATE"
VERSION=$(date '+%Y%m%d%H%M%S')
git tag -a "v$VERSION" -m "Release v$VERSION"
git push origin main --tags