添加ubuntu和debian 11换源

This commit is contained in:
lsy 2024-09-22 23:27:12 +08:00
parent 6dcd3ab067
commit f109a84744

View File

@ -39,6 +39,16 @@ case "$version" in
deb ${url}/debian/ bookworm main contrib non-free non-free-firmware
deb ${url}/debian/ bookworm-updates main contrib non-free non-free-firmware
deb ${url}/debian/ bookworm-backports main contrib non-free non-free-firmware
EOF
sudo apt update -y
sudo apt-get update -y
status=1
;;
'bullseye')
cat > "/etc/apt/sources.list" << EOF
deb ${url}/debian/ bullseye main contrib non-free
deb ${url}/debian/ bullseye-updates main contrib non-free
deb ${url}/debian/ bullseye-backports main contrib non-free
EOF
sudo apt update -y
sudo apt-get update -y
@ -52,6 +62,18 @@ case "$system" in
sed -i '/^Server.*/d' "/etc/pacman.conf"
echo "Server = ${url}/archlinuxcn/\$arch"
sudo pacman-key --lsign-key "farseerfc@archlinux.org"
pacman -Syyu
status=1
;;
'ubuntu')
cat > "/etc/apt/sources.list" << EOF
deb ${url}/ubuntu/ ${version} main restricted universe multiverse
deb ${url}/ubuntu/ ${version}-security main restricted universe multiverse
deb ${url}/ubuntu/ ${version}-updates main restricted universe multiverse
deb ${url}/ubuntu/ ${version}-backports main restricted universe multiverse
EOF
sudo apt update -y
sudo apt-get update -y
status=1
;;
esac