Date: Mon, 3 Jan 2005 20:41:21 -0600 (CST) From: Scott Bennett <bennett@cs.niu.edu> To: freebsd-questions@freebsd.org Cc: lists@tntluoma.com Subject: Re: my lame attempt at a shell script... Message-ID: <200501040241.j042fLo0014499@mp.cs.niu.edu>
next in thread | raw e-mail | index | archive | help
On Mon, 3 Jan 2005 16:22:45 -0500 Timothy Luoma <lists@tntluoma.com>
wrote:
>On Jan 3, 2005, at 3:49 PM, Eric F Crist wrote:
>
>> First off, let me thank you very much for the massive amount of
>> information you've given me thus far.
>
>I am a commandline geek from way back, so you're welcome.
>
>My brother actually had a Dilbert from years ago that he gave me where
>Dilbert runs into a guy with a long beard and suspenders and says "Hey,
>you're one of those Unix geeks, aren't you?"
>
>I wish I could get that on a T-Shirt!
>
>Anyway, the sourcing idea is definitely a good one. I'm not usually
>working with such easy source material (I do a lot of stuff where I'm
>pulling information off a website, etc)
>
>> Do me a favor and tell me if
>> this syntax is correct:
>>
>> #!/bin/sh
>>
>> . /etc/rc.conf
>>
>> if [ "$grog_firewall_enable" = "YES" ]
>> then
>> echo "Firewall enabled."
>> elif [ "$grog_firewall_enable" = "NO" ]
>> then
>> echo "Firewall disabled."
>> fi
>>
>> exit 0
>
>yes, that's right
>
[remainder deleted --SB]
It has been many years, but it seems to me that, under 4.3BSD, the echo
commands shown above would have been verboten in /etc/rc or any scripts run
by it because none of those processes had a /dev/tty associated with them.
Has this limitation been bypassed in FreeBSD somehow?
Scott Bennett, Comm. ASMELG, CFIAG
**********************************************************************
* Internet: bennett at cs.niu.edu *
*--------------------------------------------------------------------*
* "A well regulated and disciplined militia, is at all times a good *
* objection to the introduction of that bane of all free governments *
* -- a standing army." *
* -- Gov. John Hancock, New York Journal, 28 January 1790 *
**********************************************************************
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200501040241.j042fLo0014499>
