Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update CI to run in parallel #41

Merged
merged 2 commits into from
Nov 7, 2022
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
47 changes: 19 additions & 28 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,8 @@ name: Continuous Integration

on:
push:
branches:
- main
paths-ignore:
- "**/README.md"
- "**/cd.yml"
Expand All @@ -16,7 +18,7 @@ env:

jobs:
continuous-integration:
name: Checks
name: cargo ${{ matrix.action.command }} - ${{ matrix.job.os }}
runs-on: ${{ matrix.job.os }}
strategy:
fail-fast: false
Expand All @@ -29,6 +31,19 @@ jobs:
- os: windows-latest
os-name: windows
binary-postfix: ".exe"
action:
- command: build
args: --release
- command: test
args: --all-features --workspace
- command: fmt
args: --all -- --check
- command: clippy
args: --all-targets --all-features --workspace -- -D warnings
- command: doc
args: --no-deps --document-private-items --all-features --workspace --examples
- command: publish
args: --dry-run
steps:
- name: Install dependencies
if: ${{ matrix.job.os == 'ubuntu-latest' }}
Expand All @@ -45,34 +60,10 @@ jobs:
- name: Build
uses: actions-rs/cargo@v1
with:
command: build
args: --release
- name: Test suite
uses: actions-rs/cargo@v1
with:
command: test
args: --all-features --workspace
- name: Format check
uses: actions-rs/cargo@v1
with:
command: fmt
args: --all -- --check
- name: Clippy check
uses: actions-rs/cargo@v1
with:
command: clippy
args: --all-targets --all-features --workspace -- -D warnings
- name: Docs
uses: actions-rs/cargo@v1
with:
command: doc
args: --no-deps --document-private-items --all-features --workspace --examples
- name: Publish dry run
uses: actions-rs/cargo@v1
with:
command: publish
args: --dry-run
command: ${{ matrix.action.command }}
args: ${{ matrix.action.args }}
- name: Archive artifact
if: ${{ matrix.action.command == 'build' }}
uses: actions/upload-artifact@v3
with:
name: espup-${{ matrix.job.os-name }}${{ matrix.job.binary-postfix }}
Expand Down