Article:
  Start Me Up: Writing and Understanding OS X StartupItems
Subject:   "RunService" not available on Mac OS 10.1
Date:   2004-02-04 14:21:06
From:   smithkennedy
Response to: RunService


I would also like to add that the "RunService" shell script function is not implemented in rc.common on Mac OS 10.1.x, so if you do need to support that version of Mac OS X, you should keep this in mind. You can do a test to see if RunService is in /etc/rc.common, and switch on that, like so:




FOUND_RUN_SERVICE=`grep -c RunService /etc/rc.common`


if [ ${FOUND_RUN_SERVICE} -a ${FOUND_RUN_SERVICE} -eq 1 ]; then
RunService $1
else
StartService
fi



Also, make sure your property list file is the old NeXT-style instead of the newer XML .plist file format(s). SystemStarter will crash if it hits one of these newer .plist files.