Without any express or implied warranty, the following workaround worked
for me. It searches for any "deb" lines for ppa sources, and adds the
corresponding "deb-src" line after it. Furthermore, it makes an effort
not to introduce consecutive duplicate lines, and it keeps backups.
sudo perl -lanE '
BEGIN { my $prev_line; }
print if $_ ne $prev_line;
$prev_line = $_ unless m{^\s*(#|$)};
if (m{\Qdeb http://ppa.launchpad.net}) {
s/^deb/deb-src/; print;
$prev_line = $_;
}' -iBACKUP /etc/apt/sources.list.d/*.list
--
add-apt-repository ppa:username does not add deb-src entry
https://bugs.launchpad.net/bugs/399711
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs