]> source.dussan.org Git - jgit.git/commit
ArchiveCommand: Create prefix entry with commit time 78/98478/3
authorYasuhiro Takagi <ytakagi@bea.hi-ho.ne.jp>
Sat, 29 Apr 2017 11:35:10 +0000 (20:35 +0900)
committerDavid Pursehouse <david.pursehouse@gmail.com>
Mon, 5 Jun 2017 23:35:46 +0000 (19:35 -0400)
commita66e60a98620c5ba9cd3d9fc8f97f268229589e6
tree6ebd94aef1c6c634ad14a9bde84a20168c24a3c1
parent6b1e3c58b16651dc72ec79a614d507e014d18393
ArchiveCommand: Create prefix entry with commit time

The cgit archive command creates a prefix (root) directory entry
in the archive file. That entry's time is set to the commit time.

This patch makes jgit's behavior consistent with with cgit:

prefix: hoge/     -> creates prefix directory "hoge/" entry.
prefix: hoge////  -> creates prefix directory "hoge/" entry.
prefix: hoge/foo  -> does not create prefix directory entry, but for
                     each file/directory entry, prefix is added.

Change-Id: I2610e40ce37972c5f7456fdca6337e7fb07176e5
Signed-off-by: Yasuhiro Takagi <ytakagi@bea.hi-ho.ne.jp>
org.eclipse.jgit.pgm.test/tst/org/eclipse/jgit/pgm/ArchiveTest.java
org.eclipse.jgit/src/org/eclipse/jgit/api/ArchiveCommand.java