pip-helper/python_jc.py
2023-05-10 17:44:39 +08:00

29 lines
526 B
Python
Raw Permalink Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import sys
import os
from time import sleep
ml = os.getcwd()
file_error = '文件丢失,请重新安装!!'
# def
def open_exe(exe_name):
if os.path.exists(os.path.join(ml, f"{exe_name}.exe")):
os.system(f"start {exe_name}.exe")
else:
print(file_error)
sleep(1)
pass
# try
try:
import pip
print('pip已经安装')
sleep(0.5)
open_exe('client')
except ImportError:
print("请安装Pip或者python")
sleep(2)
sys.exit()