first iteration of refactoring strain's py code to rust #56
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: Static Analysis | |
on: | |
pull_request: | |
types: [opened, synchronize, reopened] | |
paths-ignore: ['**/Dockerfile', '**/public/**', '**/.*ignore', '**/*.toml'] | |
push: | |
branches: [main, staging] | |
paths-ignore: ['**/Dockerfile', '**/public/**', '**/.*ignore', '**/*.toml'] | |
jobs: | |
pre-commit: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
steps: | |
# Checkout the repository code | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
# Set up Python environment | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
# Install Rust toolchain and components | |
- name: Install Rust toolchain (nightly-2023-12-21) with Clippy and Rustfmt | |
run: | | |
rustup toolchain install nightly-2023-12-21 | |
rustup component add clippy --toolchain nightly-2023-12-21 | |
rustup component add rustfmt --toolchain nightly-2023-12-21 | |
curl -L https://risczero.com/install | bash | |
~/.risc0/bin/rzup install | |
cargo risczero --version | |
# Run pre-commit hooks | |
- name: Run pre-commit hooks | |
uses: pre-commit/[email protected] | |
with: | |
extra_args: --all-files |