On Tue, Jul 23, 2013 at 6:32 AM, Scott Kitterman <ubu...@kitterman.com> wrote: > Assuming add-apt-repository was installed by default, it's close. I think > something like this might be reasonable (imagine some policykit or whatever it > is called now magic here): > > $ sudo apt-get source hello > Reading package lists... Done > Building dependency tree > Reading state information... Done > E: You must put some 'source' URIs in your sources.list > Would you like 'source' URIs to be added? (y/N) > Y > deb-src lines have been added to your sources.list. > ... > Get:9 http://archive.ubuntu.com saucy/main Sources [1,001 kB] > Get:10 http://archive.ubuntu.com saucy/restricted Sources [6,578 B] > Get:11 http://archive.ubuntu.com saucy/universe Sources [6,071 kB] > > In other words, it's, I think, possible to make it roughly as easy as it is > now to get source without having the sources.list "cluttered". For users of > our releases, I doubt it saves much, but that would be a way to do it that > both avoids whatever amount of bandwidth usage is involved until the user opts > in to it, but preserves ready access to the source that I think is important.
Depending on how clever and one-off you want to be you could also just give them the http url to the source as well. It shouldn't be that hard to guess since apt already has most of the information needed to just generate the URL from a chosen apt server in the normal deb. This would allow for one-off downloads (for example somebody needs to look at the way debian does some of it's compiles so they can replicate without a package so they grab the source for nginx -- that's a one-off IMO if they would never use any other source package.) Though I personally like a default command that would be something like add-apt-default-sources so you can also give them the ability to run that command and disable sources too (but you can already do that via the GUI and terminal by editing /etc/apt/sources.list and such.) -- Ubuntu-devel-discuss mailing list Ubuntu-devel-discuss@lists.ubuntu.com Modify settings or unsubscribe at: https://lists.ubuntu.com/mailman/listinfo/ubuntu-devel-discuss