From owner-freebsd-questions Sun May 28 6:47:35 2000 Delivered-To: freebsd-questions@freebsd.org Received: from mail.rdc1.va.home.com (ha1.rdc1.va.home.com [24.2.32.66]) by hub.freebsd.org (Postfix) with ESMTP id 8FD6637B7A1 for ; Sun, 28 May 2000 06:47:32 -0700 (PDT) (envelope-from jhb@FreeBSD.org) Received: from john.baldwin.cx ([24.6.244.187]) by mail.rdc1.va.home.com (InterMail vM.4.01.02.00 201-229-116) with ESMTP id <20000528134732.CURV22611.mail.rdc1.va.home.com@john.baldwin.cx>; Sun, 28 May 2000 06:47:32 -0700 Content-Length: 784 X-Mailer: XFMail 1.4.0 on FreeBSD X-Priority: 3 (Normal) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 8bit MIME-Version: 1.0 In-Reply-To: <8gqsgm$311u$1@bigeye.mips.inka.de> Date: Sun, 28 May 2000 09:47:31 -0400 (EDT) Organization: BSD, Inc. From: John Baldwin To: (Christian Weisgerber) Subject: Re: sh prompt Cc: freebsd-questions@FreeBSD.ORG Message-Id: <20000528134732.CURV22611.mail.rdc1.va.home.com@john.baldwin.cx> Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On 28-May-00 Christian Weisgerber wrote: > Duke Normandin wrote: > >> I have the following prompt in ~/.shrc: >> >> PS1="[$(tty | cut -c9-11)]:`whoami`.`hostname | sed 's/\..*//'`@"`pwd` You can get the prompt you want rather easily in tcsh using the following: set prompt='[%l]:%n.%m@%~\n%# ' set promptchats='$#' [ttyp6]:john.john@/usr/local $ cd [ttyp6]:john.john@~ $ > Basically, what you are trying to do is beyond the capabilities of > sh. Agreed, sh is more of a scripting shell than an interactive shell, but that is a matter of heavy personal opinion. -- John Baldwin -- http://www.FreeBSD.org/~jhb/ PGP Key: http://www.cslab.vt.edu/~jobaldwi/pgpkey.asc "Power Users Use the Power to Serve!" - http://www.FreeBSD.org/ To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message