Jump to content

Search in one site with keywords list

Recommended Posts

Hi, I am a designer and for my job I need sometimes to find a bunch of pictures for my design presentation.

I've read several thread regarding this but I think I am still clueless as to how it works. Maybe just need some one to point me to the right direction.


What I am looking for:


I have a small list (10-15 words) with keywords on txt file:







And there is one site which I want to open in standard browser (safari) with this list of urls: 







What is the best way to do it?

Any help would be appreciated.

Edited by Yuri
Link to comment

Quite simple to do, you need only loop through each line and tell them to open (when given a URL, this will open in the default browser):

IFS=$'\n' # to prevent problems if a line has more than one word separated by spaces

for line in $(cat '/path/to/file'); do
  open "https://www.shutterstock.com/search/${line}"

Made it into a workflow. It uses a File Action, so select the txt file you want and pick quickopen.

Give it a try and see if there’s something you’d like a bit differently or a more detailed explanation.

Edited by vitor
Link to comment
7 hours ago, Yuri said:

Wow! Thank you! It works well. I am going to buy you a beer :-)


Thank you, I appreciate it.


7 hours ago, Yuri said:

How can I add time lag 1-2 seconds between requests?


You simply add a sleep 1 (or however many seconds you want) line inside the loop.


I’ve uploaded a new version of the workflow that adds a two second delay but also adds URL escaping (in case you ever have non-ASCII characters in your file, it will still work).

Link to comment

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...