git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Adding glob support to remotes
@ 2006-11-22  9:04 Andy Parkins
  2006-11-22 12:56 ` Junio C Hamano
  0 siblings, 1 reply; 5+ messages in thread
From: Andy Parkins @ 2006-11-22  9:04 UTC (permalink / raw)
  To: git

Hello,

I'm working on adding (basic) glob support to remote fetch definitions.  This 
is to allow you to write things like

[remote "origin"]
  fetch = refs/heads/*:refs/remotes/upstream/*

I started to add code to git-parse-remote.sh:canon_refs_list_for_fetch() to 
preprocess the reflist to catch lines with a "*" in them then use the remote 
pattern to filter the output of from "git-ls-remote -h", blah, blah, you get 
the idea...

However, git-ls-remote needs the name of the remote repository (of course), 
but that isn't directly available in git-parse-remote.sh.  Should I
 a) pass it as a parameter from git-fetch.sh right through each intermediate 
function
 b) create a global?
 c) change git-check-ref-format to allow "*" in the name, then put the 
git-ls-remote call in git-fetch instead.

I don't like to do (b) as it's nasty programming behaviour; however passing a 
parameter is fairly intrusive to the existing code.  Similarly (c) means I'm 
messing in places I suspect I shouldn't be (git-check-ref-format).

git-gods - what do I do?



Andy
-- 
Dr Andy Parkins, M Eng (hons), MIEE

^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2006-11-23  8:44 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-11-22  9:04 Adding glob support to remotes Andy Parkins
2006-11-22 12:56 ` Junio C Hamano
2006-11-22 14:41   ` Andy Parkins
2006-11-22 20:50     ` Junio C Hamano
2006-11-23  8:44       ` Andy Parkins

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).