Advertisement
Guest User

Untitled

a guest
Mar 20th, 2019
58
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.41 KB | None | 0 0
  1. #!/usr/bin/ksh
  2. file="test.txt"
  3. while IFS= read -r line
  4. do
  5. # display $line or do somthing with $line
  6. echo "$line"
  7. fileloc=`locate "$line"`
  8. i=`echo $?`
  9. if [ $? != 0 ]
  10. then
  11. echo "Unsuccessful"
  12. else
  13. echo $fileloc
  14. cp $fileloc /home/prakameg/PO_AUDIT
  15. echo "Successful"
  16. fi
  17. done <"$file"
  18.  
  19. 11687892
  20. 11687893
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement