On Tue, 19 Feb 2008, Johannes Schindelin wrote: > Hi, > > On Tue, 19 Feb 2008, Jon Loeliger wrote: > > > Daniel Barkalow wrote: > > > > > For example, if you don't have a kernel.org account, you might want > > > settings like: > > > > > > [host "kernel.org"] > > > base = git://git.kernel.org/pub/ > > > rewritebase = master.kernel.org:/pub > > > > > > Then, if you give git a URL like: > > > > > > master.kernel.org:/pub/scm/linux/kernel/git/linville/wireless-2.6.git > > > > > > it will act like you gave it: > > > > > > git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-2.6.git > > > > > > and you can cut-and-paste pull requests in email without fixing them > > > by hand, for example. > > > > > > Signed-off-by: Daniel Barkalow <barkalow@xxxxxxxxxxxx> > > > --- > > > > So, I may be dense, but I'm having a hard time distinguishing the names > > "base" and "rewritebase" just from a User Interface perspective. It's > > not clear to me which of those is the A and which is the B part in > > s/A/B/. "Rewritebase" might be the "from" basis, or it might be the > > "to" basis. Can we come up with more descriptive property names here? > > > > Is the rewrite always just prefix substitution/replacement? > > What if there was some generic path rewrite needed? (KISS? :-)) > > I just tried this: > > $ git config rewrite."master.kernel.org:/pub".url \ > git://git.kernel.org/pub/ > > and it worked. IOW, the config will look like this: > > [rewrite "master.kernel.org:/pub"] > url = git://git.kernel.org/pub/ > > So maybe this is easier to grasp? If you've also got people using http:// URLs, this would require giving the preferred URL twice. And it doesn't help with possible future host-based configuration, or a non-prefix pattern, if that came up some day. I suppose perhaps: [host "git://git.kernel.org/pub/"] aka = "master.kernel.org:/pub/" aka = "http://www.kernel.org/pub/" I'm a little worried about putting URLs in keys, but I don't know if that's a reasonable worry. -Daniel *This .sig left intentionally blank* - To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html