Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion .github/workflows/update-autodoc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,8 @@ jobs:
if [[ `git status --porcelain` ]]; then
git add .
git commit -m "docs: update autodoc markdowns"
git push origin update-autodoc
# the branch is recreated from main on every run: overwrite the one left by a previous run, if any
git push --force origin update-autodoc
else
echo "No changes detected. Skipping commit and PR creation."
echo "no_changes=true" >> $GITHUB_ENV
Expand All @@ -41,6 +42,11 @@ jobs:
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
# a PR left open by a previous run already shows the force-pushed branch
if [[ -n "$(gh pr list --head update-autodoc --state open --json number --jq '.[].number')" ]]; then
echo "A pull request for update-autodoc is already open, it has been updated."
exit 0
fi
gh pr create \
--head update-autodoc \
--base main \
Expand Down
Loading