Is there any way to push an empty commit to a (remote) git repository without cloning the git repository first?
I.e., can I achieve the effect of
git clone https://github.com/example-org/example-repo.git
cd example-repo
git commit -m "empty commit" --allow-empty
git push
without first cloning the repository in the first line?
Ideally, I'd like to do this with "pure" git, but using the github API would be fine as well if there no easy way for pure git.
Background: I need the empty commit as part of the automatic deploy mechanism in Heroku which automatically deploys on github commits.
gitworks only on a local repository. Using Github API — possible, see stackoverflow.com/a/52941620/7976758 and stackoverflow.com/search?q=%5Bgithub-api%5D+create+commit--single-branch) suffices since you don't need the commits before the commit you're duplicating.