Public bug reported: With the same <sourceline> argument, the `apt-add-repository` command is not entirely reversed by the `apt-add-repository -r` command.
For example: $ sudo apt-add-repository ppa:dajhorn/ppa $ cat /etc/apt/sources.list.d/dajhorn-ppa-maverick.list deb http://ppa.launchpad.net/dajhorn/ppa/ubuntu maverick main deb-src http://ppa.launchpad.net/dajhorn/ppa/ubuntu maverick main $ sudo apt-add-repository --remove ppa:dajhorn/ppa $ cat /etc/apt/sources.list.d/dajhorn-ppa-maverick.list deb-src http://ppa.launchpad.net/dajhorn/ppa/ubuntu maverick main Notice that the deb-src line persists. The expected behavior is that all lines added by `apt-add-repository` are removed and/or the list file is entirely deleted. Furthermore, `apt-add-repository --remove` doesn't handle an explicit deb-src line: $ apt-add-repository --remove 'deb-src http://ppa.launchpad.net/dajhorn/ppa/ubuntu maverick main' $ echo $? 0 $ cat dajhorn-ppa-maverick.list deb-src http://ppa.launchpad.net/dajhorn/ppa/ubuntu maverick main The expected behavior is the deletion of the given deb-src line. If the <sourceline> argument doesn't exist, then an error message is emitted, but the result code is incorrect: $ apt-add-repository --remove 'deb-src http://ppa.launchpad.net/dajhorn/ppa/bogus maverick main' Error: 'deb-src http://ppa.launchpad.net/dajhorn/ppa/bogus maverick main' doesn't exist in a sourcelist file $ echo $? 0 $ apt-cache policy python-software-properties python-software-properties: Installed: 0.76.7 Candidate: 0.76.7 Version table: *** 0.76.7 0 500 http://us.archive.ubuntu.com/ubuntu/ maverick/main amd64 Packages 100 /var/lib/dpkg/status $ lsb_release -rd Description: Ubuntu 10.10 Release: 10.10 ** Affects: software-properties (Ubuntu) Importance: Undecided Status: New -- `apt-add-repository --remove` doesn't remove deb-src lines https://bugs.launchpad.net/bugs/680203 You received this bug notification because you are a member of Ubuntu Bugs, which is subscribed to Ubuntu. -- ubuntu-bugs mailing list ubuntu-bugs@lists.ubuntu.com https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs