[ale] xargs

Dow Hurst dhurst at kennesaw.edu
Tue Nov 26 09:58:20 EST 2002


sorry I can't help with BSD since I am not familiar.  My favorite Unix 
command is xargs since it is so handy.  Can you install the GNU commands 
onto BSD and scrap the BSD commands?
Dow


David S. Jackson wrote:

>On Mon, Nov 25, 2002 at 05:42:30PM -0500 Dow Hurst <dhurst at kennesaw.edu> wrote:
>  
>
>>You'd need to be in the same directory where you were running the 
>>command since you've given ls the....
>>
>>Wait a minute.  Is that a number one or the letter L? :-)
>>Dow
>>    
>>
>
>Okay, here's the scoop, I think.
>
>First, I'm using FreeBSD, and its xargs is significantly
>different from GNU's, so that was a good part of the problem.  
>
>Second, the command, which works fine in Linux, is
>
>$  touch one two three
>$  ls one two three | xargs -i mv \{\} \{\}.suffix
>
>Now you have one.suffix two.suffix three.suffix.
>
>To move them back, you could go
>
>$  ls {one,two,three}* | xargs -i basename \{\} .suffix \
> | xargs -i mv \{\}.suffix \{\}
>
>So, I'm banging my head on the manpage for xargs in freebsd,
>where -J is supposed to be equivalent to -i, but it doesn't seem
>to work out that way...  :-)
>
>Oh, -1 was a number one.  That argument to ls forces the output
>to be in a single column.  I guess is isn't necessary here, but I
>can't help myself...
>
>  
>

-- 
__________________________________________________________
Dow Hurst                  Office: 770-499-3428
Systems Support Specialist    Fax: 770-423-6744
1000 Chastain Rd., Bldg. 12
Chemistry Department SC428  Email:dhurst at kennesaw.edu
Kennesaw State University         Dow.Hurst at mindspring.com
Kennesaw, GA 30144
*********************************
*Computational Chemistry is fun!*
*********************************


_______________________________________________
Ale mailing list
Ale at ale.org
http://www.ale.org/mailman/listinfo/ale






More information about the Ale mailing list