Re: RFS: kstars-data-extra-tycho2 (third try)
Noel David Torres Taño wrote:
> On Viernes 12 Noviembre 2010 16:47:24 Benoît Knecht escribió:
> > I'll try and have a look at postinst later, but I'm not very familiar
> > with debconf or the kstarsrc syntax, so I'll be of little assistance I'm
> > afraid.
> Dear Benoît:
> Have you been able to do the check?
Sorry, I had completely forgotten; thanks for reminding me.
So first thing first. I tried installing your package using piuparts,
and got the following error while running 'dpkg -i
Selecting previously deselected package kstars-data-extra-tycho2.
(Reading database ... 6131 files and directories currently installed.)
Unpacking kstars-data-extra-tycho2 (from .../kstars-data-extra-tycho2_1.1r1-2_all.deb) ...
Setting up kstars-data-extra-tycho2 (1.1r1-2) ...
/var/lib/dpkg/info/kstars-data-extra-tycho2.postinst: 39: cannot create /etc/kde4/kstarsrc: Directory nonexistent
dpkg: error processing kstars-data-extra-tycho2 (--install):
subprocess installed post-installation script returned error exit status 2
Errors were encountered while processing:
(Since your package doesn't depend on any kde4 stuff, you need to make
sure /etc/kde4 exists.)
Regarding debconf, you should make sure that you're not prompting the
user when it's not necessary, so your postinst should take into account
which parameter is passed to it; see  for details.
Along the same idea (minimizing user prompting), I think it would be a
good idea to read kstarsrc and see if action/get_data is already set; if
it is, don't prompt the user. Also, it would be better to just edit that
file instead of overwriting it.
Finally, I think the default for
kstars-data-extra/kstarsrc-does-not-exist should be false (you don't
want to create that configuration file and lock downloads without the
user explicitly deciding to do so).