Re: HEADS UP: change in ports rc.d script behaviour

From: Thomas-Martin Seck <tmseck-lists_at_netcologne.de>
Date: 25 Jul 2004 19:55:34 -0000
* Craig Rodrigues <rodrigc_at_crodrigues.org> [gmane.os.freebsd.current]:

> On Sun, Jul 25, 2004 at 05:12:08PM +0300, Mike Makonnen wrote:
>> 4. If you must include a default value for an rc.conf(5) knob,
>>    make sure that you put it in an if [ -z "$foo_knob"] clause.
> 
> As a simple alternative to an if clause, I've done this for the 
> isc-dhcp3-server port:
> 
> [ -z "$dhcpd_enable" ] && dhcpd_enable="NO"

Even simpler:

foo_enable=${foo_enable:-"NO"}

or

: ${foo_enable:="NO"}
Received on Sun Jul 25 2004 - 17:55:44 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:38:03 UTC