[PATCH 0/5] Some very preliminary remote git access patches

Linus Torvalds torvalds at linux-foundation.org
Mon Feb 9 10:45:09 PST 2015


On Feb 9, 2015 8:16 AM, "Dirk Hohndel" <dirk at hohndel.org> wrote:
>
> > I originally wanted to create a local cache of a remote git repository -
> > multiple branches and all. But the remote tracking branch behavior of
> > libgit2 was too confusing, and I eventually realized that I also want to
> > have a branch actually checked out in that local repository, so I ended
up
> > modifying the "local cache" model so that each *branch* has its own
local
> > cache.
>
> So if someone (like you and I) has multiple branches in one repository,
> they can still make this work by simply having two different base
> directories locally?

No need. There can be multiple git caches, they are all hidden and indexed
by the hash of the remote address.

So it's easy to do

    subsurface file:///home/torvalds/scuba-mirror[linus]

and then do

    subsurface file:///home/torvalds/scuba-mirror[hohndel]

and both of them work - it just crates two separate caches. So there will
be some duplication in this case, and wasted disk space, but it all works,
I've tested this part quite a lot

However, it's all *impractical* right now due to the lack of ssh
authentication and any GUI for progress (so that you could cancel the
update etc with slow networks). And there are a few other missing pieces.
But I think the core design is ok and in principle all the patches are fine
to apply, because it won't hurt any of the existing cases.

]
> > but sadly, I never got around to actually figuring out why libgit2
doesn't
> > use the SSH config file, and how the authentication is supposed to work.
>
> That's kind of a critical piece, though, as my assumption is that people
> will want to have at least somewhat private repos...

Yes. I'm a bit worried about how libgit2 doesn't seem to look up the ssh
config file at all, so even ssh access with just a private jet and no
passphrase doesn't work.

The reason that works me is that implies that libgit2 doesn't do the whole
"run ssh externally" at all. The slow local fetch bug I reported also
seemed to imply that. So I'm worried about how hard it will be to get ssh
access at all with it.

But my core cache reorganization meant that I never really liked at this
part at all. Maybe it will be simple. Maybe it will be fundamentally hard.
Don't know.

> Since they were all signed off I assume you are OK with me putting them
> into master once I've done some testing?

Yes. I don't think there is anything wrong with any of them, just perhaps
missing stuff. ID like some qt person to take a look at my pathname crud,
but I think it works. I may end up getting rid of the "git-caches" part of
the pathname just to avoid problems with windows, but that's in the last
patch, doesn't affect the earlier ones

   Linus
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.subsurface-divelog.org/pipermail/subsurface/attachments/20150209/72fc520c/attachment.html>


More information about the subsurface mailing list