The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Advanced & Expert Users
Google UNIX.COM



Thread: mailx
View Single Post in UNIX Forums - Click on the Thread or Permalink to View Entire Thread -->
  #4 (permalink)  
Old 05-14-2008
era era is offline
Herder of Useless Cats
 

Join Date: Mar 2008
Location: /there/is/only/bin/sh
Posts: 2,907
It's just weird to use more because it's intended for interactive use, it's a human-friendly interface for when cat is cumbersome for humans to use.

The shell script, as posted, should absolutely not care whether or not it has write access to the file. There is more to this than you are revealing, I'm afraid.

Replacing more with cat on the freak theory that more sometimes prints something which causes the file it's reading to be corrupted when you run it inside backticks is the best I can offer at this point, sorry.
Reply With Quote