Shell rcorder not finding requirement

I am attempting to use rcorder to give me a list of files to run but when I try to use rcorder to find the file and requirements, I cannot get the results I want.

That is to say, when I issue something like:
Code:
rcorder /path/to/files/foo.sh

I was expecting (hoping for) a list back such as (-i.e. have the rcorder tool FIND the requirements):
Code:
foo.sh
bar.sh

I have the following (simplified, of course):
Code:
#!/bin/sh

# PROVIDE: foo
# REQUIRE: bar

        echo "I am foo"

Code:
#!/bin/sh

# PROVIDE: bar
# REQUIRE:

        echo "I am bar"

I have read the manual and tried a slew of different things all to no avail (checked my spelling, checked syntax, tried -k, etc). I haven't looked through the rcorder code yet, but does anyone know if this is beyond the scope of rcorder (-i.e. does it need a list of files as in 'rcorder foo.sh bar.sh' and only provide a list based on that argument, or can it locate a requirement without the argument and I am setting it up/calling it wrong)?
 
-i.e. does it need a list of files as in 'rcorder foo.sh bar.sh' and only provide a list based on that argument
It needs a list of files. Then it'll try to figure out what the order of those files should be.

rcorder /etc/rc.d/* /usr/local/etc/rc.d/*

(Remember that the shell parses the wildcard and passes the result as arguments to the command, it's not the command that parses the wildcard)
 
I was expecting (hoping for) a list back such as (-i.e. have the rcorder tool FIND the requirements):

foo.sh
bar.sh

I have the following (simplified, of course):
Code:
#!/bin/sh
# PROVIDE: foo
# REQUIRE: bar 

       echo "I am foo"

Code:
#!/bin/sh
# PROVIDE: bar
# REQUIRE: 

         echo "I am bar"

What you should have expected as output is:
Code:
 [1-0] % rcorder foo.sh bar.sh
bar.sh
foo.sh
[2-0] %

7. Connecting a script to the rc.d framework :
Rich (BB code):
#!/bin/sh

# PROVIDE: mumbled oldmumble (1)
# REQUIRE: DAEMON cleanvar frotz (2)
# BEFORE:  LOGIN  (3)
# KEYWORD: nojail shutdown  (4)
   [...]
(2) (3) So our script indicates which "conditions" provided by other scripts it depends on. According to the lines, our script asks rcorder(8) to put it after the script(s) providing DAEMON and cleanvar, but before that providing LOGIN.

How to Integrate Shell Scripts into the RC Framework might also be helpful.
 
Back
Top