[4758] in RedHat Linux List
shell scripting questions
daemon@ATHENA.MIT.EDU (tom mills)
Sun Nov 17 05:17:10 1996
Date: Sun, 17 Nov 1996 03:13:59 -0700
From: tom mills <tmills@dimensional.com>
Reply-To: tmills@dimensional.com
To: redhat-list@redhat.com
Resent-From: redhat-list@redhat.com
Sorry, not a 'redhat' specific question,
But it is my OS of choice! i486dx4-100 running Colgate, all upgrades in
place without a hitch.
I'm trying to modify the /usr/sbin/adduser script to input a delimited
file of user info, in one clean shot... But I really don't know much
about scripting.
Basically I have assigned "" to the $NOHOME variable, cause it doesn't
do anything in the default script, and am using a command line arg as
$PASS to hand the password to autopasswd so i don't have to! So what I
have is a command line like: adduser bsmith @nudRUsr!
I keep a database of the initial account stuff in.... MSAccess, only
cause my boss makes me, but I thought why enter this stuff twice? I can
put it in there and export myself a delimited file that contains:
login:password:home:realname and be done with it if I could just figure
out how to tell a shell script how to read lines out of a file and parse
them in. Is this what that "readline" thing is?
The parsing I'm getting from the awk man pages, but I could really use
some examples from some of you regarding a script reading a disk file,
if anyone does anything like this. I'm also trying to figure out a
script or actual code that would match ss#'s in a student database file
and allow users to add themselves.
A little guidance please oh great guru's!
thx
--------------------------------------------------------------------
Tom Mills System Administrator
tmills@dimensional.com ccd.cccoes.edu
Community College of Denver
--------------------------------------------------------------------
--
PLEASE read the Red Hat FAQ, Tips, Errata and the MAILING LIST ARCHIVES!
________________________________________________________________________
http://www.redhat.com/RedHat-FAQ http://www.redhat.com/RedHat-Errata
http://www.redhat.com/RedHat-Tips http://www.redhat.com/mailing-lists
------------------------------------------------------------------------
To unsubscribe: mail -s unsubscribe redhat-list-request@redhat.com < /dev/null