Edit sources list in Debian 12 or Ubuntu
Debian 12 sources sample :
deb https://deb.debian.org/debian bookworm main non-free-firmware
#deb-src http://deb.debian.org/debian bookworm main non-free-firmware
deb https://deb.debian.org/debian-security/ bookworm-security main non-free-firmware
#deb-src http://deb.debian.org/debian-security/ bookworm-security main non-free-firmware
deb https://deb.debian.org/debian bookworm-updates main non-free-firmware
#deb-src http://deb.debian.org/debian bookworm-updates main non-free-firmware
#debian12 #ubuntu
Our services :
Bizanosa WordPress Support Service : https://bizanosa.com/wordpress-support-service/
Bizanosa VPS Support service : https://bizanosa.com/web-server-services/
Please consider https://www.buymeacoffee.com/bizanosa
.
If this video was helpful to you, please consider supporting my channel : https://paypal.me/rwahowa
.
Hi there and welcome to this video. In this video, I’m just going to do a quick video to show you how you can edit the sources list for Debian, and I believe this should work as well for Ubuntu and related Debian-based distros. I’m just going to start right away.
To edit the sources list, you’re going to do `sudo apt edit-sources`. Okay, so you can see mine instantly took me to edit it, and I believe I’m using Nano. However, in your case, most probably you will find that you are asked. The next step will be you’ll get a terminal request asking for which editor you should use, and you can choose Nano or Vim or whichever one you have installed on your system. You’ll just press either one, two, and it will open the editor with the sources list. In my case, you can see this is The Bookworm sources list, and you can change it and you can paste your sources in here, especially when you install a new Debian.
Usually, you’ll need to add the sources in here, and I’m going to add this as a sample in the description. If you need to have the sources as well on your sources list. If you want to save, of course, you can do in Nano, you’re going to do `Ctrl + X`, and then `Y` to accept the changes. But if you use Vim, you can do `Shift + ZZ` or you can do `:wq!`, and that’s going to exit out of Vim. `WQ exclamation mark`, and that’s going to exit you out of Vim.
If you’re on a desktop, make sure you install Vim. Just do `sudo apt install vim`, and that will allow you to use commands like `Shift + ZZ` to save or `Shift + Z + Q` to close it without saving. So in this case, I’m using Nano. I’m just going to do `Ctrl + X`, and since I didn’t change anything, it’s just going to close it.
So that’s it. It’s just that one line `sudo apt edit-sources` is going to allow you to edit the default sources for the other sources files. And usually, you’ll find that when you install other applications, they will bring their own source files. And the source files can be found under `/etc`. You can just do `LS` to search for it.
`LS`, and you’ll find it under `/etc`. You’ll find it inside of `apt`. And then since I don’t know where to go next, I’m just going to press `Tab` twice, and that’s going to list the files which are there for me. And I can see here what we have `Ed`, and we have `sources list`. So we’ll go into `sources list`. I’ll press `Tab` to autocomplete, but I want to go into the directory `sources list- D`, and if I press `Enter`, it’s going to show me the current source files that I have for other applications.
So if you need to edit any of this, you need to remove something that’s causing errors on your system, you can just do `rm` to remove whichever one of these files which are here. So that’s it for this video. I will see you next time in another one.
GET SOCIAL WITH ME:
FACEBOOK: https://www.facebook.com/rwahowa/
INSTAGRAM: https://www.instagram.com/rwahowa/
TWITTER: https://twitter.com/rwahowa/
WEBSITE : https://bizanosa.com
source