GitHub Action
Git commit, pull & push action
v1.2.5
Latest version
Runs git add, git commit, git pull and git push.
The action flow:
git add
(withadd_args
, defaults to.
)- check if there are any changed files
git fetch
git checkout branch
(to allow push in PRs)git commit
git pull
(withpull_args
, defaults to--rebase
)git push
Originally designed to run git pull --rebase -X ours
or git pull --rebase -X theirs
after commit to help pushing changes to gh-pages
.
- name: Git Commit and Push Action
uses: mgrybyk-org/git-commit-pull-push-action@v1
with:
repository: gh-pages
branch: gh-pages # ${{ github.head_ref }}
commit_message: Apply automatic changes
pull_args: --rebase -X ours
-X
(same as --strategy-option
).
ours
: option forces conflicting chunks to be auto-resolved cleanly by favoring our (current) version (instead of incoming).theirs
: is the opposite of ours.
Please see action.yml