From: Frank Schwidom <schwidom@gmx.net>
To: Bart Schaefer <schaefer@brasslantern.com>
Cc: Frank Schwidom <schwidom@gmx.net>,
Mikael Magnusson <mikachu@gmail.com>,
Zsh Users <zsh-users@zsh.org>
Subject: Re: Hi, can someone help me to convert my bash PS1 to zsh?
Date: Mon, 21 Mar 2022 19:17:59 +0100 [thread overview]
Message-ID: <20220321181759.GC1727@debian64> (raw)
In-Reply-To: <CAH+w=7bSeHzUNnaKkb8xS21kMsTnjdfz=K4twJPJ8zpjfQZi2g@mail.gmail.com>
On 2022-03-21 11:11:59, Bart Schaefer wrote:
> On Mon, Mar 21, 2022 at 10:59 AM Frank Schwidom <schwidom@gmx.net> wrote:
> >
> > How can I create a newline in PS1?
>
> Just put an actual newline in it, zsh doesn't have a prompt "escape"
> for newline. This can be accomplished by replacing $'\\n' in your
> bash PS1 assignment with $'\n' in zsh.
>
> PS1=$'%F{green}%n@%m %D{%Y-%m-%d %H:%M:%S}:\n%F{yellow}%~\n%F{magenta}%#%f '
>
Thanks.
next prev parent reply other threads:[~2022-03-21 20:20 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-03-21 16:06 Frank Schwidom
2022-03-21 16:57 ` Mikael Magnusson
2022-03-21 17:47 ` Frank Schwidom
2022-03-21 17:59 ` Mikael Magnusson
2022-03-21 18:51 ` Roman Perepelitsa
2022-03-21 21:43 ` Bart Schaefer
2022-03-22 0:36 ` Frank Schwidom
2022-03-21 18:11 ` Bart Schaefer
2022-03-21 18:17 ` Frank Schwidom [this message]
2022-03-21 18:56 ` Lawrence Velázquez
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220321181759.GC1727@debian64 \
--to=schwidom@gmx.net \
--cc=mikachu@gmail.com \
--cc=schaefer@brasslantern.com \
--cc=zsh-users@zsh.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/zsh/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).