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

[PATCH v2 0/5] Support matching "**" in .gitattributes and .gitignore

From
Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
Date
Sep 16, 2012, 15:27 UTC
Message-ID
<1347809265-2457-1-git-send-email-pclouds@gmail.com>
In-Reply-To
<1347710524-15404-1-git-send-email-pclouds@gmail.com>
Changes in v2:
 - Correct commit sha-1 in the 1/5 to the last GPL-2 rsync commit.
   State it is pristine import. Move wildmatch.[ch] to top dir.
 - Add tests to 5/5 (I forgot to test that the integration should run
   well, in addition to wildmatch() working in general)

Note that there might be a regression because wildmatch() does not care about LC_CTYPE when dealing with character classes, while libc's fnmatch might. But it's probably not worth bothering about because we match against path names, which do not necessarily follow LC_TYPE but the file system's encoding.

Nguyễn Thái Ngọc Duy (5):
  Import wildmatch from rsync
  compat/wildmatch: remove static variable force_lower_case
  compat/wildmatch: fix case-insensitive matching
  Integrate wildmatch to git
  Support "**" in .gitignore and .gitattributes patterns using
    wildmatch()
 .gitignore                         |   1 +
 Documentation/gitignore.txt        |   3 +
 Makefile                           |   6 +
 attr.c                             |   4 +-
 dir.c                              |   5 +-
 t/t0003-attributes.sh              |  17 ++
 t/t3001-ls-files-others-exclude.sh |  11 ++
 t/t3070-wildmatch.sh               |  27 +++
 t/t3070-wildmatch/wildtest.txt     | 165 ++++++++++++++++
 test-wildmatch.c                   | 228 +++++++++++++++++++++++
 wildmatch.c                        | 373 +++++++++++++++++++++++++++++++++++++
 wildmatch.h                        |   6 +
 12 files changed, 844 insertions(+), 2 deletions(-)
 create mode 100755 t/t3070-wildmatch.sh
 create mode 100644 t/t3070-wildmatch/wildtest.txt
 create mode 100644 test-wildmatch.c
 create mode 100644 wildmatch.c
 create mode 100644 wildmatch.h
-- 
1.7.12.403.gce5cf6f.dirty
Previous: Jan EngelhardtNext: Nguyễn Thái Ngọc Duy
Message 23 of 34 in “Support matching "**" in .gitattributes and .gitignore”
  1. 0/5 Support matching "**" in .gitattributes and .gitignoreNguyễn Thái Ngọc Duy, Sep 15, 2012
  2. 1/5 Import wildmatch from rsyncNguyễn Thái Ngọc Duy, Sep 15, 2012
  3. Junio C HamanoSep 16, 2012
  4. 2/5 compat/wildmatch: remove static variable force_lower_caseNguyễn Thái Ngọc Duy, Sep 15, 2012
  5. 3/5 compat/wildmatch: fix case-insensitive matchingNguyễn Thái Ngọc Duy, Sep 15, 2012
  6. 4/5 Integrate wildmatch to gitNguyễn Thái Ngọc Duy, Sep 15, 2012
  7. 5/5 Support "**" in .gitignore and .gitattributes patterns using wildmatch()Nguyễn Thái Ngọc Duy, Sep 15, 2012
  8. How to create the " [PATCH 0/5]" first email?Philip Oakley, Sep 15, 2012
  9. Junio C HamanoSep 15, 2012
  10. Philip OakleySep 17, 2012
  11. Junio C HamanoSep 17, 2012
  12. Jeff KingSep 18, 2012
  13. Junio C HamanoSep 18, 2012
  14. Jeff KingSep 18, 2012
  15. Junio C HamanoSep 18, 2012
  16. Jeff KingSep 18, 2012
  17. Junio C HamanoSep 18, 2012
  18. Philip OakleySep 18, 2012
  19. Jeff KingSep 18, 2012
  20. Jeff KingSep 18, 2012
  21. Wesley J. LandakerSep 18, 2012
  22. Jan EngelhardtSep 23, 2012
  23. 0/5 Support matching "**" in .gitattributes and .gitignoreNguyễn Thái Ngọc Duy, Sep 16, 2012
  24. 1/5 Import wildmatch from rsyncNguyễn Thái Ngọc Duy, Sep 16, 2012
  25. 2/5 compat/wildmatch: remove static variable force_lower_caseNguyễn Thái Ngọc Duy, Sep 16, 2012
  26. 3/5 compat/wildmatch: fix case-insensitive matchingNguyễn Thái Ngọc Duy, Sep 16, 2012
  27. 4/5 Integrate wildmatch to gitNguyễn Thái Ngọc Duy, Sep 16, 2012
  28. Junio C HamanoSep 17, 2012
  29. Junio C HamanoSep 17, 2012
  30. Nguyen Thai Ngoc DuySep 17, 2012
  31. Nguyen Thai Ngoc DuySep 17, 2012
  32. Junio C HamanoSep 17, 2012
  33. 5/5 Support "**" in .gitignore and .gitattributes patterns using wildmatch()Nguyễn Thái Ngọc Duy, Sep 16, 2012
  34. 6/5 side-step a make rule that builds t3070-wildmatchJohannes Sixt, Sep 25, 2012

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.