Re: [RFC/PATCH] git-remote-mediawiki: reset private ref after non-dumb push

2013-08-27 Thread Matthieu Moy
Junio C Hamano writes: > Matthieu Moy writes: > >> git-remote-mediawiki is kind of a special case, as the remote side uses >> a very different data model, hence it can make sense to export+reimport >> to get locally what the remote side received. > > Hmm, I am not sure how export+reimport would

Re: [RFC/PATCH] git-remote-mediawiki: reset private ref after non-dumb push

2013-08-27 Thread Matthieu Moy
Felipe Contreras writes: > On Mon, Aug 26, 2013 at 4:16 AM, Matthieu Moy > wrote: >> Matthieu Moy writes: >> >>> Junio C Hamano writes: >>> Matthieu Moy writes: >>> >>> Ideally, it would be possible to ask for a non-update without a fatal >>> error on old Git versions, but this is not po

Re: [RFC/PATCH] git-remote-mediawiki: reset private ref after non-dumb push

2013-08-26 Thread Felipe Contreras
On Mon, Aug 26, 2013 at 4:16 AM, Matthieu Moy wrote: > Matthieu Moy writes: > >> Junio C Hamano writes: >> >>> Matthieu Moy writes: >>> How would I do that? The update to the remote namespace is done by Git, not by the remote-helper. OK, I'm now convinced that my solution is

Re: [RFC/PATCH] git-remote-mediawiki: reset private ref after non-dumb push

2013-08-26 Thread Junio C Hamano
Matthieu Moy writes: > Not updating was the default until 664059fb62 (i.e. until 1.8.4), so the > default already changed once. I tend to agree with Felipe that doing the > update by default makes sense. OK. Thanks. > git-remote-mediawiki is kind of a special case, as the remote side uses > a

Re: [RFC/PATCH] git-remote-mediawiki: reset private ref after non-dumb push

2013-08-26 Thread Matthieu Moy
Matthieu Moy writes: > Junio C Hamano writes: > >> Matthieu Moy writes: >> >>> How would I do that? The update to the remote namespace is done by Git, >>> not by the remote-helper. >>> >>> OK, I'm now convinced that my solution is the right one. The >>> alternatives are far more complex and I s

Re: [RFC/PATCH] git-remote-mediawiki: reset private ref after non-dumb push

2013-08-26 Thread Matthieu Moy
Junio C Hamano writes: > Matthieu Moy writes: > >> How would I do that? The update to the remote namespace is done by Git, >> not by the remote-helper. >> >> OK, I'm now convinced that my solution is the right one. The >> alternatives are far more complex and I still fail to see the benefits. >

Re: [RFC/PATCH] git-remote-mediawiki: reset private ref after non-dumb push

2013-08-24 Thread Junio C Hamano
Matthieu Moy writes: > How would I do that? The update to the remote namespace is done by Git, > not by the remote-helper. > > OK, I'm now convinced that my solution is the right one. The > alternatives are far more complex and I still fail to see the benefits. Sounds like a plan, even though it

Re: [RFC/PATCH] git-remote-mediawiki: reset private ref after non-dumb push

2013-08-24 Thread Matthieu Moy
Felipe Contreras writes: > On Fri, Aug 23, 2013 at 3:25 AM, Matthieu Moy > wrote: > >> This is assuming you follow the scheme >> >> git -> local repo for other vcs -> remote repo for other vcs >> >> which itself more or less assumes that the other VCS is a decentralized >> VCS. I understand th

Re: [RFC/PATCH] git-remote-mediawiki: reset private ref after non-dumb push

2013-08-23 Thread Felipe Contreras
On Fri, Aug 23, 2013 at 3:25 AM, Matthieu Moy wrote: > This is assuming you follow the scheme > > git -> local repo for other vcs -> remote repo for other vcs > > which itself more or less assumes that the other VCS is a decentralized > VCS. I understand this is a good idea for hg or bzr remote

Re: [RFC/PATCH] git-remote-mediawiki: reset private ref after non-dumb push

2013-08-23 Thread Matthieu Moy
Felipe Contreras writes: > On Wed, Aug 21, 2013 at 4:36 PM, Matthieu Moy > wrote: >> Felipe Contreras writes: >> >>> On Tue, Aug 13, 2013 at 8:31 AM, Matthieu Moy wrote: >>> Felipe: Is this the right fix for git-remote-mediawiki? Any better idea? >>> >>> Why not keep track of the revision

Re: [RFC/PATCH] git-remote-mediawiki: reset private ref after non-dumb push

2013-08-22 Thread Felipe Contreras
On Wed, Aug 21, 2013 at 4:36 PM, Matthieu Moy wrote: > Felipe Contreras writes: > >> On Tue, Aug 13, 2013 at 8:31 AM, Matthieu Moy wrote: >> >>> Felipe: Is this the right fix for git-remote-mediawiki? Any better idea? >> >> Why not keep track of the revisions yourself? You can have file where >>

Re: [RFC/PATCH] git-remote-mediawiki: reset private ref after non-dumb push

2013-08-21 Thread Matthieu Moy
Felipe Contreras writes: > On Tue, Aug 13, 2013 at 8:31 AM, Matthieu Moy wrote: > >> Felipe: Is this the right fix for git-remote-mediawiki? Any better idea? > > Why not keep track of the revisions yourself? You can have file where > you store which was the last revision that was fetched. I don

Re: [RFC/PATCH] git-remote-mediawiki: reset private ref after non-dumb push

2013-08-21 Thread Felipe Contreras
On Tue, Aug 13, 2013 at 8:31 AM, Matthieu Moy wrote: > > Git-mediawiki's "dumb push" sends the local revisions to the remote wiki, > but does not update the local metadata to reflect the push (hence, the > next pull will have to re-import the exported revisions). > > The previous implementation wa

[RFC/PATCH] git-remote-mediawiki: reset private ref after non-dumb push

2013-08-13 Thread Matthieu Moy
Git-mediawiki's "dumb push" sends the local revisions to the remote wiki, but does not update the local metadata to reflect the push (hence, the next pull will have to re-import the exported revisions). The previous implementation was simply omitting the update to the private ref after a dumb push