• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: automator shellscript
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: automator shellscript


  • Subject: Re: automator shellscript
  • From: Ron Hunsinger <email@hidden>
  • Date: Thu, 10 Dec 2009 17:42:49 -0800

At 9:07 PM +0100 12/10/09, René Brugman wrote:
If I get this to work I like the shell script to produce a standard text depending on the result of the grep command, something like "FOUND" or "NOT FOUND"

cd aaaa/bbbb/ if grep -qi texttobefound file.rtf then echo FOUND else echo NOT FOUND fi

Alternatively, if you want to return the found text (if any) or nothing at all (if not):

    cd aaaa/bbbb/
    grep -i texttobefound file.rtf || true

-Ron Hunsinger
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Automator-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >automator shellscript (From: RenĂ© Brugman <email@hidden>)

  • Prev by Date: Re: automator shellscript
  • Next by Date: Working with Preview
  • Previous by thread: Re: automator shellscript
  • Next by thread: Working with Preview
  • Index(es):
    • Date
    • Thread