git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Globbing for ignored branches?

From
MTMarkus Trippelsdorf <markus@trippelsdorf.de>
Date
Jan 24, 2014, 20:52 UTC
Message-ID
<20140124205207.GG396@x4>
In-Reply-To
<xmqqmwilqfcl.fsf@gitster.dls.corp.google.com>
On 2014.01.24 at 12:44 -0800, Junio C Hamano wrote:
Show 32 quoted lines
> Markus Trippelsdorf <markus@trippelsdorf.de> writes:
> 
> > On 2014.01.24 at 12:00 -0800, Junio C Hamano wrote:
> >> Jeff King <peff@peff.net> writes:
> >> 
> >> > On Fri, Jan 24, 2014 at 07:32:22PM +0100, Markus Trippelsdorf wrote:
> >> >
> >> >> > However, you do have to specify each branch individually. You probably
> >> >> > want to say "all branches except X", and you cannot currently specify
> >> >> > a negative refspec like that.
> >> >> 
> >> >> Yes, that was the question I wanted to ask (, sorry for not formulating
> >> >> it more clearly). 
> >> >> Is this "negative refspec for branches" a feature that is planned for
> >> >> the future?
> >> >
> >> > It is something that has been talked about before, but I do not think
> >> > anybody is actively working on. It would probably not be too hard a
> >> > feature if you are interested in getting your feet wet in git
> >> > development. :)
> >> 
> >> The end result might be not so hard in the mechanical sense, but
> >> designing the interface would be hard.  I do not offhand think of a
> >> good way to do this.
> >
> > I don't know if the in-tree regex engine supports negative lookaheads.
> > If it does, then something like the following should work (to use my
> > "hjl" example):
> >
> > ^(.(?!hjl))*
> 
> refspec wildcards are *NOT* regular expressions.

Yes, but that's the point. If they were, the "negative refspec" interface issue would be solved.

-- 
Markus
Previous: Junio C HamanoNext: Jeff King
Message 11 of 17 in “Globbing for ignored branches?”
  1. Markus TrippelsdorfJan 24, 2014
  2. Jim GarrisonJan 24, 2014
  3. Markus TrippelsdorfJan 24, 2014
  4. Markus TrippelsdorfJan 24, 2014
  5. Jeff KingJan 24, 2014
  6. Markus TrippelsdorfJan 24, 2014
  7. Jeff KingJan 24, 2014
  8. Junio C HamanoJan 24, 2014
  9. Markus TrippelsdorfJan 24, 2014
  10. Junio C HamanoJan 24, 2014
  11. Markus TrippelsdorfJan 24, 2014
  12. Jeff KingJan 24, 2014
  13. Junio C HamanoJan 24, 2014
  14. Jeff KingJan 25, 2014
  15. Markus TrippelsdorfJan 25, 2014
  16. Markus TrippelsdorfJan 25, 2014
  17. Jeff KingJan 25, 2014

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.