Skip to content

Commit 909d3ca

Browse files
authored
Add sync step before version bump in CI/CD workflow
Added a step to sync with the remote repository before bumping the version.
1 parent 60df26d commit 909d3ca

1 file changed

Lines changed: 6 additions & 3 deletions

File tree

.github/workflows/cicd.yml

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -208,6 +208,12 @@ jobs:
208208
with:
209209
fetch-depth: 0
210210

211+
- name: Sync with remote
212+
run: |
213+
git config user.name "Hai Chu"
214+
git config user.email "hai.m.chu@tuni.fi"
215+
git pull --rebase origin main
216+
211217
- name: Bump patch version
212218
id: set-version
213219
run: |
@@ -243,9 +249,6 @@ jobs:
243249

244250
- name: Commit updated version.json
245251
run: |
246-
git config user.name "Hai Chu"
247-
git config user.email "hai.m.chu@tuni.fi"
248-
git pull --rebase origin main
249252
git add version.json
250253
git commit -m "Bump version to ${{ steps.set-version.outputs.VERSION }} [skip ci]"
251254
git push

0 commit comments

Comments
 (0)