Steve Kemp's Blog Writings relating to Debian & Free Software

Debian is missing a tool, want to write it?

Friday, 14 June 2013

Seeing this piece in the news, about how is now unsafe, I was reminded we don't have a tool to manipulate sources.lists entries.

For example:

$ apt-sources list
deb squeeze main non-free contrib
deb-src squeeze main

deb squeeze/updates main
deb-src squeeze/updates main

How about listing only my repos?

$ apt-sources list
deb-src ./
deb ./
deb ./
deb-src ./
deb-src ./
deb ./

Now add in a command to delete lines matching a given pattern:

# apt-sources delete

Doesn't that seem like a tool that should exist?

I've added this quick hack to this repository which you can submit pull requests against, or use as a base.

TODO: Write the "add" handler. Neaten.

Ever felt jealous that Ubuntu users can add PPAs? Nows your chance to do something like this:

# apt-sources add "deb ./"

| No comments



Spiral Logo


Recent Posts

Recent Tags


RSS Feed

  • Subscribe to feed