How to remove medibuntu repository and packages?

I followed directions to add medibuntu but it has messed up some codecs and dependencies so I can no longer watch videos

I have run this command, originated by a forum post:

sean@sean-P55-USB3:~$ sudo -E wget --output-document=/etc/apt/sources.list.d/medibuntu.list http://www.medibuntu.org/sources.list.d/$(lsb_release -cs).list && sudo apt-get --quiet update && sudo apt-get --yes --quiet --allow-unauthenticated install medibuntu-keyring && sudo apt-get --quiet update

How do I reverse this?


Solution 1:

Just as a warning, I have not tested these commands, but I cannot see how they could fail. If they did fail, please let me know and I'll update the answer.

Run these commands in a terminal:

sudo apt-get purge medibuntu-keyring
sudo rm /etc/apt/sources.list.d/medibuntu.list
sudo apt-get update

Notice that this will only disable the repository! If you want to remove the packages you installed from that repository, you can use this command:

PKGS=$(dpkg -l | awk '{print $2}' | grep -e aacgain -e aacplusenc -e acroread-fonts -e alsa-firmware -e app-install-data-medibuntu -e apport-hooks-medibuntu -e hot-babe -e ices -e libavcodec-extra-53 -e libavdevice-extra-53 -e libav-extra-dbg -e libavfilter-extra-2 -e libavformat-extra-53 -e libavutil-extra-51 -e libdvdcss2 -e libdvdcss-dev -e libpostproc-extra-52 -e libswscale-extra-2 -e medibuntu-keyring -e mencoder -e mplayer-dbg -e mplayer-doc -e mplayer-gui -e mplayer -e non-free-codecs -e rmconverter -e w32codecs -e w64codecs | tr '\n' ' '); sudo apt-get purge $PKGS

Hope this helps!