Skip to content
This repository was archived by the owner on Sep 24, 2024. It is now read-only.

Commit 7dfbcbf

Browse files
committed
Add manual input to release workflow
- Push tag only after bosh release is created successfully
1 parent b9ef69c commit 7dfbcbf

File tree

1 file changed

+15
-3
lines changed

1 file changed

+15
-3
lines changed

.github/workflows/bosh-release.yml

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,10 @@ name: Create BOSH release
33
on:
44
# Allows you to run this workflow manually from the Actions tab ONLY
55
workflow_dispatch:
6+
inputs:
7+
release_tag:
8+
required: false
9+
description: Tag version to be released, e.g. '0.0.1'
610

711
jobs:
812
build:
@@ -13,12 +17,13 @@ jobs:
1317
with:
1418
submodules: recursive
1519

16-
- name: Bump version and push tag
20+
- name: Bump version and create tag
1721
id: tag_version
1822
uses: mathieudutour/github-tag-action@v6.0
1923
with:
2024
github_token: ${{ secrets.GITHUB_TOKEN }}
21-
dry_run: false
25+
custom_tag: ${{ github.event.inputs.release_tag }}
26+
dry_run: true
2227

2328
- name: Install BOSH CLI
2429
run: |
@@ -38,7 +43,14 @@ jobs:
3843
VERSION=${{ steps.tag_version.outputs.new_version }}
3944
4045
bosh create-release --final --version "$VERSION" --tarball "go-cf-api-boshrelease-$VERSION.tgz"
41-
46+
47+
- name: Push Tag
48+
id: push_tag
49+
uses: mathieudutour/github-tag-action@v6.0
50+
with:
51+
github_token: ${{ secrets.GITHUB_TOKEN }}
52+
custom_tag: ${{ steps.tag_version.outputs.new_version }}
53+
4254
- name: Publish Release
4355
uses: softprops/action-gh-release@v1
4456
with:

0 commit comments

Comments
 (0)