We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 25a7c64 commit 73d6789Copy full SHA for 73d6789
.github/workflows/wiki.yml
@@ -58,6 +58,12 @@ jobs:
58
echo "wiki_changed=$changed" >> "$GITHUB_OUTPUT"
59
exit 0
60
fi
61
+
62
+ default_branch="$(git remote show origin | sed -n '/HEAD branch/s/.*: //p')"
63
64
+ if [ -z "$default_branch" ]; then
65
+ default_branch="main"
66
+ fi
67
68
git config user.email "github-actions[bot]@users.noreply.github.com"
69
git config user.name "github-actions[bot]"
@@ -70,7 +76,7 @@ jobs:
70
76
71
77
72
78
git commit -m "Update wiki docs at $(date "+%Y-%m-%d %H:%M:%S")"
73
- git push origin HEAD
79
+ git push origin "$default_branch"
74
80
75
81
changed="true"
82
0 commit comments