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

Re: [PATCH 1/3] Add support for new %w wildcard in checkout filter

From
Junio C Hamano <gitster@pobox.com>
Date
Sep 7, 2021, 20:28 UTC
Message-ID
<xmqqilzc9lm6.fsf@gitster.g>
In-Reply-To
<20210906181002.625647-1-calumlikesapplepie@gmail.com>
> Subject: [PATCH 1/3] Add support for new %w wildcard in checkout filter

Please write your title to help readers of "git shortlog --no-merges". With the above, readers would not know where the %w would newly be allowed to appear, what it does, and how it helps what use case.

Show 6 quoted lines
> When building content filters with gitattributes, for instance to ensure
> git stores the plain-text rather than the binary form of data for certain
> formats, it is often advantageous to separate the filters into separate,
> potentially complex scripts.  However, as the $PWD where content filters
> are executed is unspecified the path to scripts needs to be specified as
> an absolute path.

Isn't $PWD at least stable in a repository, relative to the top of worktree or something? IOW, isn't the above raise a separate documentation issue that is better solved without any new code?

Show 5 quoted lines
> That means that the guide for setting up a repository
> which uses scripts to filter content cannot simply consist of "include
> the following lines in your .git/config file", and it means that the
> otherwise safe operation of moving a git repository from one folder to
> another is decidedly unsafe.

If these paths are given as absolute paths (e.g. ~/filter-scripts/), the repositories that refer to these can be moved freely, as long as the location of the the directory that holds these auxiliary scripts is kept stable, no?

Previous: Jeff King
Message 8 of 8 in “Add support for new %w wildcard in checkout filter”
  1. 1/3 Add support for new %w wildcard in checkout filterCalum McConnell, Sep 6, 2021
  2. 2/3 Die if filter is attempted without a worktreeCalum McConnell, Sep 6, 2021
  3. Ævar Arnfjörð BjarmasonSep 6, 2021
  4. Calum McConnellSep 7, 2021
  5. Bagas SanjayaSep 7, 2021
  6. 3/3 Document the new gitattributes changeCalum McConnell, Sep 6, 2021
  7. Jeff KingSep 7, 2021
  8. Junio C HamanoSep 7, 2021

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.