From b83c4fd0656d4b0f5a613e1d86697b6db6a690ef Mon Sep 17 00:00:00 2001 From: Damian Poddebniak Date: Tue, 20 Jul 2021 21:47:55 +0200 Subject: [PATCH] Use GitHub Actions --- .github/workflows/audit.yml | 22 ++++++++++++++++++++++ .github/workflows/rust.yml | 26 ++++++++++++++++++++++++++ 2 files changed, 48 insertions(+) create mode 100644 .github/workflows/audit.yml create mode 100644 .github/workflows/rust.yml diff --git a/.github/workflows/audit.yml b/.github/workflows/audit.yml new file mode 100644 index 0000000..c6f22ba --- /dev/null +++ b/.github/workflows/audit.yml @@ -0,0 +1,22 @@ +name: Audit +on: + schedule: + - cron: '0 0 * * *' + push: + branches: [ main ] + paths: + - '**/Cargo.toml' + - '**/Cargo.lock' + pull_request: + branches: [ main ] + paths: + - '**/Cargo.toml' + - '**/Cargo.lock' +jobs: + security_audit: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v1 + - uses: actions-rs/audit-check@v1 + with: + token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml new file mode 100644 index 0000000..13be55d --- /dev/null +++ b/.github/workflows/rust.yml @@ -0,0 +1,26 @@ +name: Rust + +on: + push: + branches: [ main ] + pull_request: + branches: [ main ] + +env: + CARGO_TERM_COLOR: always + +jobs: + build: + + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v2 + - name: Build + run: cargo build --verbose + - name: Test + run: cargo test --verbose + - name: Fmt + run: cargo fmt -- --check --config imports_granularity=Crate,group_imports=StdExternalCrate + - name: Clippy + run: cargo clippy