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

Re: Feature request: Add --mtime option to git archive

From
Jeff King <peff@peff.net>
Date
Feb 17, 2023, 20:25 UTC
Message-ID
<Y+/iu7j+NsS/3sAX@coredump.intra.peff.net>
In-Reply-To
<xmqqpma9m4i1.fsf@gitster.g>
On Thu, Feb 16, 2023 at 06:04:38PM -0800, Junio C Hamano wrote:
Show 6 quoted lines
> > I do wonder if people would complain (both with the patch above and with
> > brian's proposal) that the resulting tarballs extract everything with a
> > date in 1970. That's not functionally a problem, but it looks kind of
> > weird in "ls -l".
> 
> And owned by root:root ;-)

Yeah, though I think it's pretty standard these days to use --no-same-owner or equivalent (and it's the default for non-root users). And ditto for modes. I wondered if there was an equivalent for timestamps. It looks like "-m" works (it just sets everything to the current timestamp at time of extraction), but I don't know how portable that is (and POSIX is no help with tar, as usual).

-Peff
Previous: René ScharfeNext: demerphq
Message 8 of 16 in “Feature request: Add --mtime option to git archive”
  1. Raul E RangelFeb 16, 2023
  2. Jeff KingFeb 16, 2023
  3. Junio C HamanoFeb 16, 2023
  4. Jeff KingFeb 17, 2023
  5. Junio C HamanoFeb 17, 2023
  6. Raul RangelFeb 17, 2023
  7. René ScharfeFeb 17, 2023
  8. Jeff KingFeb 17, 2023
  9. demerphqFeb 18, 2023
  10. brian m. carlsonFeb 18, 2023
  11. archive: add --mtimeRené Scharfe, Feb 18, 2023
  12. Junio C HamanoFeb 18, 2023
  13. René ScharfeFeb 19, 2023
  14. Junio C HamanoFeb 21, 2023
  15. Jeff KingFeb 22, 2023
  16. Junio C HamanoFeb 22, 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.