File size: 571 Bytes
0163a2c
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
import launch
from pathlib import Path

aria2path = Path(__file__).resolve().parents[0] / "aria2"

for item in aria2path.iterdir():
    if item.is_file():
        item.unlink()

def install_req(check_name, install_name=None):
    if not install_name: install_name = check_name
    if not launch.is_installed(f"{check_name}"):
        launch.run_pip(f"install {install_name}", "requirements for CivitAI Browser")

install_req("send2trash")
install_req("zip_unicode", "ZipUnicode")
install_req("bs4", "beautifulsoup4")
install_req("fake_useragent")
install_req("packaging")