Re: File naming of scripts in /etc/init.d
On Mon, Jun 25, 2012 at 01:51:36PM +0200, Steve R. Petruzzello wrote:
> I noticed that some scripts in /etc/init.d/ are suffixed by .sh and some are
> not. [...] All except console-screen.sh, hwclock.sh and keymap.sh are from
> the initscripts package.
> So 1) nowhere is .sh suffixing mentioned and 2) some scripts are not named by
> their package's name (hwclock.sh is part of the util-linux package). Is there
> a reason for this?
Nowadays, it's essentially the case that
- scripts with a .sh suffix are run from rcS
- they are not intended to be run by hand and/or after boot, or
else they can screw up the system state
> Would it be purely aesthetics to clean out these script names?
Yes, though the above distinction about them being run from rcS
would be lost. And given the history, and the fact that other
scripts depend on them (the names are used in the inter-script
dependencies), renaming them is do-able, but not something we
should be doing this close to the freeze.
> PS: Is there a way to list all packages putting a file in /etc/init.d/?
dpkg -S $(ls -1 /etc/init.d/*)
.''`. Roger Leigh
: :' : Debian GNU/Linux http://people.debian.org/~rleigh/
`. `' schroot and sbuild http://alioth.debian.org/projects/buildd-tools
`- GPG Public Key F33D 281D 470A B443 6756 147C 07B3 C8BC 4083 E800