You don't say what OS you are using, but the sources for Raspbian Buster should be something like:-
deb http://raspbian.raspberrypi.org/raspbian/ buster main contrib non-free rpi
# Uncomment line below then 'apt-get update' to enable 'apt-get source'
#deb-src http://raspbian.raspberrypi.org/raspbian/ buster main contrib non-free rpi
Restoring it should be OK.
NOTE 1 I NEVER use sudo nano
- you should use sudoedit
which edits a temporary file.
NOTE 2 raspbian.raspberrypi.org
is slow and unreliable. I replace with a local mirror; in my case deb http://raspbian.melbourneitmirror.net/raspbian/ buster main contrib non-free rpi
although you could select a local mirror from https://www.raspbian.org/RaspbianMirrors/
NOTE 3 I rarely edit /etc/apt/sources.list.d
, but add additional repositories to /etc/apt/sources.list.d
I have /etc/apt/sources.list.d/vivaldi.list
among others.
NOTE 4 I don't know who suggested using a Ubuntu build; it may or may not work; it is safer to build from source.