From: Samuel Karl Peterson <skpeterson@nospam.please.ucdavis.edu>
To: help-gnu-emacs@gnu.org
Subject: ~/.emacs_bash setting PS1
Date: Mon, 04 Feb 2008 17:41:09 -0800 [thread overview]
Message-ID: <o368x20w56y.fsf@pc14.cs.ucdavis.edu> (raw)
I set my PS1 prompt so that it highlights the hostname portion of my
PS1 string. I use different colors on different hosts so I have a
better visual cue as to which host I'm actually logged into (had some
mishaps in the past with running the wrong command on the wrong
machine). It looks like this:
export PS1="[\u@\[\033[1;35m\]\h\[\033[0m\] \W]$ "
Unfortunately, in Emacs shell-mode, this doesn't show up correctly. I
don't need for it to work in shell-mode. The info manual says that
shell-mode reads the file ~/.emacs_SHELL depending on the shell used
(I use bash). However, placing the above line into the ~/.emacs_bash
file doesn't seem to work. Oddly enough, I can type 'exit' and then
I'll have a shell with the proper PS1 variable set.
Anyone have any advice for me?
--
Sam Peterson
skpeterson At nospam ucdavis.edu
"if programmers were paid to remove code instead of adding it,
software would be much better" -- unknown
next reply other threads:[~2008-02-05 1:41 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-02-05 1:41 Samuel Karl Peterson [this message]
2008-02-05 9:09 ` ~/.emacs_bash setting PS1 Sven Joachim
2008-02-05 15:44 ` Samuel Karl Peterson
2008-02-05 9:25 ` Peter Dyballa
2008-02-05 10:27 ` Ehud Karni
2008-02-06 15:05 ` Stefan Monnier
2008-02-06 17:32 ` Samuel Karl Peterson
2008-02-08 2:57 ` Stefan Monnier
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=o368x20w56y.fsf@pc14.cs.ucdavis.edu \
--to=skpeterson@nospam.please.ucdavis.edu \
--cc=help-gnu-emacs@gnu.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.
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 read-only IMAP folder(s) and NNTP newsgroup(s).