Skip to content

Commit

Permalink
setup: improve rust github action
Browse files Browse the repository at this point in the history
  • Loading branch information
robert-zaremba committed May 20, 2023
1 parent 204ea5b commit 70d8d17
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 10 deletions.
1 change: 0 additions & 1 deletion .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,4 +36,3 @@ jobs:
- uses: gaurav-nelson/github-action-markdown-link-check@v1
with:
use-quiet-mode: "yes"
folder-path: "improvement-proposals, RFPs, specs"
33 changes: 24 additions & 9 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
@@ -1,21 +1,36 @@
name: Rust

on:
push:
branches: [ "master" ]
pull_request:
branches: [ "master" ]
branches: [master, main]
merge_group:
push:
branches: ["master"]

concurrency:
group: ci-${{ github.ref }}-${{ github.workflow }}
cancel-in-progress: true

env:
CARGO_TERM_COLOR: always

jobs:
build:
test:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Build
run: cargo build --verbose
- name: Run tests
run: cargo test --verbose
- uses: actions/checkout@v3
- uses: technote-space/[email protected]
with:
PATTERNS: |
**/**.rs
contracts/Cargo.lock
- name: Build
if: env.GIT_DIFF
run: cargo build --verbose
- name: Clippy
if: env.GIT_DIFF
run: cargo clippy
- name: Run tests
if: env.GIT_DIFF
run: cargo test --verbose

0 comments on commit 70d8d17

Please sign in to comment.