Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 22 Feb 2016 13:07:28 +1100
From:      Yudi V <yudi.tux@gmail.com>
To:        Polytropon <freebsd@edvax.de>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: minimize use of root account
Message-ID:  <CACo--msQEWmwq4ARwr2XxFrvFwVZ%2Ba-0rdxw8ugVrkREhRbeSg@mail.gmail.com>
In-Reply-To: <20160219120503.fc97ef10.freebsd@edvax.de>
References:  <CACo--mv9qU2ZwtTuZRQBpioEr%2BenT=sd-SJ79BFumZt5aL18jg@mail.gmail.com> <20160219120503.fc97ef10.freebsd@edvax.de>

next in thread | previous in thread | raw e-mail | index | archive | help
Thanks Polytropon.

based on the answers here looks like the best answer is to use SUDO or
SUPER.

> ###############
> > #!/bin/csh -f
>
> Why?!
>
> There's a relevant article: "Csh Programming Considered Harmful" written
> by Tom Christiansen.
>
> https://www-uxsup.csx.cam.ac.uk/misc/csh.html
>
> I have written one (!) csh script and I still regret it, maybe because
> it still works. :-)
>
> On FreeBSD, the default shell script interpreter is /bin/sh.
>
>
> I am fairly new to Freebsd and I checked the shell variable before I wrote
the script and as it said CSH, I just went with the csh script. I did not
get why the user shell is /bin/sh and the root is /bin/csh.
This is on a personal backup server and only has few scripts. I dont want
to readup on yet another shell scripting (someone in the forum mentioned
that /bin/sh is Almquist's Shell NOT bash). for the few scripts I run on
this server, I am just happy if they work as intended. If the server was
meant for anything else I will definitely not use csh scripts.


-- 
Kind regards,
Yudi



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CACo--msQEWmwq4ARwr2XxFrvFwVZ%2Ba-0rdxw8ugVrkREhRbeSg>