Bug#934066: sysv-rc: /etc/init.d/README is misleading wrt *.sh

Adam Borowski kilobyte at angband.pl
Fri Aug 9 00:12:42 BST 2019


On Thu, Aug 08, 2019 at 08:21:34PM +0000, Dmitry Bogatov wrote:
> [2019-08-06 18:36] Adam Borowski <kilobyte at angband.pl>
> > The documentation in /etc/init.d/README talks a lot about *.sh files in that
> > dir, in a way that suggests that's the way regular init scripts should be
> > named.  Could you please disambiguate?
> >
> > (Apologies for not submitting patches myself -- I'm on a phoney PDA until
> > mid August.)
> 
> Copy-editing is welcome.
> 
> From 949cb25e210d8f896068a018223c8cc2d78ac98f Mon Sep 17 00:00:00 2001
> From: Dmitry Bogatov <KAction at debian.org>
> Date: Tue, 6 Aug 2019 22:41:56 +0000
> Subject: [PATCH] Do not imply in README that init scripts must have extension
> 
> Avoid refererring to init scripts using /etc/init.d/*.sh wildcard,
> most of them do not have (and should not!) extension.

> -Debian Policy dictates that /etc/init.d/*.sh scripts must work properly
> -when sourced.  The following additional rules apply:
> +Debian Policy dictates that scripts in /etc/init.d/ must work properly when
> +sourced.  The following additional rules apply:
>  
> -* /etc/init.d/*.sh scripts must not rely for their correct functioning
> +* /etc/init.d/* scripts must not rely for their correct functioning
>    on their being sourced rather than executed.  That is, they must work
>    properly when executed too. They must include "#!/bin/sh" at the top.

This part is not true: there's also #!/usr/bin/env /lib/init/init-d-script

>    This is useful when running scripts in parallel.
>  
> -* /etc/init.d/*.sh scripts must conform to the rules for sh scripts as
> +* /etc/init.d/* scripts must conform to the rules for sh scripts as


Meow!
-- 
⢀⣴⠾⠻⢶⣦⠀
⣾⠁⢠⠒⠀⣿⡁ Debian is one big family.  Including that weird uncle
⢿⡄⠘⠷⠚⠋⠀ and ultra-religious in-laws.
⠈⠳⣄⠀⠀⠀⠀




More information about the Debian-init-diversity mailing list