Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 30 Jun 2020 15:21:06 +0200
From:      Per Hedeland <per@hedeland.org>
To:        Polytropon <freebsd@edvax.de>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: Shell
Message-ID:  <f19cef57-9bce-828c-fe24-63a96842bb52@hedeland.org>
In-Reply-To: <20200630143913.e27eb3e3.freebsd@edvax.de>
References:  <CY4PR19MB010400AC4940C67421BFADE8F96E0@CY4PR19MB0104.namprd19.prod.outlook.com> <DB8PR06MB6442289C119C69BDF4303E72F66F0@DB8PR06MB6442.eurprd06.prod.outlook.com> <20200630104317.812dce86b2dc5ea5a42a1ee1@sohara.org> <a590654c-ffa2-3171-ce44-ae3f33214b14@hedeland.org> <20200630143913.e27eb3e3.freebsd@edvax.de>

next in thread | previous in thread | raw e-mail | index | archive | help
On 2020-06-30 14:39, Polytropon wrote:
> On Tue, 30 Jun 2020 13:27:58 +0200, Per Hedeland wrote:
>> On 2020-06-30 11:43, Steve O'Hara-Smith wrote:
>>> On Tue, 30 Jun 2020 14:44:34 +0530
>>> Manish Jain <bourne.identity@hotmail.com> wrote:
>>>
>>>> It is often unnoticed that FreeBSD has a mirror of the root user
>>>> appropriately named toor (whose shell can be anything).
>>>
>>> 	Traditionally root ran /bin/csh and toor ran /bin/sh to keep both
>>> BSD and AT&T trained sysadmins happy, it really doesn't matter what login
>>> shell root uses at work we use zsh, at home I use bash but you could even
>>> use mc or vshnu.
>>>
>>> 	However the OP was concerned about the prompt (which many people
>>> have correctly said involves setting PS1) rather than the shell.
>>
>> Yes, PS1 is what to set for /bin/sh and its relatives (e.g. bash,
>> zsh), but it has no effect for csh/tcsh - there you need to set
>> 'prompt' (and the "formatting sequences" are also different). And it
>> seems the OP was primarily interested in root's prompt (i.e. csh by
>> default).
>
> The first message says that the prompt character is $, which would
> not be the case (per default) if the C shell was chosen; so the
> case probably is related to "shell changed from C shell to sh",
> rather than "the dog ate my configuration files". ;-)

This was definitely not my impression of the OP's *problem* - in
particular, the first message
https://lists.freebsd.org/pipermail/freebsd-questions/2020-June/290424.html
says "When I am logged in as root it is #, even when I do not execute
a shell. Usually it was root@machine17#. How do I change it back?",
and
https://lists.freebsd.org/pipermail/freebsd-questions/2020-June/290428.html
says "I don't want to change the prompt for the usr, just for the csh
shell for root".

--Per



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?f19cef57-9bce-828c-fe24-63a96842bb52>