diff --git a/README.md b/README.md
index 9f337b3..0381241 100644
--- a/README.md
+++ b/README.md
@@ -1,3 +1,6 @@
+
+
+
@@ -6,23 +9,23 @@
-
-
+
+
-
-
+
+
-
+
-
-
+
+
@@ -55,13 +58,13 @@
# Installation
-
+
-
+
-
+
@@ -551,7 +554,7 @@ python3 telegram_bot.py
# To Do
-- Finish [website API](https://github.com/Abc-dc/StreamingCommunity/tree/test_gui_1)
+- Finish [website API](https://github.com/Arrowar/StreamingCommunity/tree/test_gui_1)
# Contributing
@@ -569,6 +572,6 @@ This software is provided "as is", without warranty of any kind, express or impl
## Contributors
-
-
+
+
diff --git a/StreamingCommunity/Lib/Downloader/HLS/downloader.py b/StreamingCommunity/Lib/Downloader/HLS/downloader.py
index 2ee4b4e..4fbb583 100644
--- a/StreamingCommunity/Lib/Downloader/HLS/downloader.py
+++ b/StreamingCommunity/Lib/Downloader/HLS/downloader.py
@@ -36,11 +36,13 @@ from .segments import M3U8_Segments
# Config
+ENABLE_AUDIO = config_manager.get_bool('M3U8_DOWNLOAD', 'download_audio')
+ENABLE_SUBTITLE = config_manager.get_bool('M3U8_DOWNLOAD', 'download_subtitle')
DOWNLOAD_SPECIFIC_AUDIO = config_manager.get_list('M3U8_DOWNLOAD', 'specific_list_audio')
DOWNLOAD_SPECIFIC_SUBTITLE = config_manager.get_list('M3U8_DOWNLOAD', 'specific_list_subtitles')
MERGE_AUDIO = config_manager.get_bool('M3U8_DOWNLOAD', 'merge_audio')
MERGE_SUBTITLE = config_manager.get_bool('M3U8_DOWNLOAD', 'merge_subs')
-REMOVE_SEGMENTS_FOLDER = config_manager.get_bool('M3U8_DOWNLOAD', 'cleanup_tmp_folder')
+CLEANUP_TMP = config_manager.get_bool('M3U8_DOWNLOAD', 'cleanup_tmp_folder')
FILTER_CUSTOM_REOLUTION = config_manager.get_int('M3U8_PARSER', 'force_resolution')
GET_ONLY_LINK = config_manager.get_bool('M3U8_PARSER', 'get_only_link')
RETRY_LIMIT = config_manager.get_int('REQUESTS', 'max_retry')
@@ -121,7 +123,7 @@ class PathManager:
def cleanup(self):
"""Removes temporary directories if configured to do so."""
- if REMOVE_SEGMENTS_FOLDER:
+ if CLEANUP_TMP:
os_manager.remove_folder(self.temp_dir)
@@ -157,32 +159,33 @@ class M3U8Manager:
If it's a master playlist, only selects video stream.
"""
if not self.is_master:
- # For master playlist, only get the video stream
if FILTER_CUSTOM_REOLUTION != -1:
self.video_url, self.video_res = self.parser._video.get_custom_uri(y_resolution=FILTER_CUSTOM_REOLUTION)
else:
self.video_url, self.video_res = self.parser._video.get_best_uri()
- # Don't process audio or subtitles for master playlist
self.audio_streams = []
self.sub_streams = []
else:
- # For media playlist, process all streams as before
if FILTER_CUSTOM_REOLUTION != -1:
self.video_url, self.video_res = self.parser._video.get_custom_uri(y_resolution=FILTER_CUSTOM_REOLUTION)
else:
self.video_url, self.video_res = self.parser._video.get_best_uri()
- self.audio_streams = [
- s for s in (self.parser._audio.get_all_uris_and_names() or [])
- if s.get('language') in DOWNLOAD_SPECIFIC_AUDIO
- ]
+ self.audio_streams = []
+ if ENABLE_AUDIO:
+ self.audio_streams = [
+ s for s in (self.parser._audio.get_all_uris_and_names() or [])
+ if s.get('language') in DOWNLOAD_SPECIFIC_AUDIO
+ ]
- self.sub_streams = [
- s for s in (self.parser._subtitle.get_all_uris_and_names() or [])
- if s.get('language') in DOWNLOAD_SPECIFIC_SUBTITLE
- ]
+ self.sub_streams = []
+ if ENABLE_SUBTITLE:
+ self.sub_streams = [
+ s for s in (self.parser._subtitle.get_all_uris_and_names() or [])
+ if s.get('language') in DOWNLOAD_SPECIFIC_SUBTITLE
+ ]
def log_selection(self):
if FILTER_CUSTOM_REOLUTION == -1:
diff --git a/StreamingCommunity/Upload/update.py b/StreamingCommunity/Upload/update.py
index d6617a9..39fd94b 100644
--- a/StreamingCommunity/Upload/update.py
+++ b/StreamingCommunity/Upload/update.py
@@ -25,9 +25,6 @@ def update():
"""
Check for updates on GitHub and display relevant information.
"""
- console.print("\n[cyan]→ [green]Checking GitHub version ...")
-
- # Make the GitHub API requests and handle potential errors
try:
response_reposity = httpx.get(f"https://api.github.com/repos/{__author__}/{__title__}").json()
response_releases = httpx.get(f"https://api.github.com/repos/{__author__}/{__title__}/releases").json()
@@ -56,11 +53,9 @@ def update():
# Check installed version
if str(__version__).replace('v', '') != str(last_version).replace('v', '') :
- console.print(f"[red]New version available: [yellow]{last_version} \n")
- else:
- console.print(f" [red]Everything is up to date \n")
+ console.print(f"\n[red]New version available: [yellow]{last_version}")
- console.print(f"[red]{__title__} has been downloaded [yellow]{total_download_count} [red]times, but only [yellow]{percentual_stars}% [red]of users have starred it.\n\
+ console.print(f"\n[red]{__title__} has been downloaded [yellow]{total_download_count} [red]times, but only [yellow]{percentual_stars}% [red]of users have starred it.\n\
[cyan]Help the repository grow today by leaving a [yellow]star [cyan]and [yellow]sharing [cyan]it with others online!")
time.sleep(3)
diff --git a/StreamingCommunity/Upload/version.py b/StreamingCommunity/Upload/version.py
index 36ad52c..01ccbe0 100644
--- a/StreamingCommunity/Upload/version.py
+++ b/StreamingCommunity/Upload/version.py
@@ -1,5 +1,5 @@
__title__ = 'StreamingCommunity'
__version__ = '2.5.0'
-__author__ = 'Abc-dc'
+__author__ = 'Arrowar'
__description__ = 'A command-line program to download film'
__copyright__ = 'Copyright 2024'
diff --git a/StreamingCommunity/Util/_jsonConfig.py b/StreamingCommunity/Util/_jsonConfig.py
index 79716c8..7c92dbd 100644
--- a/StreamingCommunity/Util/_jsonConfig.py
+++ b/StreamingCommunity/Util/_jsonConfig.py
@@ -34,7 +34,7 @@ class ConfigManager:
else:
logging.info("Configuration file does not exist. Downloading...")
self.download_requirements(
- 'https://raw.githubusercontent.com/Abc-dc/StreamingCommunity/refs/heads/main/config.json',
+ 'https://raw.githubusercontent.com/Arrowar/StreamingCommunity/refs/heads/main/config.json',
self.file_path
)
diff --git a/StreamingCommunity/Util/os.py b/StreamingCommunity/Util/os.py
index c849fbf..fb8479c 100644
--- a/StreamingCommunity/Util/os.py
+++ b/StreamingCommunity/Util/os.py
@@ -476,7 +476,7 @@ class OsSummary:
if not os.path.exists(requirements_file):
self.download_requirements(
- 'https://raw.githubusercontent.com/Abc-dc/StreamingCommunity/refs/heads/main/requirements.txt',
+ 'https://raw.githubusercontent.com/Arrowar/StreamingCommunity/refs/heads/main/requirements.txt',
requirements_file
)
diff --git a/config.json b/config.json
index 5b555ba..98c88a8 100644
--- a/config.json
+++ b/config.json
@@ -28,13 +28,15 @@
"proxy_start_max": 0.5
},
"M3U8_DOWNLOAD": {
- "tqdm_delay": 0.12,
+ "tqdm_delay": 0.05,
"default_video_workser": 12,
"default_audio_workser": 12,
+ "download_audio": true,
"merge_audio": true,
"specific_list_audio": [
"ita"
],
+ "download_subtitle": true,
"merge_subs": true,
"specific_list_subtitles": [
"eng",