Adds IPTC geographic metadata to photos by reverse geocoding from lat/lon, the following IPTC tags are added:
- Country
- State
- City
- Location
- Install Node
- Install ExifTool
- Run
npm install -g geo-rename(oryarn global add geo-renameif you have Yarn)
geo-rename [OPTIONS] [FILES]
Options:
--cache-folder <path>
-f, --force
-h, --help
--offline
-q, --quiet
-s, --skip-backup
-v, --verbose
-V, --version
- I have not tested this other than with my own photos. May or may not work with your photos. Use at your own risk.
- Google only allows 15,000 requests per IP per day. Script uses a local cache, but if you have many unique locations and photos, you may run over this limit.
Fails if one of these isn't defined though:
exiftool nontagged.jpg '-testname<${CreateDate;%Y-%m-%d %H.%M.%S} ${Location;}-${City;}-${State;}-${Country}%-c.%le' 0.0.0: Poor quality code sitting on GitHub for the world to see
- Query Google
- Cache in db
- Write to files
- Support reading directories
- Write tests
- Consider
exiftool-vendored(check performance) - Setup code auto-formatting & lint
- Consider using flow https://javascriptplayground.com/blog/2017/01/npm-flowjs-javascript/
- Allow configuring Google API key
- Renaming
- Preview
- Allow output to destination directory
- Bash completion via tabtab or other
- Ditch
debugfor verbose output for better output - Progress bar
- Emoji / prettier output? https://github.com/sindresorhus/awesome-nodejs#command-line-utilities
- Update notification https://github.com/yeoman/update-notifier
MIT