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

ci: run pr checks only on prs #232

Merged
merged 1 commit into from
Sep 10, 2024
Merged
Show file tree
Hide file tree
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
28 changes: 3 additions & 25 deletions .github/workflows/ci.yml → .github/workflows/build-platforms.yml
Original file line number Diff line number Diff line change
@@ -1,29 +1,10 @@
name: Continuous Integration
on:
push:
branches:
- main
pull_request:
name: Build Platforms
# This workflow is triggered on pushes to the repository.
on: [ pull_request, workflow_call, workflow_dispatch ]

jobs:
pr_check:
name: Pull Request Check
uses: ./.github/workflows/pull-request.yml

semver:
name: cargo-semver-checks
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2

- name: check semver
uses: obi1kenobi/[email protected]

linux:
name: linux
needs: pr_check
runs-on: ubuntu-latest
strategy:
#fail-fast: true
Expand Down Expand Up @@ -70,7 +51,6 @@ jobs:

windows:
name: windows
needs: pr_check
runs-on: windows-latest
strategy:
matrix:
Expand All @@ -95,10 +75,8 @@ jobs:
- name: clippy (default features)
run: cargo clippy -- -D warnings


macos:
name: macos
needs: pr_check
runs-on: macos-latest
strategy:
matrix:
Expand Down
7 changes: 2 additions & 5 deletions .github/workflows/pull-request.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: Pull request
# This workflow is triggered on pushes to the repository.
on: [ pull_request, workflow_call, workflow_dispatch ]
on: [ pull_request ]

jobs:
check:
Expand All @@ -19,9 +19,8 @@ jobs:
./convco check ${{ github.event.pull_request.base.sha }}..${{ github.event.pull_request.head.sha }}
rm convco
check_fmt_clippy:
check_fmt:
name: Check Format
needs: check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
Expand All @@ -31,6 +30,4 @@ jobs:
- name: cargo-fmt
run: cargo fmt --all --check

#- name: clippy
# run: cargo clippy --all-features -- -D warnings

18 changes: 18 additions & 0 deletions .github/workflows/semver-checks.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Semver Checks
on:
push:
branches:
- main
pull_request:

jobs:
semver:
name: cargo-semver-checks
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@stable
- uses: Swatinem/rust-cache@v2

- name: check semver
uses: obi1kenobi/[email protected]