From 0cdb9b1f42bb628e36fff004377df7f46a0d74e5 Mon Sep 17 00:00:00 2001 From: gfdgd_xi <3025613752@qq.com> Date: Tue, 22 Nov 2022 22:27:18 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96wine=E5=AE=89=E8=A3=851?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- AllInstall.py | 59 ++++++++++++++++++++++++++++----------------------- 1 file changed, 33 insertions(+), 26 deletions(-) diff --git a/AllInstall.py b/AllInstall.py index ad61ad8..cf43bae 100755 --- a/AllInstall.py +++ b/AllInstall.py @@ -57,30 +57,37 @@ print("请问是否要更新操作系统?[Y/N]", end=' ') choose = input().upper() if not choose == "N": os.system("sudo apt upgrade -y") -print("请问是否要安装原版 wine(wine64)?[Y/N]", end=' ') -choose = input().upper() -if not choose == "N": - os.system("sudo apt install wine -y") -print("请问是否要安装 deepin-wine?[Y/N]", end=' ') -choose = input().upper() -if not choose == "N": - os.system("sudo apt install deepin-wine -y") -print("请问是否要安装 deepin-wine5(需要安装最新版星火应用商店)?[Y/N]", end=' ') -choose = input().upper() -print("请问是否要安装 deepin-wine5-stable?[Y/N]", end=' ') -choose = input().upper() -if not choose == "N": - os.system("sudo apt install deepin-wine5-stable -y") -print("请问是否要安装 deepin-wine6-stable?[Y/N]", end=' ') -choose = input().upper() -if not choose == "N": - os.system("sudo apt install deepin-wine6-stable -y") -print("请问是否要安装 spark-wine7-devel(需要安装最新版星火应用商店)?[Y/N]", end=' ') -choose = input().upper() -if not choose == "N": - InstallSparkWine("spark-wine7-devel") -print("请问是否要安装 ukylin-wine(需要添加 ukylin 源,但因为可能会导致系统问题,将不会自动添加)?[Y/N]", end=" ") -choose = input().upper() -if not choose == "N": - os.system("sudo apt install ukylin-wine -y") +if os.system("which wine > /dev/null"): + print("请问是否要安装原版 wine(wine64)?[Y/N]", end=' ') + choose = input().upper() + if not choose == "N": + os.system("sudo apt install wine -y") +if os.system("which deepin-wine > /dev/null"): + print("请问是否要安装 deepin-wine?[Y/N]", end=' ') + choose = input().upper() + if not choose == "N": + os.system("sudo apt install deepin-wine -y") +if os.system("which deepin-wine5 > /dev/null"): + print("请问是否要安装 deepin-wine5(需要安装最新版星火应用商店)?[Y/N]", end=' ') + choose = input().upper() +if os.system("which deepin-wine5-stable > /dev/null"): + print("请问是否要安装 deepin-wine5-stable?[Y/N]", end=' ') + choose = input().upper() + if not choose == "N": + os.system("sudo apt install deepin-wine5-stable -y") +if os.system("which deepin-wine6-stable > /dev/null"): + print("请问是否要安装 deepin-wine6-stable?[Y/N]", end=' ') + choose = input().upper() + if not choose == "N": + os.system("sudo apt install deepin-wine6-stable -y") +if os.system("which spark-wine7-devel > /dev/null"): + print("请问是否要安装 spark-wine7-devel(需要安装最新版星火应用商店)?[Y/N]", end=' ') + choose = input().upper() + if not choose == "N": + InstallSparkWine("spark-wine7-devel") +if os.system("which ukylin-wine > /dev/null"): + print("请问是否要安装 ukylin-wine(需要添加 ukylin 源,但因为可能会导致系统问题,将不会自动添加)?[Y/N]", end=" ") + choose = input().upper() + if not choose == "N": + os.system("sudo apt install ukylin-wine -y") print("全部完成!") \ No newline at end of file