A simple script to sort your media!
Explore the docs »
View Demo
·
Report Bug
·
Request Feature
Table of Contents
There are many great media sorters out there, but none really suited me. So I created my own. The main idea here is simplicity, and the ability to sort even media who has missing or unusual tags. This app is built with and leverages .
- You first need to have ExifTool (minimum version of 12.15) installed from here. Make sure to follow the steps in the official docs.
- Download the latest stable solution from here.
NOTE: Currently only Linux is supported.
Now everything is installed, you should know that the solution is made of 2 independent but complimentary steps:
To generate the exec file:
app -m create <media_dir> <new_dir>
A file of the name exec_file.json
will be created.
The Exec File
is a json file that contains the different media files found. In that file they will be mapped to there new desired location
in addition to some parameters.
Typically, it would look like the following:
{
"$options": {
"mode": "COPY",
"delete_empty_dir": true,
"delete_error_files": true,
"delete_exec_file": true
},
"path_mapping": {
"new_dir":{
"YYYY.MM": {
"Camera": {
"date.png": "old_path"
}
},
...
},
...
},
"errors": {
"error_file_path": "error_message",
...
}
}
As you can see $option
contains the different settings,
path_mapping
contains the mapping starting with a tree structure for the new path mapped to the old path,
errors
contains all the paths of the unrecognized files (or any other error that would show as the error_message)
The new path created is in the following format new_dir/YYYY.MM/Camera/date.png
.
You can change anything in this file as long as you keep the structure. Thus, allowing you to have complete control.
After creating the Exec File you can execute it using:
app -m execute
If you need to see all available options use:
app -h
- Add Linux Support
- Add Windows Support
- Allow for more control during the creation of the Exec File
- Create version with packaged ExifTool
- Use a better file structure than Json
See the open issues for a full list of proposed features (and known issues).
Any contribution is greatly appreciated. If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!
You can also fork the project and submit a pull request.
Distributed under the Apache-2.0 License. See LICENSE.txt
for more information.
Ahmad Obeid - [email protected]
Project Link: https://github.com/obeidahmad/family-media-sorter
The amazing resources and library that made this project possible: