mvmedia


Namemvmedia JSON
Version 1.0.1 PyPI version JSON
download
home_pagehttps://github.com/samiconductor/mvmedia
SummarySafely move photos and videos
upload_time2020-08-01 22:44:18
maintainer
docs_urlNone
authorSam Simmons
requires_python
licenseMIT
keywords cli media
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            Move Media
==========

Safely move photos and videos from a source directory with arbitrary files to
photo and video destination directories. The media type of the file is used to
determine if it's a photo or video. Any other media types are ignored.

The date and time the photo or video was taken is detected (if possible). If
it is a photo, the EXIF DateTimeOriginal tag is used if present. Else for
photos or videos, the date taken is inferred from the file name since most
media files are named by date taken. Finally, the modify time of the file is
used as a best guess. The destination files are organized by year and given a
consistent file name based on the detected date taken. If a destination file
with the same date taken and different checksum exists, an incrementing suffix
is appended to the file name.

You can optionally remove photos and videos from the source directory that are
older than a provided number of days. Files are only removed if the media file
is copied and matching checksum is verified or if the media file with matching
checksum already exists in the destination.

You can skip files that were recently modified within a provided number of
minutes.

My Use Case
-----------

I run this on my Dropbox camera uploads every night to:
  a. Free up space on Dropbox
  b. Point Plex at split up photos and videos directories
  c. Backup the organized photos and videos

Here's the crontab::

  # move dropbox camera uploads out of dropbox into media folders
  0 2 * * * mvmedia Dropbox/Camera\ Uploads --photos=Media/Pictures --videos=Media/Videos --remove=30 --recent=30 --verbose >> /var/log/dropbox/mvmedia.log

Usage
-----

Help::

  usage: mvmedia [-h] --photos PHOTOS --videos VIDEOS [--remove REMOVE]
                    [--recent RECENT] [--verbose]
                    source

  Move and rename photos and videos

  positional arguments:
    source           Source folder to read media from

  optional arguments:
    -h, --help       show this help message and exit
    --photos PHOTOS  Destination folder to move photos to
    --videos VIDEOS  Destination folder to move videos to
    --remove REMOVE  Remove files older than provided days
    --recent RECENT  Skip files recently modified within the provided minutes
    --verbose        Print verbose output

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/samiconductor/mvmedia",
    "name": "mvmedia",
    "maintainer": "",
    "docs_url": null,
    "requires_python": "",
    "maintainer_email": "",
    "keywords": "cli media",
    "author": "Sam Simmons",
    "author_email": "sam@samiconductor.com",
    "download_url": "https://files.pythonhosted.org/packages/22/d5/e55cc608521d82a0ccc8a97529013e9d722d3ed917af2eff21b1e4871bad/mvmedia-1.0.1.tar.gz",
    "platform": "",
    "description": "Move Media\n==========\n\nSafely move photos and videos from a source directory with arbitrary files to\nphoto and video destination directories. The media type of the file is used to\ndetermine if it's a photo or video. Any other media types are ignored.\n\nThe date and time the photo or video was taken is detected (if possible). If\nit is a photo, the EXIF DateTimeOriginal tag is used if present. Else for\nphotos or videos, the date taken is inferred from the file name since most\nmedia files are named by date taken. Finally, the modify time of the file is\nused as a best guess. The destination files are organized by year and given a\nconsistent file name based on the detected date taken. If a destination file\nwith the same date taken and different checksum exists, an incrementing suffix\nis appended to the file name.\n\nYou can optionally remove photos and videos from the source directory that are\nolder than a provided number of days. Files are only removed if the media file\nis copied and matching checksum is verified or if the media file with matching\nchecksum already exists in the destination.\n\nYou can skip files that were recently modified within a provided number of\nminutes.\n\nMy Use Case\n-----------\n\nI run this on my Dropbox camera uploads every night to:\n  a. Free up space on Dropbox\n  b. Point Plex at split up photos and videos directories\n  c. Backup the organized photos and videos\n\nHere's the crontab::\n\n  # move dropbox camera uploads out of dropbox into media folders\n  0 2 * * * mvmedia Dropbox/Camera\\ Uploads --photos=Media/Pictures --videos=Media/Videos --remove=30 --recent=30 --verbose >> /var/log/dropbox/mvmedia.log\n\nUsage\n-----\n\nHelp::\n\n  usage: mvmedia [-h] --photos PHOTOS --videos VIDEOS [--remove REMOVE]\n                    [--recent RECENT] [--verbose]\n                    source\n\n  Move and rename photos and videos\n\n  positional arguments:\n    source           Source folder to read media from\n\n  optional arguments:\n    -h, --help       show this help message and exit\n    --photos PHOTOS  Destination folder to move photos to\n    --videos VIDEOS  Destination folder to move videos to\n    --remove REMOVE  Remove files older than provided days\n    --recent RECENT  Skip files recently modified within the provided minutes\n    --verbose        Print verbose output\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Safely move photos and videos",
    "version": "1.0.1",
    "split_keywords": [
        "cli",
        "media"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "md5": "2cb3007aacca5dc6a8228dbc8b9cce4d",
                "sha256": "2a6bf556cbaf2748d0fb55c143aaa7f16ebe093b7a2e625405055cbb2b652511"
            },
            "downloads": -1,
            "filename": "mvmedia-1.0.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "2cb3007aacca5dc6a8228dbc8b9cce4d",
            "packagetype": "bdist_wheel",
            "python_version": "3.8",
            "requires_python": null,
            "size": 6630,
            "upload_time": "2020-08-01T22:44:19",
            "upload_time_iso_8601": "2020-08-01T22:44:19.176624Z",
            "url": "https://files.pythonhosted.org/packages/3b/d1/97501e587299361ed51e062d596c3e665c061c895be13d376b790ff1113d/mvmedia-1.0.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "md5": "9a1e3046fdd555ba382650401fc21324",
                "sha256": "bbf8635311f05b4210bb4d6d6e3c279a655b953f28810d1479dc93dbfff0da22"
            },
            "downloads": -1,
            "filename": "mvmedia-1.0.1.tar.gz",
            "has_sig": false,
            "md5_digest": "9a1e3046fdd555ba382650401fc21324",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": null,
            "size": 5155,
            "upload_time": "2020-08-01T22:44:18",
            "upload_time_iso_8601": "2020-08-01T22:44:18.230268Z",
            "url": "https://files.pythonhosted.org/packages/22/d5/e55cc608521d82a0ccc8a97529013e9d722d3ed917af2eff21b1e4871bad/mvmedia-1.0.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2020-08-01 22:44:18",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "github_user": null,
    "github_project": "samiconductor",
    "error": "Could not fetch GitHub repository",
    "lcname": "mvmedia"
}
        
Elapsed time: 0.14825s