zsh-workers
 help / color / mirror / code / Atom feed
* PATCH: Fix quoting in `redhat' prompt
@ 2012-02-13 19:57 Frank Terbeck
  2012-02-14  0:08 ` Phil Pennock
  0 siblings, 1 reply; 3+ messages in thread
From: Frank Terbeck @ 2012-02-13 19:57 UTC (permalink / raw)
  To: zsh-workers

Someone on IRC just noted, that when he's using the `redhat' prompt from
zsh, that he's getting a "\$" prompt-mark instead of the "$" he was
expecting. Turns out, that the quoting is a bit off (unless of course,
the redhat prompt is *supposed* to look like that, which I can't quite
believe).

Regards, Frank


diff --git a/Functions/Prompts/prompt_redhat_setup b/Functions/Prompts/prompt_redhat_setup
index 5bde7f9..e2b38d4 100644
--- a/Functions/Prompts/prompt_redhat_setup
+++ b/Functions/Prompts/prompt_redhat_setup
@@ -3,7 +3,7 @@
 # Styled like the default prompt in Red Hat 5.1
 #
 prompt_redhat_setup () {
-  PS1="[%n@%m %1~]\\$ "
+  PS1='[%n@%m %1~]$ '
   PS2="> "
 
   prompt_opts=( cr percent )


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: PATCH: Fix quoting in `redhat' prompt
  2012-02-13 19:57 PATCH: Fix quoting in `redhat' prompt Frank Terbeck
@ 2012-02-14  0:08 ` Phil Pennock
  2012-02-14  5:23   ` Wayne Davison
  0 siblings, 1 reply; 3+ messages in thread
From: Phil Pennock @ 2012-02-14  0:08 UTC (permalink / raw)
  To: Frank Terbeck; +Cc: zsh-workers

On 2012-02-13 at 20:57 +0100, Frank Terbeck wrote:
> Someone on IRC just noted, that when he's using the `redhat' prompt from
> zsh, that he's getting a "\$" prompt-mark instead of the "$" he was
> expecting. Turns out, that the quoting is a bit off (unless of course,
> the redhat prompt is *supposed* to look like that, which I can't quite
> believe).

The Centos prompt uses '$'/'#', per normal Bash convention.  I assume
that this matches RedHat.

> +  PS1='[%n@%m %1~]$ '

I suggest:
  PS1='[%n@%m %1~]%(#.#.$) '

-- 
https://twitter.com/syscomet


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: PATCH: Fix quoting in `redhat' prompt
  2012-02-14  0:08 ` Phil Pennock
@ 2012-02-14  5:23   ` Wayne Davison
  0 siblings, 0 replies; 3+ messages in thread
From: Wayne Davison @ 2012-02-14  5:23 UTC (permalink / raw)
  To: Frank Terbeck, zsh-workers

[-- Attachment #1: Type: text/plain, Size: 232 bytes --]

On Mon, Feb 13, 2012 at 4:08 PM, Phil Pennock <
zsh-workers+phil.pennock@spodhuis.org> wrote:

>  PS1='[%n@%m %1~]%(#.#.$) '
>

Yeah, that's what the \$ idiom does in bash (renders as $ or #).  I've
committed that tweak.

..wayne..

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2012-02-14  5:23 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-02-13 19:57 PATCH: Fix quoting in `redhat' prompt Frank Terbeck
2012-02-14  0:08 ` Phil Pennock
2012-02-14  5:23   ` Wayne Davison

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).