public inbox for git@vger.kernel.org
 help / color / mirror / Atom feed
* `cat-file --filter` is broken in 2.50?
@ 2025-06-30 16:07 Dan Pristupov
  2025-06-30 17:06 ` Phillip Wood
  0 siblings, 1 reply; 2+ messages in thread
From: Dan Pristupov @ 2025-06-30 16:07 UTC (permalink / raw)
  To: git

Hi,

`cat-file --filter` stopped working in git 2.50.

```
$ git version
git version 2.47.1.windows.2

$ git cat-file --filter "HEAD:changelog.md"
<content>
```

```
$ git version
git version 2.50.0.windows.1

$ git cat-file --filter "HEAD:changelog.md"
fatal: invalid filter-spec 'HEAD:changelog.md'
```

The problem was introduced at eb83e4c64b5a3458569593c2ab0c29365f10a82f.

Then it was merged into the main branch by 
a271b05066a1fd2c3a62508d9908d6c5df14a1cb.

This seems like a bug.


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

* Re: `cat-file --filter` is broken in 2.50?
  2025-06-30 16:07 `cat-file --filter` is broken in 2.50? Dan Pristupov
@ 2025-06-30 17:06 ` Phillip Wood
  0 siblings, 0 replies; 2+ messages in thread
From: Phillip Wood @ 2025-06-30 17:06 UTC (permalink / raw)
  To: Dan Pristupov, git

Hi Dan

On 30/06/2025 17:07, Dan Pristupov wrote:
> Hi,
> 
> `cat-file --filter` stopped working in git 2.50.

cat-file did not have a "--filter" option before 2.50. The option you 
are looking for is "--filters". As git accepts unambiguous abbreviations 
for long options "--filter" used to match "--filters" but now it is a 
separate option. Being able to use abbreviated option names is useful at 
the command line but they are best avoided in scripts.

Best Wishes

Phillip

> 
> ```
> $ git version
> git version 2.47.1.windows.2
> 
> $ git cat-file --filter "HEAD:changelog.md"
> <content>
> ```
> 
> ```
> $ git version
> git version 2.50.0.windows.1
> 
> $ git cat-file --filter "HEAD:changelog.md"
> fatal: invalid filter-spec 'HEAD:changelog.md'
> ```
> 
> The problem was introduced at eb83e4c64b5a3458569593c2ab0c29365f10a82f.
> 
> Then it was merged into the main branch by 
> a271b05066a1fd2c3a62508d9908d6c5df14a1cb.
> 
> This seems like a bug.
> 
> 


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

end of thread, other threads:[~2025-06-30 17:06 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-06-30 16:07 `cat-file --filter` is broken in 2.50? Dan Pristupov
2025-06-30 17:06 ` Phillip Wood

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox