Skip to content

Commit 1a566c0

Browse files
authored
ci: further improve release workflow (#1139)
1 parent 11cd2fb commit 1a566c0

File tree

2 files changed

+13
-3
lines changed

2 files changed

+13
-3
lines changed

.github/workflows/finish_release.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,16 @@ jobs:
1717
ref: main
1818
fetch-depth: 0 # Otherwise merge will fail on account of not having history.
1919

20+
- name: Put back the 999-SNAPSHOT version on the release branch
21+
run: |
22+
git config user.name "Timefold Release Bot"
23+
git config user.email "[email protected]"
24+
git checkout $RELEASE_BRANCH_NAME
25+
mvn -Dfull versions:set -DnewVersion=999-SNAPSHOT
26+
sed -i "s/^timefold_solver_python_version.*=.*/timefold_solver_python_version = '999-dev0'/" setup.py
27+
git commit -am "build: move back to 999-SNAPSHOT"
28+
git push origin $RELEASE_BRANCH_NAME
29+
2030
- name: Update release branch
2131
shell: bash
2232
run: |

.github/workflows/release.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ jobs:
4848
fetch-depth: 0
4949
ref: ${{ github.event.inputs.sourceBranch }}
5050

51-
- name: Init release branch
51+
- name: Delete release branch (if exists)
5252
continue-on-error: true
5353
run: git push -d origin $RELEASE_BRANCH_NAME
5454

@@ -78,7 +78,7 @@ jobs:
7878
- name: Install Pip and build
7979
run: |
8080
python -m pip install --upgrade pip
81-
pip install build
81+
pip install build
8282
8383
# We skip tests in dry run, to make the process faster.
8484
# Technically, this goes against the main reason for doing a dry run; to eliminate potential problems.
@@ -118,4 +118,4 @@ jobs:
118118
119119
- name: Publish distribution to PyPI
120120
uses: pypa/gh-action-pypi-publish@release/v1
121-
if: ${{ github.event.inputs.dryRun == 'false' }}
121+
if: ${{ github.event.inputs.dryRun == 'false' }}

0 commit comments

Comments
 (0)