Jump to content
Sign in to follow this  
Wacky

Automator

Recommended Posts

Ok I'm new to Automator and wondering how to create a simple action.

I want the computer to take a screen shot and demand a password when I open up certain folders (Applications folder, Documents folder)

Any help?

Thanks.

Share this post


Link to post
Share on other sites

I want the computer to automatically take a screen shot every time I open up certain folders. Is there a way to do that in automator? I have figured out how to do the screenshot, but it just takes it of automator and not the folder when I open it.

Share this post


Link to post
Share on other sites

The best the screenshot action will do is allow you to select the window for the screenshot, but you would still need to call the action manually. If I understand correctly, you want the workflow to be launched only when certain folders are opened. As far as I know, that would require you to "flag" each desired folder somehow and the workflow would have to be running in the background and be able to know when a folder with that flag was opened. Unless I've missed something, automator doesn't have that functionality yet.

 

Can you tell us why you want a picture of the contents of these folders when they are opened in addition to a password protecting them? Maybe there is another solution to your need.

Edited by Dolphbucs

Share this post


Link to post
Share on other sites

You can attach your Automator script to a folder by using Folder Actions.

First, save the Automator script as "Plug-in" for "Folder Actions". (It'll get dumped somewhere in your Library/Workflows folder.)

Next, in Finder, right-click (control-click) on a folder in in the contextual pull-down find "Enable Folder Actions". Then, right-click (control-click) again and select Attach Folder Action... and in the dialog click the left "+" and add the folder you want, then select the folder and click the right "+" and add the automator script you created.

 

On the other hand, "demanding a password" isn't really something you can do in Automator. You could script an nput dialog to get the text, but that won't stop the folder from opening (and even if it did, it's dead easy to Force Quit the script!)

 

Like Dolphbucs, I wonder if there isn't some better way to implement what you're really trying to accomplish. For example, if you're trying to protect the content of a folder from prying eyes, using an encrypted Disk Image may be more appropriate. And if you want to log the contents of a folder, using a simple shell comand such as "ls" to write the names, size, and time-modified of all files into a log file might be superior to a screenshot (since the entire set of files may not actually be visible on the screen at any given time.)

Edited by car1son

Share this post


Link to post
Share on other sites
You can attach your Automator script to a folder by using Folder Actions.

First, save the Automator script as "Plug-in" for "Folder Actions". (It'll get dumped somewhere in your Library/Workflows folder.)

Next, in Finder, right-click (control-click) on a folder in in the contextual pull-down find "Enable Folder Actions". Then, right-click (control-click) again and select Attach Folder Action... and in the dialog click the left "+" and add the folder you want, then select the folder and click the right "+" and add the automator script you created.

 

Good call. I got so hung up trying to think of a way to do it all within a single workflow that I didn't even consider Folder Actions. That would be the way to go, the screen shot action would then simply have to be set from full screen to interactive so that you could select the finder window of the desired folder.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

  • Recently Browsing

    No registered users viewing this page.

  • Who's Online (See full list)

    There are no registered users currently online

×