[HPADM] RE: [SUMMARY] ls works but when compress files using for loop - g ot problem

From: Ruby Domalanta (rdomalan@dairy-farm.com.ph)
Date: Mon Dec 01 2003 - 20:13:18 EST


Would like to thank all of those guys who spent their time help me out....
This forum is really awesome!!!
Special thanks to David Totsch who gave the best solution....
 
There is non-printing characters on some of my files that is why the output
is kind a odd. Instead of using for loop, use
 
compress *.tar
 
Why i haven't thought about it?? Thanks again...
 
 -----Original Message-----
From: hpux-admin-owner@DutchWorks.nl
[mailto:hpux-admin-owner@DutchWorks.nl]On Behalf Of Ruby Domalanta
Sent: Monday, December 01, 2003 4:15 AM
To: hpux-admin@DutchWorks.nl
Subject: [HPADM] ls works but when compress files using for loop - got
problem

Hi Gurus,

Has anyone experience this before? How come it cannot locate the file, I
even tried to use the full path but getting the same error " no such file or
directory"?

[root@ftp_depot]# for i in `ls`; do echo $i; done
etc.tar
optscript.tar
usrlocal.tar
varnamed.tar

[root@ftp_depot]# for i in `ls`; do echo $i; compress $i; done
etc.tar
etc.tar: No such file or directory
optscript.tar
optscript.tar: No such file or directory
usrlocal.tar
usrlocal.tar: No such file or directory
varnamed.tar
varnamed.tar: No such file or directory

: No such file or directory

Thanks in advance,
Ruby Ann Domalanta

--
             ---> Please post QUESTIONS and SUMMARIES only!! <---
        To subscribe/unsubscribe to this list, contact majordomo@dutchworks.nl
       Name: hpux-admin@dutchworks.nl     Owner: owner-hpux-admin@dutchworks.nl
 
 Archives:  ftp.dutchworks.nl:/pub/digests/hpux-admin       (FTP, browse only)
            http://www.dutchworks.nl/htbin/hpsysadmin   (Web, browse & search)


This archive was generated by hypermail 2.1.7 : Sat Apr 12 2008 - 11:02:37 EDT