File tree Expand file tree Collapse file tree 1 file changed +5
-6
lines changed
Expand file tree Collapse file tree 1 file changed +5
-6
lines changed Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ name: Dotty the Documenteer
33on :
44 push :
55 branches :
6- - master
6+ - doc
77 paths :
88 - ' doc/**'
99 - ' README.md'
5151 path : site/
5252
5353 deploy :
54- if : github.ref == 'refs/heads/master ' && github.event_name == 'push'
54+ if : github.ref == 'refs/heads/doc ' && github.event_name == 'push'
5555 needs : build
5656 runs-on : ubuntu-latest
5757
@@ -82,19 +82,18 @@ jobs:
8282
8383 - name : Commit and push
8484 run : |
85- cd pages
86-
85+ cd pages/
8786 if [ -z "$(git status --porcelain)" ]; then
8887 exit 0
8988 fi
9089
9190 SRC_REPO="${GITHUB_REPOSITORY}"
92- SRC_REF="$(git -C .. rev-parse --short HEAD) "
91+ SRC_REF="${GITHUB_SHA::7} "
9392 SRC_URL="https://github.com/${SRC_REPO}/commit/${SRC_REF}"
9493
9594 git config user.name "GitHub Actions"
9695 git config user.email "[email protected] " 97- git add .
96+ git add -A
9897 git commit -m "docs: update from ${SRC_REPO}@${SRC_REF}" \
9998 -m "For details, see ${SRC_URL}"
10099 git push
You can’t perform that action at this time.
0 commit comments