Skip to content

Commit 79fb632

Browse files
Merge pull request #447 from dekusms/dev
Modify staging version bump workflow triggers and checks
2 parents 5d2a378 + 981adfc commit 79fb632

File tree

1 file changed

+16
-9
lines changed

1 file changed

+16
-9
lines changed

.github/workflows/staging-version-bump.yml

Lines changed: 16 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,22 @@
11
name: Bump Version
22

33
on:
4-
pull_request:
5-
types:
6-
- closed
4+
push:
75
branches:
8-
- staging-release
6+
- staging
97
workflow_dispatch:
108

119
jobs:
1210
bump-version:
13-
if: github.event.pull_request.merged == true
1411
runs-on: ubuntu-latest
1512
permissions:
1613
contents: write
1714
pull-requests: write
1815

16+
defaults:
17+
run:
18+
working-directory: ${{ github.workspace }}
19+
1920
steps:
2021
- name: Checkout repository
2122
uses: actions/checkout@v4
@@ -38,21 +39,27 @@ jobs:
3839
with:
3940
python-version: '3.x'
4041

42+
- name: Verify versions.properties exists
43+
run: |
44+
if [ ! -f versions.properties ]; then
45+
echo "ERROR: versions.properties not found in ${{ github.workspace }}"
46+
ls -la
47+
exit 1
48+
fi
49+
echo "Found versions.properties:"
50+
cat versions.properties
51+
4152
- name: Run bump_version.py
4253
id: bump
4354
run: |
4455
python bump_version.py \
4556
"${{ steps.previoustag.outputs.tag }}" \
4657
"${{ steps.branch.outputs.name }}" \
4758
> version.properties
48-
# Store multiline output as a GitHub output using EOF delimiter
4959
echo "result<<EOF" >> $GITHUB_OUTPUT
5060
cat version.properties >> $GITHUB_OUTPUT
5161
echo "EOF" >> $GITHUB_OUTPUT
5262
53-
- name: Write version.properties
54-
run: echo "${{ steps.bump.outputs.result }}" > version.properties
55-
5663
- name: Commit and push version.properties
5764
run: |
5865
git config user.name "github-actions[bot]"

0 commit comments

Comments
 (0)