feat: real command handling #21
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: Publish | |
on: | |
push: | |
paths: | |
- '.github/workflows/publish.yml' | |
- 'Cargo.toml' | |
- 'src/**/*' | |
concurrency: | |
group: ${{ github.ref }}-${{ github.workflow }} | |
cancel-in-progress: true | |
jobs: | |
publish: | |
runs-on: ubuntu-latest | |
if: startsWith(github.ref, 'refs/tags/') | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions-rust-lang/[email protected] | |
- name: Cargo publish | |
uses: actions-rs/cargo@v1 | |
with: | |
command: publish | |
env: | |
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_TOKEN }} | |
# If this was successful, also make a "release" | |
- name: Create release | |
uses: softprops/action-gh-release@v2 | |
if: github.event_name != 'schedule' | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
# Release name is the tag name | |
name: ${{ github.ref_name }} | |
draft: false | |
generate_release_notes: true | |
prerelease: false |