Release crate #4
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: Release crate | |
on: | |
workflow_dispatch: | |
inputs: | |
version: | |
description: "major/minor/patch or semver" | |
required: false | |
default: "patch" | |
concurrency: release-crate | |
jobs: | |
publish: | |
runs-on: ubuntu-latest | |
permissions: | |
contents: write | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Set git credentials | |
run: | | |
git config user.name github-actions | |
git config user.email github-actions@github.com | |
- name: Crates publish | |
uses: kaleidawave/crates-release-gh-action@main | |
id: release | |
with: | |
version: ${{ github.event.inputs.version }} | |
crates-token: ${{ secrets.CARGO_REGISTRY_TOKEN }} | |
- name: Push updated Cargo.toml | |
run: | | |
git add . | |
git commit -m "Release: ${{ steps.release.outputs.new-versions-description }}" | |
git tag "release/${{ steps.release.outputs.new-version }}" | |
git push --tags origin main | |
- name: Discord | |
uses: dusmartijngames/discord-webhook-notify@master | |
with: | |
severity: info | |
text: "Released version ${{ steps.release.outputs.new-versions-description }}" | |
webhookUrl: ${{ secrets.DISCORD_WEBHOOK_ENDPOINT }} |