Skip to content

Commit

Permalink
adding CI step to build artifacts
Browse files Browse the repository at this point in the history
  • Loading branch information
zeroknots committed Oct 16, 2024
1 parent eba0e8f commit eca6f26
Show file tree
Hide file tree
Showing 2 changed files with 27 additions and 0 deletions.
10 changes: 10 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,13 @@ jobs:
foundry-fuzz-runs: 5000
foundry-profile: "test"
match-path: "test/**/*.sol"

release-artifacts:
needs: ["build"]
uses: "rhinestonewtf/reusable-workflows/.github/workflows/forge-release.yaml@main"
strategy:
matrix:
contract-name: ["Safe7579", "Safe7579Launchpad"]
with:
contract-name: ${{ matrix.contract-name }}
store-artifacts: true
17 changes: 17 additions & 0 deletions build-artifacts.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/bin/bash


# Check if a contract name is provided
if [ $# -eq 0 ]; then
echo "Please provide a contract name as an argument."
echo "Usage: $0 <ContractName>"
exit 1
fi

CONTRACT_NAME=$1

mkdir -p ./artifacts/$CONTRACT_NAME
forge build $CONTRACT_NAME
cp ./out/$CONTRACT_NAME.sol/* ./artifacts/$CONTRACT_NAME/.
forge verify-contract --show-standard-json-input $(cast address-zero) $CONTRACT_NAME > ./artifacts/$CONTRACT_NAME/verify.json

0 comments on commit eca6f26

Please sign in to comment.