[Initng] An improvement for runiscript

Ismael Luceno ismael.luceno at gmail.com
Wed Mar 7 03:05:09 CET 2007


Ismael Luceno escribió:
> I want to make runiscript more generic.
> 
> I'm thinking about moving the current code added by runiscript to a
> wrapper script.
> 
> That way we can do something like:
> 
> $ runiscript bash /path/to/the/script
> 
> And runscript should run something like
> $ /lib/initng/scripts/bash /path/to/the/script
> 
> That will ease adding support for other shells, and maybe some
> compatibility stuff, as it will only require writting a script :).
> 
> What do you think guys?
> 

Wrapper scripts will look like:

#!/bin/sh

eval "${COMMAND}() {
	echo \"ERROR: ${SERVICE} command ${COMMAND} not found.\"
	return 1
}"

export PATH="/lib/ibin:${PATH}"
source "${SERVICE_FILE}"

${COMMAND}

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: OpenPGP digital signature
Url : http://jw.dyndns.org/pipermail/initng/attachments/20070307/004f32a9/attachment.pgp 


More information about the Initng mailing list