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

Re: [PATCH] git-archive: accept --owner and --group like GNU tar

From
René Scharfe <l.s.r@web.de>
Date
Jan 5, 2018, 13:54 UTC
Message-ID
<ee76246b-579c-fe01-eb9c-d400061b47b6@web.de>
In-Reply-To
<xmqqmv1tfpqh.fsf@gitster.mtv.corp.google.com>
Am 04.01.2018 um 19:22 schrieb Junio C Hamano:
Show 15 quoted lines
> René Scharfe <l.s.r@web.de> writes:
> 
>> I don't know if it's a good idea, but perhaps we don't even need a new
>> option.  We could change how pathspecs of untracked files are handled:
>> Instead of aborting we could include them in the archive.  (Sounds like
>> the simplest possible interface, but may have practical problems.)
> 
> One practical problem is that users who do this
> 
>      $ git archive HEAD Documentation/ | tar tf -
> 
> would be expecting (at least) two different things, depending on the
> situation they are in.
> 
> So at least you'd need an "--include-untracked" option, I guess.

Right, this breaks down with directories -- most build artifacts (e.g. .o files) are probably not meant to end up in archives. We could still do it for regular files and symlinks. Perhaps that's too confusing, though, and an --add-untracked-file parameter (or whatever we want to call it) is the way to go.

René
Previous: Junio C HamanoNext: Junio C Hamano
Message 11 of 13 in “git-archive: accept --owner and --group like GNU tar”
  1. git-archive: accept --owner and --group like GNU tarsuzuki toshiya, Dec 29, 2017
  2. René ScharfeJan 1, 2018
  3. Perry HutchisonJan 2, 2018
  4. René ScharfeJan 4, 2018
  5. suzuki toshiyaJan 2, 2018
  6. René ScharfeJan 2, 2018
  7. suzuki toshiyaJan 4, 2018
  8. suzuki toshiyaJan 4, 2018
  9. René ScharfeJan 4, 2018
  10. Junio C HamanoJan 4, 2018
  11. René ScharfeJan 5, 2018
  12. Junio C HamanoJan 5, 2018
  13. suzuki toshiyaJan 5, 2018

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.