Skip to content

Commit 95eddcd

Browse files
committed
Made order of names in AUTHORS.md reliable
Details: * The sort order of the 'sort' command depends on the LC_COLLATE env var (which can be overridden by the LC_ALL env var). The AUTHORS.md file is generated on every build (because its dependencies are the complete set of commits in the repo), and uses the 'sort' command when creating it. When the sort order is not reliable, the AUTHORS.md file changes, and this causes the publish workflow to have a dirty git status due to the change AUTHORS.md file, and thus the upload to Pypi fails. This change sets LC_ALL=C.UTF-8 in order to produce a reliable order in the UATHORS.md file, independent of the LC_* env vars the environment may or may not have set. Signed-off-by: Andreas Maier <[email protected]>
1 parent 8903f38 commit 95eddcd

File tree

3 files changed

+3
-1
lines changed

3 files changed

+3
-1
lines changed

AUTHORS.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,4 +21,5 @@ Simon Spinner <[email protected]>
2121
Sreeram Venkateswaran <[email protected]>
2222
Viktor Mihajlovski <[email protected]>
2323
dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
24+
renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2425
```

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -699,7 +699,7 @@ AUTHORS.md: _always
699699
echo "" >>AUTHORS.md.tmp
700700
echo "Sorted list of authors derived from git commit history:" >>AUTHORS.md.tmp
701701
echo '```' >>AUTHORS.md.tmp
702-
sh -c "git shortlog --summary --email HEAD | cut -f 2 | sort >>AUTHORS.md.tmp"
702+
sh -c "git shortlog --summary --email HEAD | cut -f 2 | LC_ALL=C.UTF-8 sort >>AUTHORS.md.tmp"
703703
echo '```' >>AUTHORS.md.tmp
704704
sh -c "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'; rm AUTHORS.md.tmp; fi"
705705

changes/1897.fix.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Dev: Made order of names in AUTHORS.md reliable.

0 commit comments

Comments
 (0)