port load/unload

Nick Ludlam nick at macports.org
Sat Sep 18 16:30:20 PDT 2010


On 18 Sep 2010, at 21:31, Ryan Schmidt wrote:

> On Sep 18, 2010, at 14:01, Nick Ludlam wrote:
> 
>> I've just had a look at the startupitem declaration within portfiles, and I wondered whether it's worth changing the standard message to include more information. Currently, it reads:
>> 
>> ###########################################################
>> # A startup item has been generated that will aid in
>> # starting <port name> with launchd. It is disabled
>> # by default. Execute the following command to start it,
>> # and to cause it to launch at startup:
>> #
>> # sudo port load <port name>
>> ###########################################################
>> 
>> Now it doesn't explicitly mention that there is also an 'unload' which does as you'd expect. If we drill this home to users, then it'll save people from needing to remember about launchctl, and paths to the startup items themselves. The text could read something like:
>> 
>> ###########################################################
>> # You can run <port name> now, and configure it to start
>> # automatically during boot by executing the following
>> # command:
>> # 
>> # sudo port load <port name>
>> # 
>> # To stop <port name>, and prevent it from from starting
>> # automatically during boot, execute the following command:
>> #
>> # sudo port unload <port name>
>> ###########################################################
>> 
>> Thoughts?
> 
> Sure, the message could be expanded. A revised suggestion:
> 
> 
> ###########################################################
> # A launchd plist has been created to help you start and
> # stop the <port name> daemon. It is stopped by default.
> #
> # To start the <port name> daemon now and during every
> # subsequent system startup, run the following command:
> #
> # sudo port load <port name>
> #
> # To stop the <port name> daemon now and to prevent it
> # from from starting automatically during system startup,
> # run the following command:
> #
> # sudo port unload <port name>
> ###########################################################
> 
> 
> I feel adding "daemon" is important since a port might install both a client component and a server component, and the launchd plist would only apply to the server component.

Yeah that looks fine.  If this can be committed, I'll draw up a list of ports that have related (and subsequently redundant) ui_msg statements that we can remove




More information about the macports-dev mailing list