Bug fix due to major bug in 0.0.11 where files where not properly marked for operation.

This commit is contained in:
Fabrice Quenneville 2024-04-24 05:38:00 -04:00
parent c56fc194af
commit 98da57cd26
17 changed files with 112 additions and 37 deletions

View File

@ -20,7 +20,7 @@
project = 'MediaCurator' project = 'MediaCurator'
copyright = '2020, Fabrice Quenneville' copyright = '2020, Fabrice Quenneville'
author = 'Fabrice Quenneville' author = 'Fabrice Quenneville'
version = '0.0.11' version = '0.0.12'
# -- General configuration --------------------------------------------------- # -- General configuration ---------------------------------------------------

View File

@ -30,6 +30,7 @@ The source code can be found on `GitHub <https://github.com/fabquenneville/Media
:maxdepth: 1 :maxdepth: 1
:caption: Release Notes: :caption: Release Notes:
releasenotes/0.0.12-changelog
releasenotes/0.0.11-changelog releasenotes/0.0.11-changelog
releasenotes/0.0.10-changelog releasenotes/0.0.10-changelog
releasenotes/0.0.9-changelog releasenotes/0.0.9-changelog

View File

@ -37,7 +37,7 @@ Mediacurator has been tested to work with FFMPEG versions ranging from 4.1.6 to
OS Support OS Support
---------- ----------
Mediacurator has been tested to work on various GNU/Linux distribution as well as Windows Mediacurator has been tested to work on various GNU/Linux distributions as well as Windows
New Features New Features
============ ============

View File

@ -10,14 +10,7 @@ Added support to mpeg filetype.
Dropped Support Dropped Support
=============== ===============
Future Changes Compatibility Notes
==============
* More filters
* Test AV1 Support
* Prepare API for GUI
Compatibility notes
=================== ===================
Python Support Python Support
@ -33,13 +26,11 @@ Mediacurator has been tested to work with FFMPEG versions ranging from 4.1.6 to
OS Support OS Support
---------- ----------
Mediacurator has been tested to work on various GNU/Linux distribution as well as Windows Mediacurator has been tested to work on various GNU/Linux distributions as well as Windows
New Features New Features
============ ============
Improvements Improvements
============ ============
@ -47,7 +38,12 @@ Improvements
Changes Changes
======= =======
Future Changes
==============
* More filters
* Test AV1 Support
* Prepare API for GUI
Deprecations Deprecations
============ ============

View File

@ -1,14 +1,14 @@
======================================== ========================================
MediaCurator 0.0.1 Release Notes MediaCurator 0.0.11 Release Notes
======================================== ========================================
Improvements Highlights
============ ==========
* Rectified a bug where MediaLibrary would encounter an error due to a missing directory. Code improvements.
* Enhanced clarity by refining comments.
* Improved code readability through cleanup and organization. Dropped Support
* Ensured consistency and enhanced readability by adjusting variable names. ===============
Compatibility Notes Compatibility Notes
==================== ====================
@ -34,8 +34,10 @@ New Features
Improvements Improvements
============ ============
* Added a changelog in .rst format. * Rectified a bug where MediaLibrary would encounter an error due to a missing directory.
* Added verbose output to the convert method in the Video class for better visibility during the conversion process. * Enhanced clarity by refining comments.
* Improved code readability through cleanup and organization.
* Ensured consistency and enhanced readability by adjusting variable names.
Changes Changes
======= =======

View File

@ -0,0 +1,50 @@
========================================
MediaCurator 0.0.11 Release Notes
========================================
Highlights
==========
Code improvements.
Dropped Support
===============
Compatibility Notes
====================
Python Support
--------------
MediaCurator has been tested on Python 3.7 - 3.9.7.
FFMPEG Support
--------------
MediaCurator has been tested to work with FFMPEG versions ranging from 4.1.6 to 4.4.1.
OS Support
----------
MediaCurator has been tested to work on various GNU/Linux distributions as well as Windows.
New Features
============
Improvements
============
* Rectified a bug where MediaLibrary would be unable to gather the videos to operate.
Changes
=======
Deprecations
============
Future Changes
==============
* More filters
* Test AV1 Support
* Prepare API for GUI

View File

@ -37,7 +37,7 @@ Mediacurator has been tested to work with FFMPEG versions ranging from 4.1.6 to
OS Support OS Support
---------- ----------
Mediacurator has been tested to work on various GNU/Linux distribution as well as Windows Mediacurator has been tested to work on various GNU/Linux distributions as well as Windows
New Features New Features
============ ============

View File

@ -38,7 +38,7 @@ Mediacurator has been tested to work with FFMPEG versions ranging from 4.1.6 to
OS Support OS Support
---------- ----------
Mediacurator has been tested to work on various GNU/Linux distribution as well as Windows Mediacurator has been tested to work on various GNU/Linux distributions as well as Windows
New Features New Features
============ ============

View File

@ -41,7 +41,7 @@ Mediacurator has been tested to work with FFMPEG versions ranging from 4.1.6 to
OS Support OS Support
---------- ----------
Mediacurator has been tested to work on various GNU/Linux distribution as well as Windows Mediacurator has been tested to work on various GNU/Linux distributions as well as Windows
New Features New Features
============ ============

View File

@ -37,7 +37,7 @@ Mediacurator has been tested to work with FFMPEG versions ranging from 4.1.6 to
OS Support OS Support
---------- ----------
Mediacurator has been tested to work on various GNU/Linux distribution as well as Windows Mediacurator has been tested to work on various GNU/Linux distributions as well as Windows
New Features New Features
============ ============

View File

@ -33,7 +33,7 @@ Mediacurator has been tested to work with FFMPEG versions ranging from 4.1.6 to
OS Support OS Support
---------- ----------
Mediacurator has been tested to work on various GNU/Linux distribution as well as Windows Mediacurator has been tested to work on various GNU/Linux distributions as well as Windows
New Features New Features
============ ============

View File

@ -33,7 +33,7 @@ Mediacurator has been tested to work with FFMPEG versions ranging from 4.1.6 to
OS Support OS Support
---------- ----------
Mediacurator has been tested to work on various GNU/Linux distribution as well as Windows Mediacurator has been tested to work on various GNU/Linux distributions as well as Windows
New Features New Features
============ ============

View File

@ -6,9 +6,11 @@ from pathlib import Path
from .video import Video from .video import Video
from .tools import deletefile from .tools import deletefile
# Import colorama for colored output
import colorama import colorama
colorama.init() colorama.init()
# Define color codes for colored output
cgreen = colorama.Fore.GREEN cgreen = colorama.Fore.GREEN
creset = colorama.Fore.RESET creset = colorama.Fore.RESET
@ -73,10 +75,33 @@ class MediaLibrary():
for directory in self.directories: for directory in self.directories:
path = Path(directory) path = Path(directory)
# Get all video filetypes # get all video filetypes
for ext in ["wmv", "avi", "mkv", "mp4", "m4v", "flv", "mpg", "mpeg", "vid", "vob", "divx", "ogm", "webm"]: if "wmv" in self.inputs or "any" in self.inputs or len(self.inputs) < 1:
if ext in self.inputs or "any" in self.inputs or len(self.inputs) < 1: videolist += list(path.rglob("*.[wW][mM][vV]"))
videolist += list(path.rglob(f"*.[{ext.upper()}{ext.lower()}]")) if "avi" in self.inputs or "any" in self.inputs or len(self.inputs) < 1:
videolist += list(path.rglob("*.[aA][vV][iI]"))
if "mkv" in self.inputs or "any" in self.inputs or len(self.inputs) < 1:
videolist += list(path.rglob("*.[mM][kK][vV]"))
if "mp4" in self.inputs or "any" in self.inputs or len(self.inputs) < 1:
videolist += list(path.rglob("*.[mM][pP]4"))
if "m4v" in self.inputs or "any" in self.inputs or len(self.inputs) < 1:
videolist += list(path.rglob("*.[mM]4[vV]"))
if "flv" in self.inputs or "any" in self.inputs or len(self.inputs) < 1:
videolist += list(path.rglob("*.[fF][lL][vV]"))
if "mpg" in self.inputs or "any" in self.inputs or len(self.inputs) < 1:
videolist += list(path.rglob("*.[mM][pP][gG]"))
if "mpeg" in self.inputs or "any" in self.inputs or len(self.inputs) < 1:
videolist += list(path.rglob("*.[mM][pP][eE][gG]"))
if "vid" in self.inputs or "any" in self.inputs or len(self.inputs) < 1:
videolist += list(path.rglob("*.[vV][iI][dD]"))
if "vob" in self.inputs or "any" in self.inputs or len(self.inputs) < 1:
videolist += list(path.rglob("*.[vV][oO][bB]"))
if "divx" in self.inputs or "any" in self.inputs or len(self.inputs) < 1:
videolist += list(path.rglob("*.[dD][iI][vV][xX]"))
if "ogm" in self.inputs or "any" in self.inputs or len(self.inputs) < 1:
videolist += list(path.rglob("*.[oO][gG][mM]"))
if "webm" in self.inputs or "any" in self.inputs or len(self.inputs) < 1:
videolist += list(path.rglob("*.[wW][eE][bB][mM]"))
# Remove folders # Remove folders
videolist_tmp = videolist videolist_tmp = videolist

View File

@ -7,9 +7,11 @@ import subprocess
import os import os
import sys import sys
# Import colorama for colored output
import colorama import colorama
colorama.init() colorama.init()
# Define color codes for colored output
cgreen = colorama.Fore.GREEN cgreen = colorama.Fore.GREEN
cyellow = colorama.Fore.YELLOW cyellow = colorama.Fore.YELLOW
cred = colorama.Fore.RED cred = colorama.Fore.RED

View File

@ -5,9 +5,11 @@ from .tools import deletefile, findfreename
import subprocess import subprocess
import os import os
# Import colorama for colored output
import colorama import colorama
colorama.init() colorama.init()
# Define color codes for colored output
cyellow = colorama.Fore.YELLOW cyellow = colorama.Fore.YELLOW
cred = colorama.Fore.RED cred = colorama.Fore.RED
creset = colorama.Fore.RESET creset = colorama.Fore.RESET

View File

@ -37,8 +37,6 @@ def main():
''' '''
MediaCurator's main function MediaCurator's main function
Args:
Returns: Returns:
''' '''
@ -67,7 +65,6 @@ def main():
print(f"{cred}ERROR: No files or directories selected.{creset}") print(f"{cred}ERROR: No files or directories selected.{creset}")
return return
# Actions # Actions
if sys.argv[1] == "list": if sys.argv[1] == "list":
# Pulling list of marked videos / original keys for the medialibrary.videos dictionary # Pulling list of marked videos / original keys for the medialibrary.videos dictionary

View File

@ -7,7 +7,7 @@ with open("README.md", "r", encoding="utf-8") as fh:
setuptools.setup( setuptools.setup(
name="MediaCurator", name="MediaCurator",
version="0.0.11", version="0.0.12",
author="Fabrice Quenneville", author="Fabrice Quenneville",
author_email="fab@fabq.ca", author_email="fab@fabq.ca",
url="https://github.com/fabquenneville/MediaCurator", url="https://github.com/fabquenneville/MediaCurator",