3

I am new to ubuntu and I created several documents accidently when I opened sources.list. For example, I have sources.list, list, and Untitled Document. I think my computer is now not able to know which document it is referring and I am getting errors trying to download R. Do you know how to fix this so that I just have one document called sources.list with one mirror in it to download packages from?

Output of lsb_release -a:

no LSB modules are available
Description: Ubuntu 15.04 
Codename: vivid

Output of apt cacher show r-base | grep ersion

WARNING: apt does not have a stable CLI interface yet. Use with caution in scripts

Output of ls /etc/apt/:

apt.conf.d sources.list~ sources.list.save trusted.gpg~ preferences.d sources.list.d trusted.gpg trusted.gpg.d

Output of sudo apt-get update

Type Rstudio is not known on line 33 in source list 
the list of sources could not be read

contents of /etc/apt/sources.list

## N.B. software from this repository is ENTIRELY UNSUPPORTED by the Ubuntu 
## team, and may not be under a free licence. Please satisfy yourself as to 
## your rights to use the software. Also, please note that software in 
## multiverse WILL NOT receive any review or updates from the Ubuntu
## security team.

## N.B. software from this repository may not have been tested as
## extensively as that contained in the main release, although it includes
## newer versions of some applications which may provide useful features.
## Also, please note that software in backports WILL NOT receive any review
## or updates from the Ubuntu security team.


## Uncomment the following two lines to add software from Canonical's
## 'partner' repository.
## This software is not part of Ubuntu, but is offered by Canonical and the
## respective vendors as a service to Ubuntu users.
# deb http://archive.canonical.com/ubuntu vivid partner
# deb-src http://archive.canonical.com/ubuntu vivid partner

Rstudio
deb http://mirror.evolvedservers.com/ubuntu-archive/ vivid main

deb http://archive.ubuntu.com/ubuntu vivid main universe restricted multiverse
Zanna
  • 70,465

1 Answers1

1

If you have a corrupted sources.list file. You could try this:

Remove the corrupted file:

sudo rm /etc/apt/sources.list

sudo software-properties-gtk

Then tick all the boxes, and change the 'Download from' server, this will create a new sources.list.

enter image description here

Then add any additional repos as needed.

This worked for me.

Also a nice tool that builds the source list for you. Ubuntu Sources List Generator: HERE

pst007x
  • 8,052