"no-package=s" => \&ExcludePackage,
"n" => \$options{NOSCRIPTS},
- "noscripts" => \$options{NOSCRIPTS},
+ "noscripts" => \$options{ONLYSCRIPTS},
+ "o" => \$options{ONLYSCRIPTS},
+ "onlyscripts" => \$options{ONLYSCRIPTS},
"x" => \$options{INCLUDE_CONFFILES}, # is -x for some unknown historical reason..
"include-conffiles" => \$options{INCLUDE_CONFFILES},
+debhelper (5.0.14) unstable; urgency=low
+
+ * dh_installinit: If run with -o, do the inverse of -n and only
+ set up maintainer script snippets, w/o installing any files.
+ Useful for those edge cases where the init script is provided by upstream
+ and not easily installed by dh_installinit but where it's worth letting
+ it manage the maintainer scripts anyway. Closes: #140881, #184980
+ * -o might be added for other similar commands later if there is any
+ reason to. And yeah, it means that -no is close to a no-op..
+
+ -- Joey Hess <joeyh@debian.org> Sun, 8 Jan 2006 17:21:52 -0500
+
debhelper (5.0.13) unstable; urgency=low
[ Joey Hess ]
Do not modify postinst/postrm/prerm scripts.
+=item B<-o>, B<--onlyscripts>
+
+Only modify postinst/postrm/prerm scripts, do not actually install any init
+script or default files. May be useful if the init script is shipped and/or
+installed by upstream in a way that doesn't make it easy to let
+dh_installinit find it.
+
=item B<-r>, B<--no-restart-on-upgrade>
Do not restart init script on upgrade.
This parameter is deprecated, use the --name parameter instead.
+=item B<
+
=item B<--error-handler=>I<function>
Call the named shell function if running the init script fails. The
pkgfile($package,"init.d");
my $default=pkgfile($package,'default');
- if ($default ne '') {
+ if ($default ne '' && ! $dh{ONLYSCRIPTS}) {
if (! -d "$tmp/etc/default") {
doit("install","-d","$tmp/etc/default");
}
doit("install","-p","-m644",$default,"$tmp/etc/default/$script");
}
- if ($init ne '') {
- if (! -d "$tmp/etc/init.d") {
- doit("install","-d","$tmp/etc/init.d");
+ if ($init ne '' || $dh{ONLYSCRIPTS}) {
+ if (! $dh{ONLYSCRIPTS}) {
+ if (! -d "$tmp/etc/init.d") {
+ doit("install","-d","$tmp/etc/init.d");
+ }
+
+ doit("install","-p","-m755",$init,"$tmp/etc/init.d/$script");
}
-
- doit("install","-p","-m755",$init,"$tmp/etc/init.d/$script");
-
+
# This is set by the -u "foo" command line switch, it's
# the parameters to pass to update-rc.d. If not set,
# we have to say "defaults".
packages
-n NOSCRIPTS if set, do not make any modifications to the
package's postinst, postrm, etc scripts.
+-o ONLYSCRIPTS if set, only make modifications to the
+ package's scripts, but don't look for or
+ install associated files.
-X EXCLUDE exclude a something from processing (you
decide what this means for your program)
(This is an array)