KekikStream 0.3.5__py3-none-any.whl → 0.3.6__py3-none-any.whl
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.
- KekikStream/__init__.py +67 -69
- {KekikStream-0.3.5.dist-info → KekikStream-0.3.6.dist-info}/METADATA +1 -1
- {KekikStream-0.3.5.dist-info → KekikStream-0.3.6.dist-info}/RECORD +7 -7
- {KekikStream-0.3.5.dist-info → KekikStream-0.3.6.dist-info}/LICENSE +0 -0
- {KekikStream-0.3.5.dist-info → KekikStream-0.3.6.dist-info}/WHEEL +0 -0
- {KekikStream-0.3.5.dist-info → KekikStream-0.3.6.dist-info}/entry_points.txt +0 -0
- {KekikStream-0.3.5.dist-info → KekikStream-0.3.6.dist-info}/top_level.txt +0 -0
KekikStream/__init__.py
CHANGED
@@ -13,19 +13,18 @@ class KekikStream:
|
|
13
13
|
self.medya_yonetici = MediaManager()
|
14
14
|
self.suanki_eklenti: PluginBase = None
|
15
15
|
|
16
|
-
async def
|
16
|
+
async def baslat(self):
|
17
17
|
self.arayuz_yonetici.clear_console()
|
18
18
|
konsol.rule("[bold cyan]KekikStream Başlatılıyor[/bold cyan]")
|
19
19
|
if not self.eklentiler_yonetici.get_plugin_names():
|
20
|
-
konsol.print("[bold red]Hiçbir eklenti bulunamadı![/bold red]")
|
21
|
-
return
|
20
|
+
return konsol.print("[bold red]Hiçbir eklenti bulunamadı![/bold red]")
|
22
21
|
|
23
22
|
try:
|
24
|
-
await self.
|
23
|
+
await self.eklenti_secimi()
|
25
24
|
finally:
|
26
25
|
await self.eklentiler_yonetici.close_plugins()
|
27
26
|
|
28
|
-
async def
|
27
|
+
async def sonuc_bulunamadi(self):
|
29
28
|
secim = await self.arayuz_yonetici.select_from_list(
|
30
29
|
message = "Ne yapmak istersiniz?",
|
31
30
|
choices = ["Tüm Eklentilerde Ara", "Ana Menü", "Çıkış"]
|
@@ -33,25 +32,25 @@ class KekikStream:
|
|
33
32
|
|
34
33
|
match secim:
|
35
34
|
case "Tüm Eklentilerde Ara":
|
36
|
-
await self.
|
35
|
+
await self.tum_eklentilerde_arama()
|
37
36
|
case "Ana Menü":
|
38
|
-
await self.
|
37
|
+
await self.baslat()
|
39
38
|
case "Çıkış":
|
40
39
|
cikis_yap(False)
|
41
40
|
|
42
|
-
async def
|
41
|
+
async def eklenti_secimi(self):
|
43
42
|
eklenti_adi = await self.arayuz_yonetici.select_from_fuzzy(
|
44
43
|
message = "Arama yapılacak eklentiyi seçin:",
|
45
44
|
choices = ["Tüm Eklentilerde Ara", *self.eklentiler_yonetici.get_plugin_names()]
|
46
45
|
)
|
47
46
|
|
48
47
|
if eklenti_adi == "Tüm Eklentilerde Ara":
|
49
|
-
await self.
|
48
|
+
await self.tum_eklentilerde_arama()
|
50
49
|
else:
|
51
50
|
self.suanki_eklenti = self.eklentiler_yonetici.select_plugin(eklenti_adi)
|
52
|
-
await self.
|
51
|
+
await self.eklenti_ile_arama()
|
53
52
|
|
54
|
-
async def
|
53
|
+
async def eklenti_ile_arama(self):
|
55
54
|
self.arayuz_yonetici.clear_console()
|
56
55
|
konsol.rule(f"[bold cyan]{self.suanki_eklenti.name} Eklentisinde Arama Yapın[/bold cyan]")
|
57
56
|
|
@@ -60,33 +59,69 @@ class KekikStream:
|
|
60
59
|
|
61
60
|
if not sonuclar:
|
62
61
|
konsol.print("[bold red]Arama sonucu bulunamadı![/bold red]")
|
63
|
-
return await self.
|
62
|
+
return await self.sonuc_bulunamadi()
|
64
63
|
|
65
|
-
if secilen_sonuc:= await self.
|
66
|
-
await self.
|
64
|
+
if secilen_sonuc := await self.sonuc_secimi(sonuclar):
|
65
|
+
await self.sonuc_detaylari_goster({"plugin": self.suanki_eklenti.name, "url": secilen_sonuc})
|
67
66
|
|
68
|
-
async def
|
67
|
+
async def tum_eklentilerde_arama(self):
|
69
68
|
self.arayuz_yonetici.clear_console()
|
70
69
|
konsol.rule("[bold cyan]Tüm Eklentilerde Arama Yapın[/bold cyan]")
|
71
70
|
|
72
71
|
sorgu = await self.arayuz_yonetici.prompt_text("Arama sorgusu girin:")
|
73
|
-
sonuclar = await self.
|
72
|
+
sonuclar = await self.tum_eklentilerde_arama_sorgula(sorgu)
|
74
73
|
|
75
74
|
if not sonuclar:
|
76
|
-
return await self.
|
75
|
+
return await self.sonuc_bulunamadi()
|
77
76
|
|
78
|
-
secilen_sonuc = await self.
|
77
|
+
secilen_sonuc = await self.tum_sonuc_secimi(sonuclar)
|
79
78
|
|
80
79
|
if secilen_sonuc:
|
81
|
-
await self.
|
80
|
+
await self.sonuc_detaylari_goster(secilen_sonuc)
|
82
81
|
|
83
|
-
async def
|
82
|
+
async def sonuc_secimi(self, sonuclar):
|
84
83
|
return await self.arayuz_yonetici.select_from_fuzzy(
|
85
|
-
message = "İçerik
|
84
|
+
message = "İçerik sonuçlarından birini seçin:",
|
86
85
|
choices = [{"name": sonuc.title, "value": sonuc.url} for sonuc in sonuclar]
|
87
86
|
)
|
88
87
|
|
89
|
-
async def
|
88
|
+
async def tum_eklentilerde_arama_sorgula(self, sorgu: str):
|
89
|
+
tum_sonuclar = []
|
90
|
+
|
91
|
+
for eklenti_adi, eklenti in self.eklentiler_yonetici.plugins.items():
|
92
|
+
if not isinstance(eklenti, PluginBase):
|
93
|
+
konsol.print(f"[yellow][!] {eklenti_adi} geçerli bir PluginBase değil, atlanıyor...[/yellow]")
|
94
|
+
continue
|
95
|
+
|
96
|
+
konsol.log(f"[yellow][~] {eklenti_adi:<19} aranıyor...[/]")
|
97
|
+
try:
|
98
|
+
sonuclar = await eklenti.search(sorgu)
|
99
|
+
if sonuclar:
|
100
|
+
tum_sonuclar.extend(
|
101
|
+
[{"plugin": eklenti_adi, "title": sonuc.title, "url": sonuc.url, "poster": sonuc.poster} for sonuc in sonuclar]
|
102
|
+
)
|
103
|
+
except Exception as hata:
|
104
|
+
konsol.print(f"[bold red]{eklenti_adi} » hata oluştu: {hata}[/bold red]")
|
105
|
+
|
106
|
+
if not tum_sonuclar:
|
107
|
+
konsol.print("[bold red]Hiçbir sonuç bulunamadı![/bold red]")
|
108
|
+
await self.sonuc_bulunamadi()
|
109
|
+
return []
|
110
|
+
|
111
|
+
return tum_sonuclar
|
112
|
+
|
113
|
+
async def tum_sonuc_secimi(self, sonuclar):
|
114
|
+
secenekler = [
|
115
|
+
{"name": f"{f'[{sonuc["plugin"]}]':<21} » {sonuc['title']}", "value": sonuc}
|
116
|
+
for sonuc in sonuclar
|
117
|
+
]
|
118
|
+
|
119
|
+
return await self.arayuz_yonetici.select_from_fuzzy(
|
120
|
+
message = "Arama sonuçlarından bir içerik seçin:",
|
121
|
+
choices = secenekler
|
122
|
+
)
|
123
|
+
|
124
|
+
async def sonuc_detaylari_goster(self, secilen_sonuc):
|
90
125
|
try:
|
91
126
|
if isinstance(secilen_sonuc, dict) and "plugin" in secilen_sonuc:
|
92
127
|
eklenti_adi = secilen_sonuc["plugin"]
|
@@ -99,8 +134,7 @@ class KekikStream:
|
|
99
134
|
medya_bilgi = await self.suanki_eklenti.load_item(url)
|
100
135
|
except Exception as hata:
|
101
136
|
konsol.log(secilen_sonuc)
|
102
|
-
hata_yakala(hata)
|
103
|
-
return
|
137
|
+
return hata_yakala(hata)
|
104
138
|
|
105
139
|
self.medya_yonetici.set_title(f"{self.suanki_eklenti.name} | {medya_bilgi.title}")
|
106
140
|
self.arayuz_yonetici.display_media_info(f"{self.suanki_eklenti.name} | {medya_bilgi.title}", medya_bilgi)
|
@@ -115,15 +149,15 @@ class KekikStream:
|
|
115
149
|
)
|
116
150
|
if secilen_bolum:
|
117
151
|
baglantilar = await self.suanki_eklenti.load_links(secilen_bolum)
|
118
|
-
await self.
|
152
|
+
await self.baglanti_secenekleri_goster(baglantilar)
|
119
153
|
else:
|
120
154
|
baglantilar = await self.suanki_eklenti.load_links(medya_bilgi.url)
|
121
|
-
await self.
|
155
|
+
await self.baglanti_secenekleri_goster(baglantilar)
|
122
156
|
|
123
|
-
async def
|
157
|
+
async def baglanti_secenekleri_goster(self, baglantilar):
|
124
158
|
if not baglantilar:
|
125
159
|
konsol.print("[bold red]Hiçbir bağlantı bulunamadı![/bold red]")
|
126
|
-
return await self.
|
160
|
+
return await self.sonuc_bulunamadi()
|
127
161
|
|
128
162
|
haritalama = self.cikaricilar_yonetici.map_links_to_extractors(baglantilar)
|
129
163
|
play_fonksiyonu_var = hasattr(self.suanki_eklenti, "play") and callable(getattr(self.suanki_eklenti, "play", None))
|
@@ -132,7 +166,7 @@ class KekikStream:
|
|
132
166
|
if not haritalama and not play_fonksiyonu_var:
|
133
167
|
konsol.print("[bold red]Hiçbir Extractor bulunamadı![/bold red]")
|
134
168
|
konsol.print(baglantilar)
|
135
|
-
return await self.
|
169
|
+
return await self.sonuc_bulunamadi()
|
136
170
|
|
137
171
|
if not haritalama:
|
138
172
|
secilen_link = await self.arayuz_yonetici.select_from_list(
|
@@ -158,10 +192,10 @@ class KekikStream:
|
|
158
192
|
await self.medya_oynat(secilen_link)
|
159
193
|
|
160
194
|
case "Tüm Eklentilerde Ara":
|
161
|
-
await self.
|
195
|
+
await self.tum_eklentilerde_arama()
|
162
196
|
|
163
197
|
case _:
|
164
|
-
await self.
|
198
|
+
await self.baslat()
|
165
199
|
|
166
200
|
async def medya_oynat(self, secilen_link):
|
167
201
|
if hasattr(self.suanki_eklenti, "play") and callable(self.suanki_eklenti.play):
|
@@ -181,7 +215,7 @@ class KekikStream:
|
|
181
215
|
extract_data = await cikarici.extract(secilen_link, referer=self.suanki_eklenti.main_url)
|
182
216
|
except Exception as hata:
|
183
217
|
konsol.print(f"[bold red]{cikarici.name} » hata oluştu: {hata}[/bold red]")
|
184
|
-
return await self.
|
218
|
+
return await self.sonuc_bulunamadi()
|
185
219
|
|
186
220
|
if isinstance(extract_data, list):
|
187
221
|
secilen_data = await self.arayuz_yonetici.select_from_list(
|
@@ -199,48 +233,12 @@ class KekikStream:
|
|
199
233
|
konsol.log(f"[yellow][»] Oynatılıyor : {secilen_data.url}")
|
200
234
|
self.medya_yonetici.play_media(secilen_data)
|
201
235
|
|
202
|
-
async def tum_eklentilerde_arama(self, sorgu: str):
|
203
|
-
tum_sonuclar = []
|
204
|
-
|
205
|
-
for eklenti_adi, eklenti in self.eklentiler_yonetici.plugins.items():
|
206
|
-
if not isinstance(eklenti, PluginBase):
|
207
|
-
konsol.print(f"[yellow][!] {eklenti_adi} geçerli bir PluginBase değil, atlanıyor...[/yellow]")
|
208
|
-
continue
|
209
|
-
|
210
|
-
konsol.log(f"[yellow][~] {eklenti_adi:<19} aranıyor...[/]")
|
211
|
-
try:
|
212
|
-
sonuclar = await eklenti.search(sorgu)
|
213
|
-
if sonuclar:
|
214
|
-
tum_sonuclar.extend(
|
215
|
-
[{"plugin": eklenti_adi, "title": sonuc.title, "url": sonuc.url, "poster": sonuc.poster} for sonuc in sonuclar]
|
216
|
-
)
|
217
|
-
except Exception as hata:
|
218
|
-
konsol.print(f"[bold red]{eklenti_adi} » hata oluştu: {hata}[/bold red]")
|
219
|
-
|
220
|
-
if not tum_sonuclar:
|
221
|
-
konsol.print("[bold red]Hiçbir sonuç bulunamadı![/bold red]")
|
222
|
-
await self.hicbir_sonuc_bulunamazsa()
|
223
|
-
return []
|
224
|
-
|
225
|
-
return tum_sonuclar
|
226
|
-
|
227
|
-
async def tum_sonuc_sec(self, sonuclar):
|
228
|
-
secenekler = [
|
229
|
-
{"name": f"{f'[{sonuc["plugin"]}]':<21} » {sonuc['title']}", "value": sonuc}
|
230
|
-
for sonuc in sonuclar
|
231
|
-
]
|
232
|
-
|
233
|
-
return await self.arayuz_yonetici.select_from_fuzzy(
|
234
|
-
message = "Arama sonuclarından bir içerik seçin:",
|
235
|
-
choices = secenekler
|
236
|
-
)
|
237
|
-
|
238
236
|
def basla():
|
239
237
|
try:
|
240
238
|
pypi_kontrol_guncelle("KekikStream")
|
241
239
|
|
242
240
|
app = KekikStream()
|
243
|
-
run(app.
|
241
|
+
run(app.baslat())
|
244
242
|
cikis_yap(False)
|
245
243
|
except KeyboardInterrupt:
|
246
244
|
cikis_yap(True)
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: KekikStream
|
3
|
-
Version: 0.3.
|
3
|
+
Version: 0.3.6
|
4
4
|
Summary: terminal üzerinden medya içeriği aramanızı ve VLC/MPV gibi popüler medya oynatıcılar aracılığıyla doğrudan izlemenizi sağlayan modüler ve genişletilebilir bir bıdı bıdı
|
5
5
|
Home-page: https://github.com/keyiflerolsun/KekikStream
|
6
6
|
Author: keyiflerolsun
|
@@ -1,4 +1,4 @@
|
|
1
|
-
KekikStream/__init__.py,sha256=
|
1
|
+
KekikStream/__init__.py,sha256=2eeeKoB1PVLyD23grIko7YDx2jbRJPk6YzSK4-LIE8k,10458
|
2
2
|
KekikStream/__main__.py,sha256=4U-NO1f0Mts5Mf_QnWhWqRbTsRBy2y2VPlpHyaqG9_I,137
|
3
3
|
KekikStream/requirements.txt,sha256=gS_TUUQx5A7FUmRGxj2dQedxheD7qA6AswdUb2y_Ub8,70
|
4
4
|
KekikStream/CLI/__init__.py,sha256=U6oLq_O7u5y2eHhBnmfhZNns_EqHHJXJmzl8jvZFUNY,230
|
@@ -48,9 +48,9 @@ KekikStream/Plugins/JetFilmizle.py,sha256=DPdvTEns8r2MI9pHY8d9EEsUZmlQU7N2C9yr8o
|
|
48
48
|
KekikStream/Plugins/SezonlukDizi.py,sha256=5BZVzQ2eQtymHxO0bzjA2ho4FFNahPFQly4hoHuH8lo,4441
|
49
49
|
KekikStream/Plugins/SineWix.py,sha256=ZtcIwPW0ONGkSjT7Ye8b71RWdHZMUZefX-JTWu6uGSs,4854
|
50
50
|
KekikStream/Plugins/UgurFilm.py,sha256=yYXee5uxwNnPqFJZ6s6cRkmUyqS3Vv8x-iesPalc4j4,2930
|
51
|
-
KekikStream-0.3.
|
52
|
-
KekikStream-0.3.
|
53
|
-
KekikStream-0.3.
|
54
|
-
KekikStream-0.3.
|
55
|
-
KekikStream-0.3.
|
56
|
-
KekikStream-0.3.
|
51
|
+
KekikStream-0.3.6.dist-info/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
|
52
|
+
KekikStream-0.3.6.dist-info/METADATA,sha256=bEpxnxF4AbzzSAwo8BWWo1xQ2AV9Ubk1QDefzNImYbg,3987
|
53
|
+
KekikStream-0.3.6.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91
|
54
|
+
KekikStream-0.3.6.dist-info/entry_points.txt,sha256=dFwdiTx8djyehI0Gsz-rZwjAfZzUzoBSrmzRu9ubjJc,50
|
55
|
+
KekikStream-0.3.6.dist-info/top_level.txt,sha256=DNmGJDXl27Drdfobrak8KYLmocW_uznVYFJOzcjUgmY,12
|
56
|
+
KekikStream-0.3.6.dist-info/RECORD,,
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|