screen-users
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

truncated PWD on the hardstatus line?


From: P Kapat
Subject: truncated PWD on the hardstatus line?
Date: Wed, 18 Feb 2009 21:34:43 -0500

Hi,

I am trying to setup my .screenrc. I am able to display the $PWD on
the hardstatus line using:

PS1="\[\e]0;\w\a\]$PS1"

in my .bashrc, and

hardstatus string '%{= Ck}%H:%L>%{= dd} %h'

in my .screenrc. But for long directory names, I wanted to truncate
the first part of the directory string to "...". I was trying to use
the PROMPT_COMMAND in .bashrc to do the actual truncation and use that
variable (say, newPWD)  instead of '\w' in the PS1 string above:
"\[\e]0;$newPWD\a\]$PS1"

Of course this doesn't work. Also, I couldn't quite understand the %L
or %> or %< string sequences for screen. So, is it possible?

Kindly CC me when replying, I am not subscribed to the list.
-- 
Regards
PK
--------------------------------------
http://counter.li.org  #402424




reply via email to

[Prev in Thread] Current Thread [Next in Thread]