Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 2462 - Patch for runscript.sh to enable status() function in rc scripts
Summary: Patch for runscript.sh to enable status() function in rc scripts
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: x86 All
: High enhancement (vote)
Assignee: Martin Schlemmer (RETIRED)
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 4222
  Show dependency tree
 
Reported: 2002-05-05 06:49 UTC by Todd Wright
Modified: 2003-02-04 19:42 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments
context diff of /sbin/runscript.sh (runscript.sh.diff,937 bytes, patch)
2002-05-05 07:05 UTC, Todd Wright
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Todd Wright 2002-05-05 06:49:58 UTC
The attached small diff file adds a proper status() function to runscripts.sh 
which contains the core code which drives the /etc/init.d/* rc scripts

This allows anyone to code a status() function in their rc script which can 
display status information specific to the application in addition to the 
simple "started/stopped" status that is displayed currently.

To see this in operation, apply the patch to /sbin/runscripts.sh and then 
execute '/etc/init.d/autofs status' - assuming you have autofs installed. The 
autofs rc script already contains a status() function, but unfortunatly it is 
bypassed by the existing runscripts.sh

The runscript.sh file is in sys-apps/baselayout

I am hoping to also provide a patch which will create suse-like rc symlinks 
in /usr/sbin to make manipulating services easier
Comment 1 Todd Wright 2002-05-05 07:05:35 UTC
Created attachment 828 [details, diff]
context diff of /sbin/runscript.sh
Comment 2 Martin Schlemmer (RETIRED) gentoo-dev 2002-09-29 08:02:40 UTC
Added something to this extend to CVS.