Skip to main content

organize-photos

The organize-photos is a Python CLI program that allows you to organize your photos into subfolders based on their EXIF metadata. You can define a custom pattern to create new paths for your photos, making it easy to sort and categorize your image collection.

Features

  • Organize photos based on EXIF metadata such as date and time taken.
  • Customize the path structure using a template with placeholders for year, month, day, hour, minute, and second.
  • Copy and rename images to the destination directory, maintaining the folder structure specified by the template.
  • Supports UNIX-style glob patterns for selecting files in the source directory.

Installation

Development

Prerequisites: pdm for environment management

  1. Clone this repository.
git clone https://github.com/ohmycoffe/organize-photos.git
  1. Navigate to the project directory.
cd organize-photos
  1. Install the required dependencies using pdm.
pdm install -G dev

Install pre-commit.

pdm run pre-commit install
  1. Run tests.
pdm run pytest

NOTE: This repository supports also GNU Make commands

make help

Usage

You can easily install the latest released version using binary installers from the Python Package Index (PyPI):

pip install organize-photos --user
  • source-dir: The source directory containing the photos you want to organize.
  • -d, --dest-dir: The destination directory where copied and renamed images will be saved. If not provided, the default is the current working directory.
  • -t, --template: The template for generating new file paths. Customize the path structure using placeholders such as ${year}, ${month}, ${day}, ${hour}, ${minute}, and ${second}.
  • -p, --file-pattern: The pattern for selecting files in the source directory. Use UNIX-style glob patterns to filter which files will be processed. The default is to process all files.

Example

organize-photos /path/to/source/photos -d /path/to/output -t "${year}/${year}${month}${day}${hour}${minute}${second}" -p "**/*.jpg"

This command will organize the photos in the source directory based on the specified template and file pattern and save the organized photos in the destination directory. For instance, if you have a file located at /path/to/source/photos/image1.jpeg, which was created on January 3, 2019, at 20:54:12, the program creates a copy of the file at /path/to/output/2019/20190103205412.jpeg following the specified pattern.

License

organize-photos is released under the MIT License.

Author

Metadata

Release files for organize-photos 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for organize-photos 0.1.0
File Size Uploaded Provenance Actions
organize_photos-0.1.0.tar.gz 11.5 kB Without provenance Details for organize_photos-0.1.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for organize-photos 0.1.0
File Interpreter ABI Platform Actions
organize_photos-0.1.0-py3-none-any.whl Python 3 none any Details for organize_photos-0.1.0-py3-none-any.whl

Total release size: 21.6 kB

Release files / organize_photos-0.1.0.tar.gz

Download URL organize_photos-0.1.0.tar.gz
Size 11.5 kB
Tags Source
SHA-256 checksum
How to use checksums
2a0f6c71056da33efc93f7330dcf07f33cdcb16e197a8279a9eabebc20332d3e
BLAKE2b-256 checksum
How to use checksums
449b9243799205fff56d2344c0b2d1d28136bf6c036543d99a28cfa902b489e0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via pdm/2.9.3 CPython/3.10.7

Release files / organize_photos-0.1.0-py3-none-any.whl

Download URL organize_photos-0.1.0-py3-none-any.whl
Size 10.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e73877ed31bd0bb1e05e3abe9a92b6289291f10f1c4066da56b51dbc0c9ff70c
BLAKE2b-256 checksum
How to use checksums
07bf1a9dc6f4328f2f14f95b2d5bfa6e741d40efc64b0f419ef338e07dcfb960
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via pdm/2.9.3 CPython/3.10.7

Security for organize-photos 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page