Recently I added context menu under services to execute python script but I think it would be convenient if I add a button on the Finder toolbar, like next to New Folder Button in below image.

enter image description here

Is this possible at add button on Finder Toolbar that triggers a python script and passes the current folder as argument ?

  • This is most likely possible by making the same service which I assume you did in Automator into a app and then holding the option+ command keys and drag the app on to a finder window tool bar. Might be worth showing what you have in the service
    – markhunte
    Commented Dec 31, 2013 at 15:03
  • @markhunte : ok then how to make the service as an app ? Commented Dec 31, 2013 at 16:37
  • To answer that properly you need to show us your workflow using scene shots and code snippets in your Question.
    – markhunte
    Commented Dec 31, 2013 at 16:56
  • here is the workflow with the screenshot: apple.stackexchange.com/questions/115371/… Commented Dec 31, 2013 at 17:00

1 Answer 1


See if this works.

Download the Get first Finder Window Path BETA 10.9 automator action from from my blog : my_very_first_automator_action

The action returns the path of the front most finder window. It does not take any input from above actions. The post explains it all :-)

Create a new Application document in Automator and add the Get first Finder Window Path to it. Then just add you Run shell script after it.

Save as Application. And then do the drag and drop.

I would test it with your code but I do not have the python slideshow...

Note from Apple documentation in regard to Third party Actions.

Installing Actions When your action has been thoroughly debugged and tested, build a deployment version of the bundle (using the proper optimizations). Then create an installation package for the action (or add the action to your application’s installation package). The installer should copy the action to /Library/Automator or ~/Library/Automator, depending on whether access to the action should be system wide or restricted to the installing user.

Instead of installing your action separately, you can put it inside the bundle of your application, especially if the action uses the features of that application. When Automator searches for actions to display, it looks inside registered applications as well in the standard Automator directories. The advantage of packaging your actions inside an application is that you don’t need to create a separate installation package to install the actions. To install the actions, users need only drag the application to a standard location.

Action bundles should be stored inside the application wrapper at Contents/Library/Automator. Thus, if your action is MyAction.action and your application is MyApp.app, the path inside the application would be:


You can either manually copy an action into this location (after creating the necessary subdirectories) or you have Xcode copy it using a Copy Files build phase. If you copy an action into an application bundle but the application is already installed on a system, you must get Launch Services to recognize that the application has new content to register (that is, the new action) by changing the application’s modification date. You can do this by entering the touch command in the Terminal application.

sudo touch /Applications/MyApp.app

Or you can rename the application in Finder to something else, change it back to the original name, and then launch the application once.

  • well the link you gave isn't working: Hmm, www.markosx.com isn't loading right now. Commented Dec 31, 2013 at 19:27
  • Hmm. I out at the mo. But the link loads on my iPhone?
    – markhunte
    Commented Dec 31, 2013 at 21:20
  • yes this does solves what I was looking for, and I can do the same way for my slideShow to open. but the path that I specify in Automator > Run Shell Script is going to be different for every user, which means I would have to some how insert the install path in the Run Shell Script for the app to work with anyone. Do u have slightest idea how to do that or do I need to create another question on apple.stackexchange ? Commented Jan 1, 2014 at 3:16
  • 1
    Glad that worked. I think it would need to be a new question. Giving details of why the path for each user will be different and what you need.. You know the drill:-)
    – markhunte
    Commented Jan 1, 2014 at 10:52
  • I've added a note regarding third party action which you may need to know in regards of distributing a application that uses a third party action.
    – markhunte
    Commented Jan 1, 2014 at 11:29

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .