feat: new github action for tagging releases

This commit is contained in:
rvcas 2025-02-18 18:10:16 -05:00 committed by Lucas
parent 0da4f70c39
commit d9a32c72eb
1 changed files with 41 additions and 0 deletions

41
.github/workflows/tag.yml vendored Normal file
View File

@ -0,0 +1,41 @@
name: Create Release Tag
on:
workflow_dispatch:
inputs:
bump:
description: 'Version bump type (major, minor, patch)'
required: true
default: 'patch'
type: choice
options:
- major
- minor
- patch
jobs:
publish:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
token: ${{ secrets.GITHUB_TOKEN }}
- name: Set up Rust
uses: Swatinem/rust-cache@v2
- name: Install cargo-release
run: cargo install cargo-release
- name: Configure Git
run: |
git config --global user.name "GitHub Action"
git config --global user.email "action@github.com"
- name: Run cargo release
env:
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_TOKEN }}
run: |
cargo release ${{ github.event.inputs.bump }} --execute