0

I can't install anything or do anything without ubuntu giving me

E:Type 'sudo' is not known on line 1 in source list /etc/apt/sources.list.d/spotify.list
E:The list of sources could not be read

I only want to install adobe flash.

How can I fix this?

Zanna
  • 70,465

1 Answers1

1

Welcome to Ubuntu, you will be good to go with a little more experience.

I assume you manually edited the file /etc/apt/sources.list.d/spotify.list and you now have a typo in the file.

Open the file in any editor (sudo nano /etc/apt/sources.list.d/spotify.list ) and fix it.

If you do not know the syntax, post the contents of the file here.

See also : How do I remove a malformed line from my sources.list?

Panther
  • 102,067
  • Thank you, I did find the error in the code but now I'm not allowed to save it. I tried to replace it but I got "You do not have the permissions necessary to save the file. Please check that you typed the location correctly and try again." The file is read only and I cant change it even tho I'm the admin of my own pc – Isaiah Wells Sep 12 '17 at 02:26
  • Did you edit the file as root ? with sudo nano ... ? gksu gedit ? How did you open the file ? You can save it in your home directory and then sudo mv /home/your_user/spotify.list /etc/apt/sources.list.d/spotify.list – Panther Sep 12 '17 at 02:29
  • Thank you very much kind sir, I have figured out that everything must be done in the terminal to "get good" with linux. My problem has been solved thank you very much sir. – Isaiah Wells Sep 12 '17 at 02:40
  • Not necessarily, it is just easier to post commands here rather than screenshots and in general Linux gives meaningful error messages. Once you learn to read the messages and man pages you are good to go. Just as in Windows , graphical tools sometimes do not give as much information. – Panther Sep 12 '17 at 02:42