Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Upload all photos from a directory using command line (openphoto-php -
for i in $(ls /path/to/directory/*.JPG) ; do
./openphoto -h yourhost -e /photo/upload.json -F "photo=@$i" -X POST;
Copy link

This is great, but would it be possible to add tags optionally at the same time? So all the uploaded photos are linked with the provided tags?

Copy link

jmathai commented Oct 10, 2011

Just add tags as another parameter

./openphoto -h yourhost -e /photo/upload.json -F "photo=@$i" -X POST -F "tags=tag1,tag2";

Copy link

jdeproost commented Oct 11, 2011 via email

Copy link

tommyla commented Sep 12, 2012

use folders as tags and albums

so if you have a
"Vacation 2012" folder
then it will be album "Vacation 2012" and all pictures inside it has the tags "Vacation,2012"

Copy link

I like this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment