Skip to content

Commit d1517e6

Browse files
committed
ci(update-book): allow for unchanged translations when forcing a rebuild
When forcing a full rebuild, it is possible that some translations do not result in any change. Allow for that _specifically_ when force-rebuilding, but not otherwise (where it would be a bug if there was no change, as at least the head commit will be changed). Signed-off-by: Johannes Schindelin <[email protected]>
1 parent f484ffc commit d1517e6

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

Diff for: .github/workflows/update-book.yml

+7
Original file line numberDiff line numberDiff line change
@@ -87,6 +87,13 @@ jobs:
8787
8888
# commit it all
8989
git add -A external/book &&
90+
if ${{ inputs.force-rebuild == true && 'git diff-index --exit-code HEAD --' || 'false' }}
91+
then
92+
# Force the bundle to be non-empty
93+
git fetch --depth 2 origin ${{ github.ref_name }} &&
94+
git update-ref refs/remotes/origin/${{ github.ref_name }} HEAD^ &&
95+
exit 0
96+
fi &&
9097
git -c user.name=${{ github.actor }} \
9198
-c user.email=${{ github.actor }}@noreply.github.com \
9299
commit -m 'book: update ${{ matrix.language.lang }}' \

0 commit comments

Comments
 (0)