Re: OT: Which tool, and how, to get partial string from file?
Kent writes:
> How can I test to see if the word "tuber" is in the /etc/passwd file,
> reliably, and take an action if it is, and take a different action if
> it's not, in a bash shell script?
By testing the exit status of grep.
--
John Hasler
john@dhh.gt.org (John Hasler)
Dancing Horse Hill
Elmwood, WI
Reply to:
- References:
- OT: Which tool, and how, to get partial string from file?
- From: Kent West <westk@acu.edu>
- Re: OT: Which tool, and how, to get partial string from file?
- From: "Miquel van Smoorenburg" <miquels@cistron.nl>
- Re: OT: Which tool, and how, to get partial string from file?
- From: Kent West <westk@acu.edu>
- Re: OT: Which tool, and how, to get partial string from file?
- From: Kent West <westk@acu.edu>
- Re: OT: Which tool, and how, to get partial string from file?
- From: Kent West <westk@acu.edu>
- Re: OT: Which tool, and how, to get partial string from file?
- From: Kent West <westk@acu.edu>