-
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Rewrite nearly the whole thing for better parsing, support, readabi…
…lity, etc. (OOP forever!) - Consolidate Plex API config with schedules, now in config.yaml - Changes to schema for schedules - No more priority of, e.g. date_range over monthly - No more default - `misc` reworked to `always` - Update Docker files - Update README - Delete old files, linting stuff (screw mypy)
- Loading branch information
Showing
25 changed files
with
1,232 additions
and
1,500 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,79 @@ | ||
# All keys must be in lowercase | ||
# All paths will be case-sensitive based on your environment (Linux, Windows) | ||
|
||
plex: | ||
url: http://localhost:32400 # URL to your Plex server | ||
token: thisismyplextoken # Your Plex token | ||
|
||
# Always include these pre-rolls | ||
always: | ||
enabled: true | ||
paths: | ||
- "path/to/video1.mp4" | ||
- "path/to/video2.mp4" | ||
- "path/to/video3.mp4" | ||
count: 10 # Optional, randomly select X many videos from the list rather than all of them | ||
weight: 1 # Optional, how much to emphasize these pre-rolls over others (higher = more likely to play) | ||
|
||
# Schedule prerolls by date and time frames | ||
date_range: | ||
enabled: true | ||
ranges: | ||
- name: "New Years" # Optional name for logging purposes | ||
start_date: 2020-01-01 # Jan 1st, 2020 | ||
end_date: 2020-01-02 # Jan 2nd, 2020 | ||
paths: | ||
- "path/to/video1.mp4" | ||
- "path/to/video2.mp4" | ||
- "path/to/video3.mp4" | ||
weight: 2 # Optional, add these paths to the list twice (make up greater percentage of prerolls - more likely to be selected) | ||
- start_date: xxxx-07-04 # Every year on July 4th | ||
end_date: xxxx-07-04 # Every year on July 4th | ||
paths: | ||
- "path/to/video1.mp4" | ||
- "path/to/video2.mp4" | ||
- "path/to/video3.mp4" | ||
- start_date: xxxx-xx-02 # Every year on the 2nd of every month | ||
end_date: xxxx-xx-03 # Every year on the 3rd of every month | ||
paths: | ||
- "path/to/video1.mp4" | ||
- "path/to/video2.mp4" | ||
- "path/to/video3.mp4" | ||
- start_date: xxxx-xx-xx 08:00:00 # Every day at 8am | ||
end_date: xxxx-xx-xx 09:30:00 # Every day at 9:30am | ||
paths: | ||
- "path/to/video1.mp4" | ||
- "path/to/video2.mp4" | ||
- "path/to/video3.mp4" | ||
|
||
# Schedule prerolls by week of the year | ||
weekly: | ||
enabled: false | ||
weeks: | ||
- number: 1 # First week of the year | ||
paths: | ||
- "path/to/video1.mp4" | ||
- "path/to/video2.mp4" | ||
- "path/to/video3.mp4" | ||
weight: 1 # Optional, how much to emphasize these pre-rolls over others (higher = more likely to play) | ||
- number: 2 # Second week of the year | ||
paths: | ||
- "path/to/video1.mp4" | ||
- "path/to/video2.mp4" | ||
- "path/to/video3.mp4" | ||
|
||
# Schedule prerolls by month of the year | ||
monthly: | ||
enabled: false | ||
months: | ||
- number: 1 # January | ||
paths: | ||
- "path/to/video1.mp4" | ||
- "path/to/video2.mp4" | ||
- "path/to/video3.mp4" | ||
weight: 1 # Optional, how much to emphasize these pre-rolls over others (higher = more likely to play) | ||
- number: 2 # February | ||
paths: | ||
- "path/to/video1.mp4" | ||
- "path/to/video2.mp4" | ||
- "path/to/video3.mp4" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
APP_NAME = "Plex Prerolls" | ||
APP_DESCRIPTION = "A tool to manage prerolls for Plex" | ||
DEFAULT_CONFIG_PATH = "config.yaml" | ||
DEFAULT_LOG_DIR = "logs/" | ||
CONSOLE_LOG_LEVEL = "INFO" | ||
FILE_LOG_LEVEL = "DEBUG" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Empty file.
Oops, something went wrong.