youtube-lecture-manager 2.3.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- youtube_lecture_manager-2.3.0/LICENSE +6 -0
- youtube_lecture_manager-2.3.0/PKG-INFO +57 -0
- youtube_lecture_manager-2.3.0/README.md +20 -0
- youtube_lecture_manager-2.3.0/lecture_manager/__init__.py +9 -0
- youtube_lecture_manager-2.3.0/lecture_manager/config.py +85 -0
- youtube_lecture_manager-2.3.0/lecture_manager/crud.py +1062 -0
- youtube_lecture_manager-2.3.0/lecture_manager/dashboard.py +218 -0
- youtube_lecture_manager-2.3.0/lecture_manager/db.py +246 -0
- youtube_lecture_manager-2.3.0/lecture_manager/export.py +308 -0
- youtube_lecture_manager-2.3.0/lecture_manager/facebook.py +376 -0
- youtube_lecture_manager-2.3.0/lecture_manager/facebook_manager.py +722 -0
- youtube_lecture_manager-2.3.0/lecture_manager/file_compressor.py +232 -0
- youtube_lecture_manager-2.3.0/lecture_manager/file_manager.py +2411 -0
- youtube_lecture_manager-2.3.0/lecture_manager/file_sharing.py +199 -0
- youtube_lecture_manager-2.3.0/lecture_manager/main.py +162 -0
- youtube_lecture_manager-2.3.0/lecture_manager/utils.py +217 -0
- youtube_lecture_manager-2.3.0/lecture_manager/web.py +438 -0
- youtube_lecture_manager-2.3.0/lecture_manager/youtube.py +172 -0
- youtube_lecture_manager-2.3.0/setup.cfg +4 -0
- youtube_lecture_manager-2.3.0/setup.py +75 -0
- youtube_lecture_manager-2.3.0/youtube_lecture_manager.egg-info/PKG-INFO +57 -0
- youtube_lecture_manager-2.3.0/youtube_lecture_manager.egg-info/SOURCES.txt +24 -0
- youtube_lecture_manager-2.3.0/youtube_lecture_manager.egg-info/dependency_links.txt +1 -0
- youtube_lecture_manager-2.3.0/youtube_lecture_manager.egg-info/entry_points.txt +2 -0
- youtube_lecture_manager-2.3.0/youtube_lecture_manager.egg-info/requires.txt +13 -0
- youtube_lecture_manager-2.3.0/youtube_lecture_manager.egg-info/top_level.txt +1 -0
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: youtube-lecture-manager
|
|
3
|
+
Version: 2.3.0
|
|
4
|
+
Summary: Organise and manage YouTube lecture libraries with a terminal interface, web UI, and local playback
|
|
5
|
+
Home-page: https://github.com/yourusername/lecture-manager
|
|
6
|
+
Author: Udaya Raj Joshi
|
|
7
|
+
Author-email: udayarajjoshi@gmail.com
|
|
8
|
+
Classifier: Programming Language :: Python :: 3
|
|
9
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
10
|
+
Classifier: Operating System :: POSIX :: Linux
|
|
11
|
+
Requires-Python: >=3.6
|
|
12
|
+
Description-Content-Type: text/markdown
|
|
13
|
+
License-File: LICENSE
|
|
14
|
+
Requires-Dist: mysql-connector-python>=8.0.0
|
|
15
|
+
Requires-Dist: yt-dlp>=2023.0.0
|
|
16
|
+
Requires-Dist: flask>=2.0.0
|
|
17
|
+
Requires-Dist: browser-cookie3
|
|
18
|
+
Requires-Dist: bgutil-ytdlp-pot-provider
|
|
19
|
+
Requires-Dist: requests>=2.25.0
|
|
20
|
+
Requires-Dist: gallery-dl>=1.20.0
|
|
21
|
+
Requires-Dist: ffmpeg-python>=0.2.0
|
|
22
|
+
Provides-Extra: dev
|
|
23
|
+
Requires-Dist: pytest; extra == "dev"
|
|
24
|
+
Requires-Dist: black; extra == "dev"
|
|
25
|
+
Requires-Dist: flake8; extra == "dev"
|
|
26
|
+
Dynamic: author
|
|
27
|
+
Dynamic: author-email
|
|
28
|
+
Dynamic: classifier
|
|
29
|
+
Dynamic: description
|
|
30
|
+
Dynamic: description-content-type
|
|
31
|
+
Dynamic: home-page
|
|
32
|
+
Dynamic: license-file
|
|
33
|
+
Dynamic: provides-extra
|
|
34
|
+
Dynamic: requires-dist
|
|
35
|
+
Dynamic: requires-python
|
|
36
|
+
Dynamic: summary
|
|
37
|
+
|
|
38
|
+
# YouTube Lecture Manager
|
|
39
|
+
|
|
40
|
+
Manage your YouTube lectures with a terminal interface, web UI, and local playback.
|
|
41
|
+
|
|
42
|
+
## Features
|
|
43
|
+
|
|
44
|
+
- Add lectures via YouTube URL
|
|
45
|
+
- Auto‑detect title, lecturer, date, time
|
|
46
|
+
- Organise files into a structured folder tree
|
|
47
|
+
- Facebook video/photo support
|
|
48
|
+
- Web interface with dashboard
|
|
49
|
+
- Export/Import CSV & JSON
|
|
50
|
+
- File compression, sharing, and trash management
|
|
51
|
+
|
|
52
|
+
## Installation
|
|
53
|
+
|
|
54
|
+
```bash
|
|
55
|
+
git clone https://github.com/yourusername/lecture-manager.git
|
|
56
|
+
cd lecture-manager
|
|
57
|
+
pip install -e .
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# YouTube Lecture Manager
|
|
2
|
+
|
|
3
|
+
Manage your YouTube lectures with a terminal interface, web UI, and local playback.
|
|
4
|
+
|
|
5
|
+
## Features
|
|
6
|
+
|
|
7
|
+
- Add lectures via YouTube URL
|
|
8
|
+
- Auto‑detect title, lecturer, date, time
|
|
9
|
+
- Organise files into a structured folder tree
|
|
10
|
+
- Facebook video/photo support
|
|
11
|
+
- Web interface with dashboard
|
|
12
|
+
- Export/Import CSV & JSON
|
|
13
|
+
- File compression, sharing, and trash management
|
|
14
|
+
|
|
15
|
+
## Installation
|
|
16
|
+
|
|
17
|
+
```bash
|
|
18
|
+
git clone https://github.com/yourusername/lecture-manager.git
|
|
19
|
+
cd lecture-manager
|
|
20
|
+
pip install -e .
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
# File config.py
|
|
2
|
+
|
|
3
|
+
import os
|
|
4
|
+
import json
|
|
5
|
+
from .utils import color_text, print_colored, COLORS
|
|
6
|
+
|
|
7
|
+
CONFIG_FILE = os.path.expanduser("~/.lecture_manager_config.json")
|
|
8
|
+
db_config = None
|
|
9
|
+
|
|
10
|
+
def load_or_create_config():
|
|
11
|
+
global db_config
|
|
12
|
+
if os.path.exists(CONFIG_FILE):
|
|
13
|
+
try:
|
|
14
|
+
with open(CONFIG_FILE, 'r') as f:
|
|
15
|
+
db_config = json.load(f)
|
|
16
|
+
print_colored("[✓] Loaded database configuration.", COLORS.GREEN)
|
|
17
|
+
return
|
|
18
|
+
except Exception as e:
|
|
19
|
+
print_colored(f"[!] Error reading config: {e}. Will create new one.", COLORS.YELLOW)
|
|
20
|
+
|
|
21
|
+
print("\n" + "═" * 50)
|
|
22
|
+
print_colored(" DATABASE CONFIGURATION", COLORS.CYAN, bold=True)
|
|
23
|
+
print("═" * 50)
|
|
24
|
+
print("Please enter your MariaDB/MySQL connection details.")
|
|
25
|
+
host = input(color_text("Host (default: localhost): ", COLORS.MAGENTA)).strip() or "localhost"
|
|
26
|
+
database = input(color_text("Database name: ", COLORS.MAGENTA)).strip()
|
|
27
|
+
user = input(color_text("Username: ", COLORS.MAGENTA)).strip()
|
|
28
|
+
password = input(color_text("Password: ", COLORS.MAGENTA)).strip()
|
|
29
|
+
port = input(color_text("Port (default: 3306): ", COLORS.MAGENTA)).strip() or "3306"
|
|
30
|
+
|
|
31
|
+
if not database or not user:
|
|
32
|
+
print_colored("[!] Database name and username are required.", COLORS.RED)
|
|
33
|
+
exit(1)
|
|
34
|
+
|
|
35
|
+
db_config = {
|
|
36
|
+
'host': host,
|
|
37
|
+
'database': database,
|
|
38
|
+
'user': user,
|
|
39
|
+
'password': password,
|
|
40
|
+
'port': int(port)
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
try:
|
|
44
|
+
with open(CONFIG_FILE, 'w') as f:
|
|
45
|
+
json.dump(db_config, f, indent=2)
|
|
46
|
+
print_colored(f"[✓] Configuration saved to {CONFIG_FILE}", COLORS.GREEN)
|
|
47
|
+
except Exception as e:
|
|
48
|
+
print_colored(f"[!] Failed to save config: {e}", COLORS.RED)
|
|
49
|
+
|
|
50
|
+
def edit_config():
|
|
51
|
+
global db_config
|
|
52
|
+
print("\n" + "═" * 50)
|
|
53
|
+
print_colored(" EDIT DATABASE CONFIGURATION", COLORS.CYAN, bold=True)
|
|
54
|
+
print("═" * 50)
|
|
55
|
+
print("Current settings:")
|
|
56
|
+
print(f" Host : {db_config.get('host', '')}")
|
|
57
|
+
print(f" Database : {db_config.get('database', '')}")
|
|
58
|
+
print(f" User : {db_config.get('user', '')}")
|
|
59
|
+
print(f" Port : {db_config.get('port', 3306)}")
|
|
60
|
+
print("(Leave blank to keep current value)")
|
|
61
|
+
|
|
62
|
+
host = input(color_text(f"Host [{db_config.get('host', 'localhost')}]: ", COLORS.MAGENTA)).strip() or db_config.get('host', 'localhost')
|
|
63
|
+
database = input(color_text(f"Database [{db_config.get('database', '')}]: ", COLORS.MAGENTA)).strip() or db_config.get('database', '')
|
|
64
|
+
user = input(color_text(f"Username [{db_config.get('user', '')}]: ", COLORS.MAGENTA)).strip() or db_config.get('user', '')
|
|
65
|
+
password = input(color_text(f"Password [{db_config.get('password', '')}]: ", COLORS.MAGENTA)).strip() or db_config.get('password', '')
|
|
66
|
+
port = input(color_text(f"Port [{db_config.get('port', 3306)}]: ", COLORS.MAGENTA)).strip() or db_config.get('port', 3306)
|
|
67
|
+
|
|
68
|
+
if not database or not user:
|
|
69
|
+
print_colored("[!] Database name and username are required. Aborting.", COLORS.RED)
|
|
70
|
+
return
|
|
71
|
+
|
|
72
|
+
new_config = {
|
|
73
|
+
'host': host,
|
|
74
|
+
'database': database,
|
|
75
|
+
'user': user,
|
|
76
|
+
'password': password,
|
|
77
|
+
'port': int(port)
|
|
78
|
+
}
|
|
79
|
+
try:
|
|
80
|
+
with open(CONFIG_FILE, 'w') as f:
|
|
81
|
+
json.dump(new_config, f, indent=2)
|
|
82
|
+
db_config = new_config
|
|
83
|
+
print_colored("[✓] Configuration updated and saved.", COLORS.GREEN)
|
|
84
|
+
except Exception as e:
|
|
85
|
+
print_colored(f"[!] Failed to save config: {e}", COLORS.RED)
|