예제 #1
0
def setup():
    if not os.path.exists(BGMI_PATH):
        print_warning('BGMI_PATH %s does not exist, installing' % BGMI_PATH)

        create_dir()
        install_crontab()

    init_db()
예제 #2
0
def setup():
    need_to_init = False
    if not os.path.exists(BGMI_PATH):
        need_to_init = True
        print_warning('BGMI_PATH %s does not exist, installing' % BGMI_PATH)

    create_dir()
    init_db()
    if need_to_init:
        install_crontab()
예제 #3
0
def setup():
    if not os.path.exists(BGMI_PATH):
        print_warning('BGMI_PATH %s does not exist, installing' % BGMI_PATH)
        from bgmi.setup import create_dir, install_crontab
        create_dir()
        install_crontab()

    if not os.path.exists(DB_PATH):
        init_db(DB_PATH)
    main()
예제 #4
0
def setup() -> None:
    need_to_init = False
    if not os.path.exists(BGMI_PATH):
        need_to_init = True
        print_warning(f"BGMI_PATH {BGMI_PATH} does not exist, installing")

    create_dir()
    init_db()
    if need_to_init:
        install_crontab()
    write_default_config()
예제 #5
0
def setup():
    if not os.path.exists(BGMI_PATH):
        print_warning('BGMI_PATH %s does not exist, installing' % BGMI_PATH)
        from bgmi.setup import create_dir, install_crontab
        create_dir()
        if not platform.system() == 'Windows':
            # if not input('Do you want to install a crontab to auto-download bangumi?(Y/n): ') == 'n':
            install_crontab()

    # if not os.path.exists(DB_PATH):
    init_db(DB_PATH)
    main()
예제 #6
0
파일: setup.py 프로젝트: xxoxx/BGmi
 def run(self):
     install.do_egg_install(self)
     install_crontab()
     create_dir()