Re: "register" files in dpkg database programmatically? (was Re: How Debian Deals with Data)

2011-07-18 Thread Christopher Baines
On Mon, 2011-07-18 at 14:19 +0200, Paul Wise wrote: > On Sun, Jul 17, 2011 at 1:04 AM, Peter Samuelson wrote: > > > - Treat the file as though it were shipped in the package directly. > > This means it is removed on package upgrade, as well as on package > > removal. This is very straightforwar

Re: "register" files in dpkg database programmatically? (was Re: How Debian Deals with Data)

2011-07-18 Thread Paul Wise
On Sun, Jul 17, 2011 at 1:04 AM, Peter Samuelson wrote: > - Treat the file as though it were shipped in the package directly. >  This means it is removed on package upgrade, as well as on package >  removal.  This is very straightforward (append the filename to >  /var/lib/dpkg/info/{foo}.list), b

Re: "register" files in dpkg database programmatically?

2011-07-16 Thread Tollef Fog Heen
]] Peter Samuelson | - Treat the file as though it were shipped in the package directly. | This means it is removed on package upgrade, as well as on package | removal. This is very straightforward (append the filename to | /var/lib/dpkg/info/{foo}.list), but perhaps not too useful. This

Re: "register" files in dpkg database programmatically? (was Re: How Debian Deals with Data)

2011-07-16 Thread Peter Samuelson
[Roger Leigh] > By registering the file as I create it, I completely avoid the > breakage potential of complex and poorly-tested postrm logic--it's > completely removed. It also means that other packages can't > arbitrarily overwrite it. It would certainly be very useful for > e.g. generated fil

Re: "register" files in dpkg database programmatically? (was Re: How Debian Deals with Data)

2011-07-16 Thread Roger Leigh
On Sat, Jul 16, 2011 at 08:32:46PM +0100, Christopher Baines wrote: > On Sat, 2011-07-16 at 17:12 +0200, Paul Wise wrote: > > On Sat, Jul 16, 2011 at 4:48 PM, Peter Samuelson wrote: > > > > > It would be useful in any number of situations to be able > > > to "register" a file with dpkg: tell dpkg

Re: "register" files in dpkg database programmatically? (was Re: How Debian Deals with Data)

2011-07-16 Thread Christopher Baines
On Sat, 2011-07-16 at 17:12 +0200, Paul Wise wrote: > On Sat, Jul 16, 2011 at 4:48 PM, Peter Samuelson wrote: > > > It would be useful in any number of situations to be able > > to "register" a file with dpkg: tell dpkg that a given package owns a > > given file, so that it is automatically remove

Re: "register" files in dpkg database programmatically? (was Re: How Debian Deals with Data)

2011-07-16 Thread Paul Wise
On Sat, Jul 16, 2011 at 4:48 PM, Peter Samuelson wrote: > It would be useful in any number of situations to be able > to "register" a file with dpkg: tell dpkg that a given package owns a > given file, so that it is automatically removed when the package is > removed or upgraded.  I can see this b

"register" files in dpkg database programmatically? (was Re: How Debian Deals with Data)

2011-07-16 Thread Peter Samuelson
[Christopher Baines] > I would consider the best solution to be a mixture of the two, so the > symbolic package handles fetching the data, but then tells dpkg what > files its putting where. I don't really care that much about huge data packages, but this jumped out at me. It would be useful in