Skip to content

Commit

Permalink
Add CI checks: changelog and cargo publish
Browse files Browse the repository at this point in the history
  • Loading branch information
Richard Schneeman committed Nov 8, 2023
1 parent fd8c22f commit d6015a6
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 0 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/check_changelog.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
name: Check Changelog

on:
pull_request:
types: [opened, reopened, labeled, unlabeled, synchronize]

permissions:
contents: read

jobs:
check-changelog:
runs-on: ubuntu-latest
if: (!contains(github.event.pull_request.labels.*.name, 'skip changelog'))
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Check that CHANGELOG is touched
run: |
git fetch origin ${{ github.base_ref }} --depth 1 && \
git diff remotes/origin/${{ github.base_ref }} --name-only | grep CHANGELOG.md
14 changes: 14 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,20 @@ on:
pull_request:

jobs:
check_publishable:
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Update Rust toolchain
# Most of the time this will be a no-op, since GitHub releases new images every week
# which include the latest stable release of Rust, Rustup, Clippy and rustfmt.
run: rustup update
- name: Rust Cache
uses: Swatinem/rust-cache@v2.7.1
- name: Check cargo publish
run: cargo publish --dry-run

lint:
runs-on: ubuntu-22.04
steps:
Expand Down

0 comments on commit d6015a6

Please sign in to comment.