/plexorcist

The Plexorcist banishes your binge-watching ghosts and unclutters your watched videos graveyard, bringing order and harmony to your Plex experience!

Primary LanguagePythonApache License 2.0Apache-2.0

Pylint Tests CodeQL Maintainability Test Coverage codecov Known Vulnerabilities

Plexorcist

The Plexorcist banishes your binge-watching ghosts and unclutters your watched videos graveyard, bringing order and harmony to your Plex experience!

In other words it's a small Python script that cleans up any number of Plex Media Server libraries of all watched videos. Automatically delete watched episodes or movies, to clear up space on your Plex Media Server.

Disclaimer

This script should only be executed on a Plex Media Server that you have authorized access to, and only if you are certain that you want to perform a clean-up on specific libraries. It is important to note that the author of this script cannot be held accountable for any unintended loss of data. It is advised that you exercise great caution and prudence before utilizing this script.

Features

  • Suppport for multiple libraries (Movies and TV Shows only)
  • Movies and TV Shows whitelist
  • Remove only videos older than
  • Configurable via config file
  • I18N (via config file) - feeling fancy?
  • Logging
    • Automatic creation and cleanup when file gets too big (1 MB)
    • Logs the timestamp for all actions
    • Logs the name of the Movie or TV Show (including episode title)
    • Logs the space reclaimed after deletion
    • Requests error handling
  • Pushbullet integration (via API key)
  • IFTTT integration (via webhook)
  • CSV report file (timestamp, number of deleted videos, GB reclaimed)

Installation

Recommended

Run this command in your terminal

wget -qO - https://raw.githubusercontent.com/stefanbc/plexorcist/main/plexorcist.sh | bash

Manually

Clone Plexorcist

git clone https://github.com/stefanbc/plexorcist.git

Open Plexorcist

cd plexorcist

Install the dependencies

pip install -r requirements.txt

Give permissions to Plexorcist

chmod +x plexorcist.py

Before running Plexorcist for the first time please read the Documentation.

Documentation

Documentation

Contributing

Contributions are always welcome!

See CONTRIBUTING.md for ways to get started.

Please adhere to this project's code of conduct.

Contributors


stefanbc

License

Apache License 2.0