-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathAutoKemono.bat
136 lines (124 loc) · 4.4 KB
/
AutoKemono.bat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
@ECHO OFF
call config.bat
echo =======================
echo ===== FantuScript =====
echo ===== Dl - Kemono =====
echo ===== V : %version% =====
echo ===== FantuScript =====
echo =======================
:verifpython
if exist "%pythonpath%" goto :verifrequirement else
echo. & echo. & echo Have you installed Python and these updates ? & set /p python3= Non (1) :
if %python3%== 1 echo Install Python here :https://www.python.org/downloads/ . To use Kemono ! & pause & goto :fin2
:verifrequirement
if exist "%pythonpath%\Lib\site-packages\beautifulsoup4-4.11.1.dist-info" goto:verifcookie else goto:requirement
if exist "%pythonpath%\Lib\site-packages\requests-2.27.1.dist-info" goto:verifcookie else goto:requirement
if exist "%pythonpath%\Lib\site-packages\yt_dlp-2022.4.8.dist-info" goto:verifcookie else goto:requirement
:requirement
echo Wish to set up these requirements to you ? (Python must be installed.)
set /p requirement= Yes (1) or No (2) :
if %requirement%== 1 goto :install
if %requirement%== 2 pause & goto :fin2
:verifcookie
if exist "kemono.party_cookies.txt" goto :language else
echo. & echo. & echo Do you have the cookie with the .bat?
set /p cookies= Non (1) :
if %cookies%== 1 echo installer get-cookiestxt here [chrome] https://chrome.google.com/webstore/detail/get-cookiestxt/bgaddhkoddajcdgocldbbfleckgcbcid?hl=en Place the Kemono cookies with the .Bat then. & pause & goto :fin2
:install
set r1=beautifulsoup4==4.11.1
set r2=requests==2.27.1
set r3=yt_dlp==2022.4.8
pip install %r1%
pip install %r2%
pip install %r3%
echo.
echo.
echo Script ready to use!
goto :language
:language
echo.
echo.
echo Wich language went you to use ?
set /p lng= Fr (1) ou En (2) :
if %lng%== 1 set lngu= fr & goto :start1
if %lng%== 2 set lngu= en & goto :start1
:start1
echo.
echo.
if %lngu%== fr echo %restartfr%
if %lngu%== fr echo %acceptation%
if %lngu%== en echo %reloaden%
if %lngu%== en echo %accept%
set /p restart=:
if %restart%== 1 goto :timer
if %restart%== 2 goto :Start
:timer
echo.
echo.
if %lngu%== fr echo %timerfr%
if %lngu%== en echo %timeren%
set /p time= :
set /a time=%time%
if %time% GEQ 1 goto :Start
if %time% LSS 1 if %lngu%== fr echo %timerfrer% & pause & goto :timer
if %time% LSS 1 if %lngu%== en echo %timerener% & pause & goto :timer
:Start
echo.
echo.
if %lngu%== fr echo %dlzonefr%
if %lngu%== fr echo %acceptation%
if %lngu%== en echo %dlzoneen%
if %lngu%== en echo %accept%
set /p changement= :
if %changement%== 1 set changement2= true
if %changement%== 2 set changement2= false
if %changement2%== true if %lngu%== fr echo %dlsetfr%
if %changement2%== true if %lngu%== en echo %dlseten%
if %changement2%== true set /p fichiernom= :
if %changement2%== false set fichiernom=Dl
if %lngu%== fr echo. & echo. & echo %dluserfr% : %~dp0%fichiernom%
if %lngu%== en echo. & echo. & echo %dluseren% : %~dp0%fichiernom%
if exist "%fichiernom%" goto :fin
echo.
echo.
if %lngu%== fr if not exist "%fichiernom%" echo %repfr%
if %lngu%== fr echo %acceptation%
if %lngu%== en if not exist "%fichiernom%" echo %repen%
if %lngu%== en echo %accept%
set /p fcre= :
if %fcre%== 1 mkdir %fichiernom% & goto :fin
if %fcre%== 2 goto :Start
:fin
echo.
echo.
if %lngu%== fr echo %urlfr%
if %lngu%== en echo %urlen%
set /p url= :
echo.
echo.
if %lngu%== fr echo %varenitfr% & echo %pixivfr1fr% & echo %fantia2fr%
if %lngu%== en echo %vareniten% & echo %pixivfr1en% & echo %fantia2en%
set /p t= :
if %t%== 1 goto :option1
if %t%== 2 goto :option2
:option1
python kemono-dl.py --cookies "kemono.party_cookies.txt" --links %url% --filename-pattern "{service} {filename}_p{index} by {username}.{ext}" --dirname-pattern "%fichiernom%"
if %time% GEQ 1 set /a time=%time%-1
if %time% GEQ 1 if %lngu%== fr echo %dltfr%%time%Dl & goto :Start
if %time% GEQ 1 if %lngu%== en echo %dlten%%time%Dl & goto :Start
if %time% LSS 1 goto :fin2
:option2
python kemono-dl.py --cookies "kemono.party_cookies.txt" --links %url% --filename-pattern "{service} {title}_p{index} by {username}.{ext}" --dirname-pattern "%fichiernom%"
if %restarty%== true echo Et c'est re partie ! & goto :Start
if %time% LSS 1 goto :fin2
:fin2
echo ==> Fermeture du programme. <==
echo.
echo.
echo =======================
echo ===== FantuScript =====
echo ===== Dl - Kemono =====
echo ===== V : 1.0.0-A =====
echo ===== FantuScript =====
echo =======================
pause