I would like to know how to use a pair of fifos as a means for exchanging commits between Git repository clones.
git-remote-fd documents how to use this from a client's perspective, but does not give any example how to set up the associated server part.
So far, I have tried the following:
# Prepare repos.
git init a
(cd a && echo one > file1 && git add file1 && git commit -m first)
git clone a b
(cd a && echo two > file2 && git add file2 && git commit -m second)
mkfifo ab && mkfifo ba
# Now I want to push from a to b via the fifos
(cd a && git push fd::8,9 master) 8< ba 9> ab &
(cd b && git pull fd::9,8 master) 8> ba 9< ab
No luck, though. The fifos obviously block. The commands hang and never complete.
I guess "git push" is not the right command for the server part, and "git send-pack" or "git upload-pack" would be more appropriate. But I have a hard time understanding how to actually use both commands.
Any ideas?