I would like to know how to go about exporting a load of image ID's based off the image name. For example
'how to dig gold' search may have a load of images like
how to dig gold.mp4001.jpg
how to dig gold.mp4002.jpg
how to dig gold.mp4003.jpg
how to dig gold.mp4004.jpg
how to dig gold.mp4005.jpg
Their wordpress image IDs are along the range of 8322-8326. I would like to run a single command to do this if possible as I will be doing this for hundreds of different keywords. The results should look like the following
how to dig gold-8322
how to dig gold-8323
how to dig gold-8324
how to dig gold-8325
how to dig gold-8326