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

Re: Is there a way to get the "format-patch" formatted file name?

From
Oswald Buddenhagen <oswald.buddenhagen@gmx.de>
Date
Aug 31, 2023, 12:46 UTC
Message-ID
<ZPCLi5iiYsf6XQc6@ugly>
In-Reply-To
<3a7837fa-d7fb-1a85-dc67-94e94f4058c6@redhat.com>
On Thu, Aug 31, 2023 at 02:13:30PM +0200, Vít Ondruch wrote:
Show 15 quoted lines
>Dne 31. 08. 23 v 13:04 Oswald Buddenhagen napsal(a):
>> On Thu, Aug 31, 2023 at 11:49:10AM +0200, Vít Ondruch wrote:
>>> $ git extract-filenames-from-patch 791.patch
>>>
>>> 0001-Fix-Minitest-constant-name-in-tests.patch
>>>
>> `git log --pretty=format:%f` does that.
>> of course you need to apply the patch first for that to work
>
>
>That (applying the patch) is the problem actually. I am looking for 
>functionality like this in the context of  Fedora packaging, where we 
>work with source tarballs. Therefore I don't typically have an 
>repository around.
>

well, you can just `git init` and add and commit the entire tree. less inefficient would be creating a dummy repo, and cutting down the patch to be empty before applying it.

of course these are ludicrous suggestions in practice, and just replicating the cleanup function with a few regexes in a perl one-liner should do.

regards
Previous: Vít OndruchNext: Junio C Hamano
Message 4 of 10 in “Is there a way to get the "format-patch" formatted file name?”
  1. Vít OndruchAug 31, 2023
  2. Oswald BuddenhagenAug 31, 2023
  3. Vít OndruchAug 31, 2023
  4. Oswald BuddenhagenAug 31, 2023
  5. Junio C HamanoAug 31, 2023
  6. Vít OndruchSep 1, 2023
  7. Oswald BuddenhagenSep 1, 2023
  8. Junio C HamanoSep 1, 2023
  9. Junio C HamanoSep 1, 2023
  10. Vít OndruchSep 1, 2023

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.