The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
.
google unix.com




Thread: ls command help
View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #1 (permalink)  
Old 10-23-2006
princssashes princssashes is offline
Registered User
  
 

Join Date: Oct 2006
Posts: 3
Unhappy ls command help

Okay so I am very confused as to how to do this it says it is an exercise in my book but never talks about it or explains it please help I have tried everything every combination i can think of.

find out which of these filename paths exist using the ls command and save the list to a file in the pwd name 'existentFiles'

/etc/magic /sbin/fsck /boot/grub/menu.lst /usr/share/games/wombat /var/cache/man/index.db /usr/bin/defcon

with parameters that aside from the file name args, only the -1 flag for the ls command should be used.

I have no clue what the command would be I have tried
ls -1 /etc/magic /sbin/fsck /boot/grub/menu.lst /usr/share/games/wombat /var/cache/man/index.db /usr/bin/defcon > existentFiles

and many variations but nothing........

then the 2nd part is to find out from the same list which pats exist and which dont using the same parameters except adding both a list in the pwd named existentFiles and a list in the pwd for nonexistantFiles

Please help