[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

maint scripts



Hi all,

As per policy, my unofficial package of IRAF now includes a perl script
update-extern.pkg.pl which is installed in /usr/bin/.  It will be used
by external IRAF packages, each of which need to update extern.pkg.  Of
course, each also depends on IRAF.  If memory serves, the script
shouldn't have the .pl extension; can someone remind me why?  (I like it
because then vim color-highlights it).

This script takes two arguments: the first is "add|remove" and the
second is the name of the external pacakge.  Both actually do "remove"
first, for idempotency.

I'm wondering how this should be implemented in the maintscripts.  All
that _needs_ to happen is:

	- run add for initial installation only
	- run remove for removal

What I think I'd like to do is also run add on upgrades, in case my
script changes and I want to fix something.

Debian's maintscripts obviously allow for much more generality than I
need, so I'd appreciate it if someone could confirm that the following
makes sense:

	preinst:
		upgrade)
			add
		install)
			add

	postrm:
		remove)
			delete

I don't think its worth implementing error-unwind, because if my script
fails once, I see no reason why it won't fail again.  So, all the other
arguments will fall into 
	*) exit 1;

Cheers,
-- 
Justin
aptitude install iraf saods9 eclipse xpa sextractor x11iraf wcstools pyraf
http://www.justinpryzby.com/debian/

References

[1] http://www.justinpryzby.com/iraf.noao.edu/update-extern.pkg.sh

Attachment: signature.asc
Description: Digital signature


Reply to: