push synced/master before synced/git-annex

sync: Partly work around github behavior that first branch to be pushed to
a new repository is assumed to be the head branch, by not pushing
synced/git-annex first.

github expects master (or whatever the name is) to be pushed first, but
git-annex sync can't, because it's got to also support pushes to non-bare
repos where pushing master fails, as explained in the big comment. So
pushing synced/master is not entirely a fix, but at least it makes github
default to a branch with the stuff the user expects in it, not a bunch of
annex log files.

Aside from fixing github to not make this assumption, or improving
the git push protocol to include what the current HEAD is, the only other
approach I can think of is to identify git push's progress messages and
display those when pushing master, while filtering out error messages
about non-fast-forward etc. But git doesn't provide a way to separate out
or identify its progress messages.

Sponsored-by: Luke Shumaker on Patreon
This commit is contained in:
Joey Hess 2021-06-21 12:32:21 -04:00
parent fcd5c6a21c
commit 1cc7b2661e
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
3 changed files with 26 additions and 4 deletions

View file

@ -0,0 +1,7 @@
[[!comment format=mdwn
username="joey"
subject="""comment 11"""
date="2021-06-21T16:25:13Z"
content="""
Changed the sync order as I discussed.
"""]]