Skip to main content
This example groups photos into a country/city/town folder hierarchy based on their GPS coordinates, and names each file with the taken date and address. The original folder structure is discarded entirely; the new structure comes from the locations embedded in the photo EXIF data.

Command

Key arguments

Before and after

Before (photos/):
After (organized-albums/):

What you see in the output

Photos are organized by location, not by their original album names. All ten Arezzo photos from the Italy album land in Italia/Arezzo/, named 2008.10.22-Italia-Arezzo-1.jpg through 2008.10.22-Italia-Arezzo-10.jpg. The one Florence photo goes into Italia/Firenze/Quartiere 1/. The two Madrid photos from Spain Journey land in España/Madrid/. The folder depth matches the number of distinct address levels returned by OpenStreetMap for each location. A single photo taken in Kenya resolves to only a country, so its folder is Kenya/ with no city or town sub-level.
Two photos land in no-address/: Italy album/IMG_2371.jpg has a taken date but no GPS coordinate, and Spain Journey/IMG_5397.jpg has neither a date nor a coordinate. Both are placed in no-address/ at the root of the output because --no-coordinate InSubFolder routes GPS-less photos there. Their original file names are preserved.
Combine this strategy with --folder-append DayRange and --folder-append-location Suffix to also show date ranges on each location folder. For example, Arezzo would become Arezzo-2008.10.22-2008.10.22. This gives you both geographic and temporal context in the folder listing.