Bump clap from 4.5.4 to 4.5.7 #290
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: ci | |
on: | |
pull_request: | |
types: | |
- opened | |
- synchronize | |
- reopened | |
push: | |
branches: | |
- master | |
tags: | |
- "[0-9]+.[0-9]+.[0-9]+*" | |
jobs: | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: dtolnay/rust-toolchain@stable | |
with: | |
components: clippy, rustfmt | |
- uses: Swatinem/rust-cache@v2 | |
- run: cargo fmt --all -- --check | |
- run: cargo check | |
- run: cargo clippy -- -D warnings | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: dtolnay/rust-toolchain@stable | |
- uses: Swatinem/rust-cache@v2 | |
- run: cargo test | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@master | |
- uses: actions/checkout@v4 | |
- uses: dtolnay/rust-toolchain@stable | |
- uses: Swatinem/rust-cache@v2 | |
- run: cargo build | |
release: | |
needs: | |
- build | |
- lint | |
- test | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: | |
- macos-latest | |
- ubuntu-latest | |
include: | |
- os: macos-latest | |
target: x86_64-apple-darwin | |
- os: ubuntu-latest | |
target: x86_64-unknown-linux-gnu | |
if: startsWith(github.ref, 'refs/tags/') | |
steps: | |
- uses: actions/checkout@master | |
- uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: stable | |
target: ${{ matrix.target }} | |
override: true | |
- name: Get tag | |
id: tag | |
run: "echo ::set-output name=TAG::${GITHUB_REF##*/}" | |
- name: Build in release mode | |
uses: actions-rs/cargo@v1 | |
with: | |
command: build | |
args: --release --all-features --target ${{ matrix.target }} | |
- name: Package the binary | |
run: > | |
tar cfz labelr-${{ steps.tag.outputs.TAG }}-${{ matrix.target }}.tar.gz | |
-C target/${{ matrix.target }}/release/ | |
labelr | |
- name: Upload artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: labelr-${{ steps.tag.outputs.TAG }}-${{ matrix.target }}.tar.gz | |
path: labelr-${{ steps.tag.outputs.TAG }}-${{ matrix.target }}.tar.gz | |
- name: Upload CHANGELOG.md | |
uses: actions/upload-artifact@v4 | |
with: | |
name: CHANGELOG.md | |
path: CHANGELOG.md | |
if: matrix.os == 'ubuntu-latest' | |
publish: | |
needs: | |
- release | |
runs-on: ubuntu-latest | |
if: startsWith(github.ref, 'refs/tags/') | |
steps: | |
- name: Download all workflow run artifacts | |
uses: actions/download-artifact@v4 | |
- name: Get Changelog Entry | |
id: changelog_reader | |
uses: mindsers/changelog-reader-action@v2 | |
with: | |
path: CHANGELOG.md/CHANGELOG.md | |
- name: Publish the release | |
uses: softprops/action-gh-release@v2 | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
with: | |
body: ${{ steps.changelog_reader.outputs.changes }} |