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

git-archive loses path info when opened with Winzip?

From
RDRogan Dawes <lists@dawes.za.net>
Date
Mar 31, 2008, 11:59 UTC
Message-ID
<47F0D215.1060700@dawes.za.net>
Hi folks,

I have noticed something strange with "git-archive"-created tarballs. It seems that Winzip has trouble parsing the paths for certain files correctly.

The symptom is that Winzip shows some files as having been created at the "top level" of the zip, without any path at all, while the rest of the files are within their correct directory structure.

I have attached a screenshot of a gitweb-created snapshot opened in Winzip 9.0 SR1 (build 6224), but it apparently happens in other (more recent) versions of Winzip as well.

The tarball in question is at:
<http://dawes.za.net/gitweb.cgi?p=rogan/webscarab/webscarab.git;a=snapshot;h=7ee920dad6b41987f692017dbd9b85259e7a8fe5>

(It's a 2.7MB file). And yes, it happens when git-archive is called directly, not just via gitweb.cgi.

Regular GNU tar (cygwin) shows the correct path info: (for example)

0 $ tar -tvzf /tmp/webscarab.tar.gz | grep AbstractTreeTableModel -rw-rw-r-- root/root 2311 2008-03-08 22:35 rogan/webscarab/webscarab.git/src/org/owasp/webscarab/util/swing/treetable/AbstractTreeTableModel.java 0 $

The version of git on the server is:
 > [rdawes@lucas rdawes]$ which git
 > /home/rdawes/bin/git
 > [rdawes@lucas rdawes]$ git --version
 > git version 1.5.5.rc1.6.g5cc8f

Any ideas what may be going wrong here? Note that it doesn't seem to happen when generating a ZIP using git-archive, but only when generating tarballs.

Regards,
Rogan
Next: René Scharfe
Message 1 of 3 in “git-archive loses path info when opened with Winzip?”
  1. Rogan DawesMar 31, 2008
  2. René ScharfeMar 31, 2008
  3. Rogan DawesMar 31, 2008

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.