From owner-freebsd-questions@FreeBSD.ORG Fri Apr 25 01:10:46 2014 Return-Path: Delivered-To: questions@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1 with cipher ADH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 47E4343C for ; Fri, 25 Apr 2014 01:10:46 +0000 (UTC) Received: from mx01.qsc.de (mx01.qsc.de [213.148.129.14]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 0AF57173C for ; Fri, 25 Apr 2014 01:10:45 +0000 (UTC) Received: from r56.edvax.de (port-92-195-108-40.dynamic.qsc.de [92.195.108.40]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mx01.qsc.de (Postfix) with ESMTPS id 497073CD3E; Fri, 25 Apr 2014 03:10:35 +0200 (CEST) Received: from r56.edvax.de (localhost [127.0.0.1]) by r56.edvax.de (8.14.5/8.14.5) with SMTP id s3P19QNx004337; Fri, 25 Apr 2014 03:09:26 +0200 (CEST) (envelope-from freebsd@edvax.de) Date: Fri, 25 Apr 2014 03:09:25 +0200 From: Polytropon To: Fbsd8 Subject: Re: 10.0 set prompt for new users has problems Message-Id: <20140425030925.6b8913c0.freebsd@edvax.de> In-Reply-To: <5359B0B0.6060802@a1poweruser.com> References: <5359293C.20501@a1poweruser.com> <20140424200058.6c4c6cc8.freebsd@edvax.de> <5359B0B0.6060802@a1poweruser.com> Organization: EDVAX X-Mailer: Sylpheed 3.1.1 (GTK+ 2.24.5; i386-portbld-freebsd8.2) Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Cc: questions X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.17 Precedence: list Reply-To: Polytropon List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 25 Apr 2014 01:10:46 -0000 On Thu, 24 Apr 2014 20:47:44 -0400, Fbsd8 wrote: > Polytropon wrote: > > On Thu, 24 Apr 2014 11:09:48 -0400, Fbsd8 wrote: > >> 10.0 host and using pw command to adduser. > >> pw adduser test -c Test-user -m -g wheel -w yes > >> > >> original /etc/csh.cshrc and /usr/share/skel/dot.cshrc files > >> > >> When I log into user test the prompt is a single dollar sign. > > > > This is not the default prompt for the C shell. It > > looks like you're running sh or bash. Can you check? > > Try > > > > $ echo $SHELL > > > > to see what login shell has been defined. Maybe the pw > > command did not set csh as the login shell, and you're > > left with sh as default. > > > > All the users I created with the above pw command are sh shell. > Used vipw and see that the last field at end of the line is /bin/sh As I guessed, erm, concluded. :-) > >> Issuing the ll command i see .cshrc* > >> Why does this file end with an *? > > > > This is because the file has the executable attribute (+x) > > set. There are other "signifiers" for files and directories. > > Try the following > > > > % setenv LSCOLORS 'ExGxdxdxCxDxDxBxBxegeg' > > % ls -laFG .cshrc > > > > The colors will also reflect the "executable" attribute. > > > > Note that this file does _not_ have to be executable, so > > check /usr/share/skel if the file has _accidentally_ been > > chmod'ed with +x. When copying the content of the skel/ > > directory (or subtree), attributes will be kept. > > > > > This must be the new default in 10.0 because > ls -laFG /usr/share/skel shows dot.cshrc* and > ls -la /usr/share/skel shows dot.cshrc The -F option adds the '/', '*', '|', '@', '%' and '=' accordingly, see "man ls" for details. The -G option enables the colors as defined in $LSCOLORS (or default colors). Currently I'm not able to run a v10 system to check if those got new defaults... > >> I can edit the /usr/share/skel/dot.cshrc replacing the existing set > >> prompt with the new one, deluser test, adduser test, and still get > >> dollar sign for the prompt even though I see the wanted prompt statement > >> in user test home directory .cshrc* file. > > > > Add -s csh to your pw adduser command. > > > > pw adduser test -c Test-user -m -g wheel -s csh -w yes > Fixed the problem. Now the changes made to /usr/share/skel/dot.cshrc > take affect in the users added using that pw command. The aliases also > work now. This is to be exptected. :-) For existing users, you can use the chsh command to change the shell. -- Polytropon Magdeburg, Germany Happy FreeBSD user since 4.0 Andra moi ennepe, Mousa, ...