git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Bug: git-archive: --add-virtual-file doesn't seem to respect --prefix
@ 2024-02-15  6:07 Ron Yorston
  2024-02-15 11:48 ` AW: " stefan.naewe
  0 siblings, 1 reply; 2+ messages in thread
From: Ron Yorston @ 2024-02-15  6:07 UTC (permalink / raw)
  To: git

The man page for git-archive has similar language regarding the
--add-file and --add-virtual-file options:

   The path of the file in the archive is built by concatenating the
   value of the last --prefix option (if any) before...

However this doesn't seem to be true for --add-virtual-file.  In any
git repository:

   $ touch real_added_file
   $ git archive --format=tar --prefix=prefix/ --add-file=real_added_file \
      --add-virtual-file=virtual_added_file: HEAD | \
      tar tvf - | grep added_file
   -rw-rw-r-- root/root         0 2017-02-22 17:18 prefix/real_added_file
   -rw-rw-r-- root/root         0 2017-02-22 17:18 virtual_added_file

I expected to see 'prefix/virtual_added_file'.

Ron

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

end of thread, other threads:[~2024-02-15 11:49 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-15  6:07 Bug: git-archive: --add-virtual-file doesn't seem to respect --prefix Ron Yorston
2024-02-15 11:48 ` AW: " stefan.naewe

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).