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

[PATCH 0/5] Extend pattern refspecs

From
Daniel Barkalow <barkalow@iabervon.org>
Date
Mar 6, 2009, 04:56 UTC
Message-ID
<alpine.LNX.1.00.0903052346270.19665@iabervon.org>

This series only supports the narrowest case of having the * in the middle of a side of a refspec: having it as a full path component on each side.

Patches 1-3 centralize all of the parsing and matching rules to a pair of functions; patch 4 makes the stored representation more convenient (and serves as a distinguished bisection outcome for anything I missed that was relying on the contents of struct refspec for patterns); and patch 5 extends the matching implementation and loosens the ref format requirements to allow the * to be in the middle.

An easy followup would relax the restrictions further without requiring any particularly tricky further changes.

Daniel Barkalow (5):
  Make clone parse the default fetch refspec with the regular code
  Use a single function to match names against patterns
  Use the matching function to generate the match results
  Keep '*' in pattern refspecs
  Support '*' in the middle of a refspec
 builtin-clone.c    |   25 ++++++++--------
 refs.c             |   15 +++++----
 remote.c           |   78 +++++++++++++++++++++++++++++----------------------
 t/t5511-refspec.sh |   12 ++++++++
 4 files changed, 77 insertions(+), 53 deletions(-)
Next: Jay Soffian
Message 1 of 9 in “Extend pattern refspecs”
  1. 0/5 Extend pattern refspecsDaniel Barkalow, Mar 6, 2009
  2. Jay SoffianMar 6, 2009
  3. Daniel BarkalowMar 6, 2009
  4. Jay SoffianMar 6, 2009
  5. Daniel BarkalowMar 6, 2009
  6. Jay SoffianMar 6, 2009
  7. Junio C HamanoMar 8, 2009
  8. Daniel BarkalowMar 8, 2009
  9. Jay SoffianMar 9, 2009

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.