zsh-workers
 help / color / mirror / code / Atom feed
From: Casper Gripenberg <casper.gripenberg@kotiportti.fi>
To: zsh-workers@sunsite.dk
Subject: Strange escape codes in prompt
Date: Tue, 23 Sep 2008 01:47:28 +0300	[thread overview]
Message-ID: <48D82080.4000508@kotiportti.fi> (raw)


Hi. I've long been wondering why I from time to time see
a spurious "%" on my line before the prompt. Normally this
% character is not visible, but sometimes when I suspend
a program or fg a program it pops up on a line. It
always seemed a bit weird.

So I completely reset my prompt from all colorization
and geeky extra-info:

PS1="PROMPT: "

And then I took a look at the raw output of zsh, expecting
to see nothing but a newline and "PROMPT: " being outputted.

But this is what I got:

^[[1m[4m[7m%[m[1m[4m[0m[4m[0m[m[m[JPROMPT:

Each '[' being prefixed by an escape. And lo..there is
the mysterios "%" embedded into that sequence.

Now my question is where do all these escapes come from?
Is that normal and/or necessary? What do they do?

Even if I did
TERM=dumb
..the mysterious % still remained in the output.

Running zsh 4.3.4 on Ubuntu 8.04.

Thx.

Casper





             reply	other threads:[~2008-09-22 22:48 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-09-22 22:47 Casper Gripenberg [this message]
2008-09-23  8:44 ` Peter Stephenson

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=48D82080.4000508@kotiportti.fi \
    --to=casper.gripenberg@kotiportti.fi \
    --cc=zsh-workers@sunsite.dk \
    /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).