代码拉取完成,页面将自动刷新
同步操作将从 吉客固件(dugiware)/dugitools 强制同步,此操作会覆盖自 Fork 仓库以来所做的任何修改,且无法恢复!!!
确定后同步将在后台操作,完成时将刷新页面,请耐心等待。
#!/bin/bash
set -e
#使用颜色打印函数
source ~/.colorc
do_install()
{
swarn "Install $1 [CHECK]"
depends_str=$(apt-cache depends $1 | grep Depends | awk '{print $2}')
if [ -n "${depends_str}" ]; then
snote "Depends:"
sinfo "${depends_str}"
else
snote "Depends: nothing"
fi
swarn "Install $1 [START]"
#sudo apt-get install -y $1 > /dev/null 2>&1
sudo apt-get install -y $1
if [ $? -eq 0 ]; then
sdone "Install $1 [OK]"
else
serro "Install $1 [ERROR]"
exit 1
fi
}
do_python2_install()
{
swarn "Instal python2 [START]"
do_install python2
sdone "Instal python2 [FINISH]"
swarn "check python2 version [START]"
python2 --version
swarn "check available python verion"
ls /usr/bin/python*
swarn "check current python alternatives before settings"
set +e
sudo update-alternatives --list python
set -e
swarn "set python2 alternatives index as 1"
sudo update-alternatives --install /usr/bin/python python /usr/bin/python2 1
swarn "set python3 alternatives index as 2"
sudo update-alternatives --install /usr/bin/python python /usr/bin/python3 2
swarn "check current python alternatives after settings"
sudo update-alternatives --list python
sdone "plsease choose default phyon ..."
sudo update-alternatives --config python
}
do_pip2_install()
{
echo "sudo python2 pip2fiels/get-pip.py"
sudo python2 pip2files/get-pip.py
}
do_python2_install
do_pip2_install
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。