We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7dff531 commit 128c489Copy full SHA for 128c489
.github/workflows/release.yml
@@ -1,11 +1,6 @@
1
name: Publish Release
2
3
on:
4
- workflow_dispatch:
5
- inputs:
6
- tag:
7
- description: 'Tag for the release (e.g. v1.0.0)'
8
- required: false
9
push:
10
tags:
11
- "v*.*.*"
@@ -29,8 +24,7 @@ jobs:
29
24
- name: Build
30
25
run: |
31
26
# Set the version number for the build based on the tag or fallback to the branch name
32
- $version = if ("${{ inputs.tag }}" -match '^v(\d+\.\d+\.\d+)$') { "${{ inputs.tag }}.0" } else { "${{ github.ref_name }}.0" }
33
- $version = $version -replace '^v', '' # Remove the 'v' prefix if present, for example: v1.0.0 -> 1.0.0
27
+ $version = ${{github.ref_name}} -replace '^v', ''
34
28
35
Write-Host "Setting version to $version"
36
0 commit comments