From owner-freebsd-newbies Wed Sep 5 15:38: 9 2001 Delivered-To: freebsd-newbies@freebsd.org Received: from mailsrv.otenet.gr (mailsrv.otenet.gr [195.170.0.5]) by hub.freebsd.org (Postfix) with ESMTP id 5B62337B403 for ; Wed, 5 Sep 2001 15:38:02 -0700 (PDT) Received: from hades.hell.gr (patr530-a195.otenet.gr [212.205.215.195]) by mailsrv.otenet.gr (8.11.5/8.11.5) with ESMTP id f85Mbw719370; Thu, 6 Sep 2001 01:37:58 +0300 (EEST) Received: (from charon@localhost) by hades.hell.gr (8.11.6/8.11.6) id f85McBJ00917; Thu, 6 Sep 2001 01:38:11 +0300 (EEST) (envelope-from charon@labs.gr) Date: Thu, 6 Sep 2001 01:38:05 +0300 From: Giorgos Keramidas To: Soren Neigaard Cc: freebsd-newbies@FreeBSD.ORG Subject: Re: sh settings for users? Message-ID: <20010906013804.A638@hades.hell.gr> References: <682008978.20010904181012@e-box.dk> <20010905153310.C466@hades.hell.gr> <963828024.20010905212123@e-box.dk> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <963828024.20010905212123@e-box.dk>; from neigaard@e-box.dk on Wed, Sep 05, 2001 at 09:21:23PM +0200 X-PGP-Fingerprint: 3A 75 52 EB F1 58 56 0D - C5 B8 21 B6 1B 5E 4A C2 X-URL: http://students.ceid.upatras.gr/~keramida/index.html Sender: owner-freebsd-newbies@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org On Wed, Sep 05, 2001 at 09:21:23PM +0200, Soren Neigaard wrote: > Wednesday, September 05, 2001, 2:33:10 PM, Giorgos wrote: > > GK> > I use the standard sh shell. root can use the arrows to browse the > GK> > history, but other users cant. Can I make it so that all new users > GK> > have this feature, or shuld I make it so that all users share this > GK> > feature (whitch is best, and how is it done)? > GK> > GK> Put in your .shrc (or the user's that needs history): > GK> set -o emacs > > Huh? I don't want emacs!? Ho do I make it so that all new users have > history on arrow keys, and have autocompletion on the tab key? This is what happens when I reply to messages that have more than one question in them. Remind me not to fall in this bear-trap again... Your original mail had more than one question. It's unedited text is shown below. I chose to reply only to the question that I *did* know the answer at the time. Let's answer all of them, one at a time: > I use the standard sh shell. root can use the arrows to browse the > history, but other users cant. Can I make it so that all new users > have this feature, or shuld I make it so that all users share this > feature (whitch is best, and how is it done)? According to you, root can use the arrow keys in /bin/sh (the standard sh, as you call it) to browse through history entries. This is because his .shrc file contains: set -o emacs If you 'dont want emacs' as you very kindly pointed out, you can go read through the manpage of sh(1) to find out what this changes, and either use this or `set -o vi'. It's up to you to choose. BUT FIRST, read the manpage to understand what I'm talking about. *sigh* Yes, you can make it so that all users have this feature turned on by default. Edit the .shrc file in the HOME of the existing users and add this line. Then, edit /usr/share/skel/dot.shrc and add it there too. First read the manpage of adduser to find out what the files in /usr/share/skel are for. > Can I make autocompletion work in sh (either on tab, or with > duble-click on esc)? No you can't. Period. Install another, more featureful shell, to have autocompletion. > The reason I use sh, is that I don't want to get "bad" habbits with > more powerfull shells, since I'm working differet "old" Unix systems, > that dosn't have "powerfull" shells. Is this a bad excuse/idea? No, it's neither an excuse, nor an idea. It's a matter of taste. -giorgos PS: Next time you post, try to post *one* question in each message, please. PPS: Did you even try what I suggested? To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-newbies" in the body of the message