mirror of
https://gitea.blesmrt.net/mikaela/shell-things.git
synced 2024-11-19 17:49:23 +01:00
21 lines
865 B
Bash
Executable File
21 lines
865 B
Bash
Executable File
#!/usr/bin/env bash
|
|
export RELEASE=$(lsb_release -sc)
|
|
export DOWNLOAD="https://raw.githubusercontent.com/Mikaela/shell-things/master/etc/apt/sources.list/$RELEASE"
|
|
echo "I am now changing directory to /etc/apt/."
|
|
echo ""
|
|
cd /etc/apt/
|
|
echo "I will now backup sources.list to sources.list.bak ."
|
|
echo ""
|
|
cp /etc/apt/sources.list /etc/apt/sources.list.bak
|
|
echo "I will now download the sources.list file from https://raw.githubusercontent.com/Mikaela/shell-things/master/etc/apt/sources.list/$RELEASE and save it as /etc/apt/sources.list ."
|
|
echo ""
|
|
echo "" > /etc/apt/sources.list
|
|
\wget $DOWNLOAD -O /etc/apt/sources.list
|
|
echo ""
|
|
echo "The new sources.list file should now be installed."
|
|
echo ""
|
|
echo "Finally, I will now run 'apt-get -y update' so the new sources.list is used."
|
|
echo ""
|
|
apt-get update
|
|
echo "I have now finished everything that I was supposed to do."
|