I haven’t found anything on this yet. The only way I know this is possible is by setting up a net drive (e.g. netdrive.net or something similar) with a repo on it that we can tell our local bare repo to use as a working tree. It won’t have any idea the content is actually going to some place across the net.
Is there any other way to do it?
Short version: no. Reason: git needs easy access to
.git/indexandlstat()system calls. You probably don’t want the index on the remote location either, so why not just have your post-receive hook (in your--barerepo where you put “final deploy” versions) update a non-bare repo somewhere, then ftp over the changed files? (You can get a list of “just the added / changed / removed files” withgit diff-tree -ras long as you know which version is currently live on the remote web server.)