Skip to content

Commit afba91c

Browse files
committed
Release 2.0.0 - finally
After a long journey of debugging, it turns out that the problem is that 'git shortlog --summary --email' does not display any authors anymore since today, when run in GitHub Actions. The fix for now is to make 'make authors' tolerant against that, by dececting there are no authors and then leaving the AUTHORS.md file unchanged. Signed-off-by: Andreas Maier <maiera@de.ibm.com>
1 parent ae421af commit afba91c

File tree

2 files changed

+1
-25
lines changed

2 files changed

+1
-25
lines changed

.github/workflows/publish.yml

-24
Original file line numberDiff line numberDiff line change
@@ -155,32 +155,13 @@ jobs:
155155
# fetch-depth 0 checks out all history for all branches and tags.
156156
# This is needed to get the authors from git.
157157
fetch-depth: 0
158-
159158
- name: Set up Python 3.10
160159
uses: actions/setup-python@v5
161160
with:
162161
python-version: "3.10"
163-
164-
- name: Debug - Display git log count
165-
run: |
166-
git log --oneline | wc
167-
168-
- name: Debug - Display git authors
169-
run: |
170-
git shortlog --summary --email
171-
172-
- name: Debug - Display git status
173-
run: |
174-
git status
175-
176162
- name: Development setup
177163
run: |
178164
make develop
179-
180-
- name: Debug - Display git status
181-
run: |
182-
git status
183-
184165
- name: Display Python packages
185166
run: |
186167
pip list
@@ -192,11 +173,6 @@ jobs:
192173
- name: Display the distribution directory
193174
run: |
194175
ls -l dist
195-
196-
- name: Fail
197-
run: |
198-
false
199-
200176
- name: Publish distribution to PyPI
201177
if: startsWith(github.ref, 'refs/tags')
202178
uses: pypa/gh-action-pypi-publish@release/v1

Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -479,7 +479,7 @@ AUTHORS.md: _always
479479
sh -c "ls -l log.tmp"
480480
sh -c "cat log.tmp >>AUTHORS.md.tmp"
481481
echo '```' >>AUTHORS.md.tmp
482-
sh -c "if ! grep -q '[^[:space:]]' log.tmp; then echo 'Warning - git shortlog does not display any authors - leaving AUTHORS.md file unchanged'; else if ! diff -q AUTHORS.md.tmp AUTHORS.md; then echo 'Updating AUTHORS.md:'; diff AUTHORS.md.tmp AUTHORS.md; mv AUTHORS.md.tmp AUTHORS.md; else echo 'AUTHORS.md was already up to date'; fi; fi"
482+
sh -c "if ! grep -q '[^[:space:]]' log.tmp; then echo 'Warning - git shortlog does not display any authors - leaving AUTHORS.md file unchanged'; else if ! diff -q AUTHORS.md.tmp AUTHORS.md; then echo 'Updating AUTHORS.md as follows:'; diff AUTHORS.md.tmp AUTHORS.md; mv AUTHORS.md.tmp AUTHORS.md; else echo 'AUTHORS.md was already up to date'; fi; fi"
483483
sh -c "rm -f log.tmp AUTHORS.md.tmp"
484484

485485
.PHONY: clean

0 commit comments

Comments
 (0)