Skip to content

This is 0.6.0

This is 0.6.0 #64

Workflow file for this run

name: build
on: [push, pull_request]
env:
RUSTFLAGS: --deny warnings
jobs:
build:
runs-on: ubuntu-latest
strategy:
matrix:
toolchain: [stable, beta, nightly]
steps:
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ matrix.toolchain }}
components: clippy, rustfmt
- name: Rustfmt
run: cargo fmt -- --check
- name: Clippy
continue-on-error: ${{ matrix.toolchain == 'nightly' }}
run: cargo clippy --workspace --all-targets
check-version:
needs: build
if: startsWith(github.ref, 'refs/tags/')
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Calculate version from tag
id: version
run: echo "value=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
- name: Check tag against package version
run: grep '^version = "${{ steps.version.outputs.value }}"$' Cargo.toml
release:
needs: check-version
runs-on: macos-latest
strategy:
matrix:
target: [x86_64-apple-darwin, aarch64-apple-darwin]
steps:
- uses: actions/checkout@v4
- uses: extractions/setup-crate@v1
with:
owner: rossmacarthur
name: powerpack
- uses: dtolnay/rust-toolchain@stable
with:
target: ${{ matrix.target }}
- name: Calculate version from tag
id: version
run: echo "value=${GITHUB_REF#refs/tags/}" >> $GITHUB_OUTPUT
- name: Archive
id: archive
run: |
archive=crates-${{ steps.version.outputs.value }}-${{ matrix.target }}.alfredworkflow
powerpack package --target ${{ matrix.target }}
mv target/workflow/crates.alfredworkflow "$archive"
echo "path=$archive" >> $GITHUB_OUTPUT
- uses: softprops/action-gh-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
files: ${{ steps.archive.outputs.path }}