代码拉取完成,页面将自动刷新
#!/bin/bash
soft_list=soft_list.ini
# ***********************************************************************
software_config(){
ln -sf /usr/bin/nvim /usr/bin/vi
}
# ***********************************************************************
software_install(){
pacman -Sy --noconfirm
local line=
cat $soft_list |while read -r line
do
if echo "$line" |grep \;;then
continue
fi
if pacman -S --noconfirm "$line";then
echo "install $line"
else
echo "failed install $line"
fi
done
}
# ***********************************************************************
pip_npm_install(){
pip3 config set global.index-url https://pypi.tuna.tsinghua.edu.cn/simple
pip3 install pynvim
npm config set registry https://registry.npm.taobao.org
npm install -g bash-language-server
npm install -g vscode-langservers-extracted
if npm install -g neovim ;then
echo "pip_npm_install ok"
else
echo "pip_npm_install failed"
fi
}
# ***********************************************************************
system_config(){
echo performance > /sys/devices/system/cpu/cpu5/cpufreq/scaling_governor
echo performance > /sys/devices/system/cpu/cpu4/cpufreq/scaling_governor
echo performance > /sys/devices/system/cpu/cpu3/cpufreq/scaling_governor
echo performance > /sys/devices/system/cpu/cpu2/cpufreq/scaling_governor
echo performance > /sys/devices/system/cpu/cpu1/cpufreq/scaling_governor
echo performance > /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
}
# ***********************************************************************
main(){
system_config
software_install
pip_npm_install
software_config
}
main
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。