-
Notifications
You must be signed in to change notification settings - Fork 230
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
0330c9d
commit 28017e5
Showing
10 changed files
with
3,757 additions
and
2,363 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,44 @@ | ||
name: Message Buffer IDL Check | ||
on: | ||
pull_request: | ||
paths: | ||
- pythnet/message_buffer/** | ||
push: | ||
branches: | ||
- main | ||
paths: | ||
- pythnet/message_buffer/** | ||
jobs: | ||
abi-check: | ||
name: Check Message Buffer IDL files are up to date | ||
runs-on: ubuntu-latest | ||
defaults: | ||
run: | ||
working-directory: pythnet/message_buffer | ||
steps: | ||
- name: Checkout sources | ||
uses: actions/checkout@v3 | ||
- uses: actions-rs/toolchain@v1 | ||
with: | ||
profile: minimal | ||
toolchain: nightly-2023-03-01 | ||
components: rustfmt, clippy | ||
- name: Install Solana | ||
run: | | ||
sh -c "$(curl -sSfL https://release.solana.com/v1.14.18/install)" | ||
echo "/home/runner/.local/share/solana/install/active_release/bin" >> $GITHUB_PATH | ||
- name: Install Anchor | ||
run: | | ||
cargo install --git https://github.com/coral-xyz/anchor --tag v0.27.0 anchor-cli --locked | ||
- name: Build and generate IDLs | ||
run: anchor build | ||
- name: Copy anchor target files | ||
run: cp ./target/idl/* idl/ && cp ./target/types/* idl/ | ||
- name: Run prettier (to avoid pre-commit failures) | ||
uses: actionsx/prettier@v2 | ||
with: | ||
args: --write idl/* | ||
- name: Check ABI changes | ||
# Fails if the IDL files are not up to date. Please use anchor build to regenerate the IDL files for | ||
# the current version of the contract and update idl directory. | ||
run: git diff --exit-code idl/* |
Oops, something went wrong.