From bd0c4aaf7101512bae4a94703afb4c146db252de Mon Sep 17 00:00:00 2001 From: eliforp <18079714+leptoid@users.noreply.github.com> Date: Wed, 25 Apr 2018 16:17:05 -0500 Subject: [PATCH 1/2] Update __init__.py --- anime_dl/sites/__init__.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/anime_dl/sites/__init__.py b/anime_dl/sites/__init__.py index 3d914b1..fb785d5 100644 --- a/anime_dl/sites/__init__.py +++ b/anime_dl/sites/__init__.py @@ -1,3 +1,3 @@ -import crunchyroll -import funimation -import vrv \ No newline at end of file +import sites.crunchyroll +import sites.funimation +import sites.vrv From 9ce2d267605354ecbb462b43a72526da0e5cf224 Mon Sep 17 00:00:00 2001 From: eliforp <18079714+leptoid@users.noreply.github.com> Date: Fri, 12 Oct 2018 21:24:25 -0400 Subject: [PATCH 2/2] Update animeName.py to solve Issue #67 This is a modification to solve Feature Request / Issue #67 Added .zfill(2) to episodenumber variable. This change affixes a "0" before any single digit integer to solve a problem with Plex detecting episodes and playlists incorrectly ordering episodes with an integer [1-99]. --- anime_dl/animeName.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/anime_dl/animeName.py b/anime_dl/animeName.py index ae85f01..def5bb4 100644 --- a/anime_dl/animeName.py +++ b/anime_dl/animeName.py @@ -11,7 +11,7 @@ def nameEdit(self, animeName, episodeNumber, resolution): rawName = str(animeName).title().strip().replace("Season ", "S") + " - " +\ str(episodeNumber).strip() + " [" + str(resolution) + "]" file_name = str(re.sub(r'[^A-Za-z0-9\ \-\' \\]+', '', str(animeName))).title().strip().replace("Season ", "S")\ - + " - " + str(episodeNumber).strip() + " [" + str(resolution) + "].mp4" + + " - " + str(episodeNumber.zfill(2)).strip() + " [" + str(resolution) + "].mp4" try: max_path = int(subprocess.check_output(['getconf', 'PATH_MAX', '/'])) @@ -30,7 +30,7 @@ def nameEditFuni(self, animeName, seasonNumber, episodeNumber, resolution): str(episodeNumber).strip())\ + " [" + str(resolution) + "]" file_name = str(re.sub(r'[^A-Za-z0-9\ \-\' \\]+', '', str(animeName))).title().strip().replace("Season ", "S") \ - + " - " + str(episodeNumber).strip() + " [" + str(resolution) + "].mp4" + + " - " + str(episodeNumber.zfill(2)).strip() + " [" + str(resolution) + "].mp4" try: max_path = int(subprocess.check_output(['getconf', 'PATH_MAX', '/'])) @@ -41,4 +41,4 @@ def nameEditFuni(self, animeName, seasonNumber, episodeNumber, resolution): if len(file_name) > max_path: file_name = file_name[:max_path] - return file_name \ No newline at end of file + return file_name