mirror of
https://github.com/GuillemCastro/spotify-dl.git
synced 2024-11-10 05:20:25 +01:00
try to fix create-release again [skip ci]
This commit is contained in:
parent
0ec9b9eb72
commit
6b592c559a
1 changed files with 29 additions and 12 deletions
41
.github/workflows/create-release.yml
vendored
41
.github/workflows/create-release.yml
vendored
|
@ -19,9 +19,21 @@ jobs:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
- name: install Rust stable
|
- name: Run semver-diff
|
||||||
uses: dtolnay/rust-toolchain@stable
|
if: inputs.release_type == ''
|
||||||
|
id: semver-diff
|
||||||
|
uses: tj-actions/semver-diff@v3
|
||||||
|
with:
|
||||||
|
initial_release_type: ${{ inputs.release_type }}
|
||||||
|
- name: Install stable toolchain
|
||||||
|
if: steps.semver-diff.outputs.release_type != '' || inputs.release_type != ''
|
||||||
|
uses: actions-rs/toolchain@v1
|
||||||
|
with:
|
||||||
|
profile: minimal
|
||||||
|
toolchain: stable
|
||||||
|
override: true
|
||||||
- uses: actions/cache@v4
|
- uses: actions/cache@v4
|
||||||
|
if: steps.semver-diff.outputs.release_type != '' || inputs.release_type != ''
|
||||||
with:
|
with:
|
||||||
path: |
|
path: |
|
||||||
~/.cargo/bin/
|
~/.cargo/bin/
|
||||||
|
@ -29,17 +41,22 @@ jobs:
|
||||||
~/.cargo/registry/cache/
|
~/.cargo/registry/cache/
|
||||||
~/.cargo/git/db/
|
~/.cargo/git/db/
|
||||||
key: ${{ runner.os }}-cargo-cargo-bump
|
key: ${{ runner.os }}-cargo-cargo-bump
|
||||||
- name: Clean cargo-bump
|
- name: Bump Cargo.toml version
|
||||||
run: cargo uninstall cargo-bump || true
|
shell: bash
|
||||||
- name: Bump version
|
if: steps.semver-diff.outputs.release_type != '' || inputs.release_type != ''
|
||||||
id: cargo-bump
|
working-directory: '.'
|
||||||
uses: tj-actions/cargo-bump@v3
|
run: |
|
||||||
with:
|
cargo install cargo-bump --force
|
||||||
release_type: ${{ github.event.inputs.release_type }}
|
if [[ -z "${{ inputs.release_type }}" ]]; then
|
||||||
|
cargo bump ${{ steps.semver-diff.outputs.release_type }}
|
||||||
|
else
|
||||||
|
cargo bump ${{ inputs.release_type }}
|
||||||
|
fi
|
||||||
|
cargo update --workspace
|
||||||
- name: Commit changes
|
- name: Commit changes
|
||||||
uses: stefanzweifel/git-auto-commit-action@v4
|
uses: stefanzweifel/git-auto-commit-action@v4
|
||||||
with:
|
with:
|
||||||
commit_message: "Bump version to v${{ steps.cargo-bump.outputs.new_version }}"
|
commit_message: "Bump version to v${{ steps.semver-diff.outputs.new_version }}"
|
||||||
commit_user_name: "github-actions[bot]"
|
commit_user_name: "github-actions[bot]"
|
||||||
commit_user_email: "github-actions[bot]@users.noreply.github.com"
|
commit_user_email: "github-actions[bot]@users.noreply.github.com"
|
||||||
commit_author: "github-actions[bot] <github-actions[bot]@users.noreply.github.com>"
|
commit_author: "github-actions[bot] <github-actions[bot]@users.noreply.github.com>"
|
||||||
|
@ -47,5 +64,5 @@ jobs:
|
||||||
- name: Create tag
|
- name: Create tag
|
||||||
uses: rickstaa/action-create-tag@v1
|
uses: rickstaa/action-create-tag@v1
|
||||||
with:
|
with:
|
||||||
tag: v${{ steps.cargo-bump.outputs.new_version }}
|
tag: v${{ steps.semver-diff.outputs.new_version }}
|
||||||
message: "Bump version to v${{ steps.cargo-bump.outputs.new_version }}"
|
message: "Bump version to v${{ steps.semver-diff.outputs.new_version }}"
|
||||||
|
|
Loading…
Reference in a new issue