i use self written initscripts and i have in them status function which reports something to me. when i use it with new baselayout it only says: status ok it will be really nice to allow user (in this actualy initscript) overrride this so it calls function in script itself. alternative would be alowing other functions in scripts. if i rename it to ie stat() and call it returns unknown function `stat' (btw there is really typo in that first comma) Reproducible: Always Steps to Reproduce: use baselayout 2 and have some status() function in initscript Actual Results: * status: started Expected Results: really nice dump of stuff i really need
Can you give a functional example? I'm opposed to this unless there's some real benefit. How about rc-status? How do you expect that to work?
rc-status doesnt work the same way overriding the default status function is fine as the output is meant for humans to consume
(In reply to comment #2) > overriding the default status function is fine as the output is meant for > humans to consume What about the return value? A lot of 3rd party scripts do this if /etc/init.d/foo --quiet status; then $action_if_started else $action_if_stopped fi
that is why i referred to the output, not the exit status
Well aware that rc-status doesn't work the same. But let's say the proposal is the have Apache say "Serving # vhosts". Would you want rc-status to just say "started" or some shortened version there of. That was my question to the user what HE expected in his suggestion.
ok i put status function to my firewall just for testing. on old baselayout output looks like: root@hlukotvor: ~ # rc-status firewall [ started ] ... root@hlukotvor: ~ # /etc/init.d/firewall status * status: started ### /sbin/iptables -nvL ################################# Chain INPUT (policy DROP 4012 packets, 474K bytes) ... with baselayout2 and openrc: scarab@Ugly-Elf: ~ > s rc-status firewall [ started ] ... scarab@Ugly-Elf: ~ > s /etc/init.d/firewall status * status: started
so allow another functions into initscripts and i will use them unless that i need more info from some scripts than "status: started" really
Roy? Mike?
fixed in 0.4.3-r2, thanks
(In reply to comment #9) > fixed in 0.4.3-r2, thanks > I LOVE YOU :] (note this is not spam i am really happy and really sorry i had no time to do it myself)