[X-Unix] Bash script
Eugene Lee
list-themacintoshguy at fsck.net
Fri Jul 9 06:26:53 PDT 2004
On Thu, Jul 08, 2004 at 06:33:41PM -0700, Scott Haneda wrote:
:
: For some reason this is not working, If I run it alone, like so:
: tr "\r" "\n" < /Applications/EIMS/Filters/STF.log | grep 89
: I get hits, if I run it as a shell script
: stfgrep 89 I get nothing.
:
: #!/bin/bash
:
: if [ "$1" = "" ]; then
: echo "Enter in something to search on"
: exit 0
: fi
:
: tr "\r" "\n" < /Applications/EIMS/Filters/STF.log | grep "$1"
I saw some odd whitespace characters in your shell script. What editor
are you using to write it? Whatever app it is, be sure to save as a
plain text file. That might be the problem. Otherwise, your script is
perfectly fine.
--
Eugene Lee
http://www.coxar.pwp.blueyonder.co.uk/
More information about the X-Unix
mailing list