Jump to content

Droplet Photoshop and Alfred shortcut


Recommended Posts

Posted

Hello to all
I would like to create a workflow to automate a task
I have a Photoshop droplet that allows me to convert images and save them in a folder
I would like to be able to select these image files from the Finder and with a keyboard shortcut that Alfred launches the Photoshop droplet
Do you know how to do it?
Thanks a lot :)

Posted

I haven’t messed with Photoshop Droplets in over a decade, but unless they’ve changed they’re just apps to which you can pass arguments.


What you want should work by adding a Hotkey Trigger (with Argument: Selection in macOS) to an Open File Action (leave the left side empty, and on the right side drop the droplet).


Bonus: add a File Action Trigger and you can also get to it from Alfred’s file navigation and the Universal Actions shortcut.

 

2 hours ago, pazou said:

convert images and save them in a folder

 

Alternatively, just use the Convert Image Format Automation Task, no Photoshop or droplet needed.

Posted

Hello Vito
thank you very much for your answer


It works, but not totally 
I select several files in the Finder, but the workflow works only on one file (the first one in the list)

 

I didn't use the "Convert Image Format" because I need a specific image conversion, with a specific color profile to add

Posted

Yes, here it is

 

[14:06:22.854] Convert[Hotkey] Processing complete
[14:06:22.854] Convert[Hotkey] Passing output '(
    "/Users/marketing/Desktop/\U2022Images/EOTS Chief Stew Sri Astuti-RET.jpg",
    "/Users/marketing/Desktop/\U2022Images/IMG_9041-RET.jpg",
    "/Users/marketing/Desktop/\U2022Images/Julien-Captain_1-RET.jpg"
)' to Open File

 

Thank you Vitor

Posted

Everything looks correct. Let’s try it another way. Instead of Open File, have a Run Script Action with default settings and the following code:


for file in "${@}"; do
  "/PATH/TO/DROPLET" "${file}"
done


Replace /PATH/TO/DROPLET with the full path to the droplet.

Posted

Thanks again Vitor, I appreciate your help :)

 

it doesn't work

this is the debugger :

 

 

[17:08:36.221] Convert 300 RVB - COPY[Hotkey] Processing complete
[17:08:36.229] Convert 300 RVB - COPY[Hotkey] Passing output '(
    "/Users/marketing/Desktop/Images/Julien-Captain_1-RET.jpg",
    "/Users/marketing/Desktop/Images/IMG_9041-RET.jpg",
    "/Users/marketing/Desktop/Images/EOTS Chief Stew Sri Astuti-RET.jpg"
)' to Run Script
[17:08:36.299] ERROR: Convert 300 RVB - COPY[Run Script] /Users/marketing/Library/Caches/com.runningwithcrayons.Alfred/Workflow Scripts/58133C4F-214B-4D9A-96FB-0918630CBFC6:2: permission denied: /Applications/•Verif Photos/300 RVB.app
/Users/marketing/Library/Caches/com.runningwithcrayons.Alfred/Workflow Scripts/58133C4F-214B-4D9A-96FB-0918630CBFC6:2: permission denied: /Applications/•Verif Photos/300 RVB.app
/Users/marketing/Library/Caches/com.runningwithcrayons.Alfred/Workflow Scripts/58133C4F-214B-4D9A-96FB-0918630CBFC6:2: permission denied: /Applications/•Verif Photos/300 RVB.app

 

Posted

And this is the script :

 

for file in "${@}"; do
  "/Applications/•Verif Photos/300 RVB.app" "${file}"
done

 

Posted

Ah, yes, the droplet is an app. Try:

 

for file in "${@}"; do
  open -a "/Applications/•Verif Photos/300 RVB.app" "${file}"
done

 

Posted

Hello Vitor

 

I just tried, the problem is still there
There is only one file that is converted

 

The debugger if you need it :

[09:13:16.429] Convert 300RVB[Hotkey] Processing complete
[09:13:16.437] Convert 300RVB[Hotkey] Passing output '(
    "/Users/marketing/Desktop/Images/Image 3.jpg",
    "/Users/marketing/Desktop/Images/Image 2.jpg",
    "/Users/marketing/Desktop/Images/Image 1.jpg"
)' to Run Script

 

 

Anyway, thanks a lot for your help ;)

 

 

Posted

One more:

 

for file in "${@}"; do
  open -Wa "/Applications/•Verif Photos/300 RVB.app" "${file}"
done

 

It’s weird that Photoshop droplets only accept one file when given arguments directly from the command-line. What we’re doing above is looping through each image and giving them as the argument one at a time. In the new iteration, it will wait for the droplet to exit before going to the next one.

Posted

Hello Vitor
Sorry, I couldn't answer you yesterday ;) 
I think the problem could come from the Droplet
The script works, but something strange happens: on the 3 images, 2 are converted. And the two converted images remain open in photoshop
The script worked a few times by converting well the 3 images, keeping open one image in photoshop
I then tried with a folder of 8 images, some times it converts 3 images, some times 6 images, it's never complete

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
×
×
  • Create New...