Skip to content

Commit 8d08021

Browse files
authored
Just apply docs/ changes from that single commit - refs #1
1 parent 5692dd6 commit 8d08021

File tree

1 file changed

+7
-6
lines changed

1 file changed

+7
-6
lines changed

.github/workflows/stable-docs.yml

+7-6
Original file line numberDiff line numberDiff line change
@@ -41,9 +41,10 @@ jobs:
4141
- name: Handle Commit to Main
4242
if: contains(github.event.head_commit.message, '!stable-docs')
4343
run: |
44-
# Apply all changes that affect docs/ directory
45-
for commit in $(git log --format="%H" origin/main ^origin/stable-docs); do
46-
git show $commit -- docs/ | git apply -
47-
git add docs/
48-
git commit -m "Cherry-picked docs changes from $commit" || true
49-
done
44+
git fetch origin stable-docs:stable-docs
45+
git checkout stable-docs
46+
# !stable-docs should only be in the one commit, so apply changes from that commit
47+
git show ${{ github.sha }} -- docs/ | git apply -
48+
git add docs/
49+
git commit -m "Cherry-picked docs changes from ${{ github.sha }}" || true
50+
git push origin stable-docs

0 commit comments

Comments
 (0)