RE: In an automator shell script, discovering the path to the application (James C)
RE: In an automator shell script, discovering the path to the application (James C)
- Subject: RE: In an automator shell script, discovering the path to the application (James C)
- From: James C <email@hidden>
- Date: Wed, 21 Dec 2011 13:42:00 +1300
Hi Geoff,
Thanks for telling me your plan.
I think that your "Get Finder Items" is "Get Selected Finder Items".
Do I have the right end of the stick?
I have attached an app which:
- presumes that you have growl installed
- reports the path to the current application as a growl notification
There are two ways that I know of so far, of making it break:
- if you select two applications and then context-menu open, only
one of them runs, and it gets the path from the other one
- if you select something, then change to a terminal, and run the
application with the shell 'open' command
It also may break if another automator work-flow opens it.
It is currently the best plan I have. I plan to run with it, as the
application is now, and try to detect breakage in the shell-script.
Regards,
James.
>
> Message: 1
> Date: Mon, 19 Dec 2011 20:32:06 +0000
> From: Geoff Dillberg <email@hidden>
> Subject: RE: In an automator shell script, discovering the path to the
> application (James C)
> To: "email@hidden"
> <email@hidden>
> Message-ID:
> <email@hidden>
>
> Content-Type: text/plain; charset=us-ascii
>
> Hi James,
>
> I've done similar to what you're attempting.
> I needed a third-party action: Get Parent Folder
> http://mac.softpedia.com/get/Automator-Actions---Workflows/Get-Parent-Folder.shtml
>
> You'll need to do a "Get Finder Items" on your app in order to feed the results "Get Parent Folder"
> Then save those results to a Set Variable (I forget the whole name of that action)
> Then before you run your shell script do a Get Variable
> Then in your Run Shell Script action 'pass input' pulldown, choose 'as arguments' or 'to stdin' depending on your needs.
>
> My applet is basically a Automator wrapper around a ruby shell script that acts on a folder, and generates an HTML report in the same folder as the input folder.
>
> You can contact me directly at:
> email@hidden (hopefully you won't get spam filtered by my corporate email server)
> email@hidden (personal email, but I don't check it every day, so I may not respond quickly)
>
> Hope this helps,
> Geoff
>
Attachment:
nexterGyve.app.zip
Description: Zip archive
_______________________________________________
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