Thread (18 messages) flat view 18 messages, 12 authors, 2016-06-15

Re: [PATCH] Get rid of cpio in git-clone (was: Re: cpio command not found)

From: Jeff King <hidden>
Date: 2016-06-15 22:43:45

On Wed, Oct 31, 2007 at 09:14:25PM +0100, Erik Mouw wrote:
quoted
Patch, please?
Here you go.
Good, now we have something to critique. :)
-		find objects -depth -print | cpio -pumd$l "$GIT_DIR/" || exit 1
+		cp -Rp$l objects/ "$GIT_DIR/" || exit 1
cp -l isn't even close to portable. It's not in POSIX, and doesn't work
on (at least) Solaris.

I think Mike's patch (cpio if available, copy otherwise) is a reasonable
approach. If there are other methods (and I think cp -l is not
unreasonable for systems where it is supported and cpio is unavailable),
then perhaps it is worth trying them one by one and dropping back to
full copy if all fail.

-Peff
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help