gnu-arch-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Gnu-arch-users] cvs export for tla?


From: Jason McCarty
Subject: Re: [Gnu-arch-users] cvs export for tla?
Date: Fri, 18 Feb 2005 17:29:26 -0500
User-agent: Mutt/1.5.4i

John Arbash Meinel wrote:
[regarding -T for tar]
> And you're right, -T - is much better than xargs, since xargs can't be
> told to only split on newlines.

Might it be a bad idea to use xargs with tar in any case, since with
enough files xargs would run "tar cjf ..." two or more times?

> I understand that they decided to use '-0' to handle it, but it would
> still be nicer to do the newline thing. In filenames, spaces are common,
> newlines are significantly less so.
> There was a discussion of creating an xxargs, or "tla xargs" to handle
> tla escapes, since Tom doesn't really like the -0 flag. Don't know that
> it ever went anywhere.

I use this (zsh) function, on the few occasions it matters:
  xxargs () { # read newline-separated pika-escaped names and hand them to xargs
    local file
    (while read -r file; do
       tla escape --unescaped "$file"
       echo -en '\0'
     done
    ) | xargs -0 "$@"
  }

-- 
Jason McCarty <address@hidden>




reply via email to

[Prev in Thread] Current Thread [Next in Thread]