Skip to content

Commit

Permalink
fix: ci working directory
Browse files Browse the repository at this point in the history
  • Loading branch information
JordyRo1 committed May 15, 2024
1 parent c5539e9 commit f5784df
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 5 deletions.
6 changes: 6 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,23 @@ jobs:
- uses: actions/checkout@v4
- uses: software-mansion/setup-scarb@v1
- name: Build contracts
working-directory: ./contracts
run: scarb build
- name: Archive contracts
working-directory: ./contracts
run: |
mkdir -p filtered_artifacts
find ./contracts/target/dev -type f -name '*.contract_class.json' -exec cp {} filtered_artifacts/ \;
- name: Generate checksums
working-directory: ./contracts
run: |
cd filtered_artifacts
for file in *; do
sha256sum "$file" > "$file.sha256"
md5sum "$file" > "$file.md5"
done
- name: Build artifact zip
working-directory: ./contracts
run: |
cd filtered_artifacts
zip -r ../hyperlane-starknet-${{ github.ref_name }}.zip .
Expand All @@ -39,11 +43,13 @@ jobs:
md5sum hyperlane-starknet-${{ github.ref_name }}.zip > hyperlane-starknet-${{ github.ref_name }}.CHECKSUM.MD5
- name: Find zip files
working-directory: ./contracts
run: |
find ./filtered_artifacts -type f -name '*.zip' -exec echo "::set-output name=zip_files::{}" \;
id: find_zip_files

- name: Release Artifact
working-directory: ./contracts
uses: softprops/action-gh-release@v1
with:
files: |
Expand Down
11 changes: 6 additions & 5 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,15 @@ on:
push:
pull_request:
jobs:
env:
working-directory: ./contracts
check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: software-mansion/setup-scarb@v1
- uses: foundry-rs/setup-snfoundry@v3
- run: scarb fmt --check
- run: scarb build
- run: snforge test
- working-directory: ./contracts
run: scarb fmt --check
- working-directory: ./contracts
run: scarb build
- working-directory: ./contracts
run: snforge test

0 comments on commit f5784df

Please sign in to comment.