refactor(bindings): change bindings generation and prepare to local testing tool #139
Workflow file for this run
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
name: check | |
on: | |
workflow_dispatch: | |
push: | |
branches: | |
- main | |
pull_request: | |
permissions: read-all | |
jobs: | |
markdown: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- run: | | |
sudo gem install mdl | |
mdl -s .github/linter/readme_style.rb README.md | |
mdl -s .github/linter/base_style.rb .github | |
mdl -s .github/linter/book_style.rb book | |
fmt: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: asdf-vm/actions/[email protected] | |
- run: scarb fmt --check | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: asdf-vm/actions/[email protected] | |
- run: scarb test --all-features | |
rust_bindings: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: dtolnay/rust-toolchain@stable | |
- uses: dtolnay/rust-toolchain@v1 | |
with: | |
toolchain: nightly-2024-08-28 | |
components: rustfmt | |
- uses: asdf-vm/actions/[email protected] | |
- name: Generate bindings | |
run: bash scripts/generate_bindings.sh | |
- name: Check for changes | |
run: | | |
git diff --exit-code || (echo "Error: Generated bindings are not up to date. Please run 'bash scripts/generate_bindings.sh' and commit the changes." && exit 1) |