Hi, Anthony Ettinger wrote: > I want to stick a path or filename and/or both if possible. > > Right now I get "1 BASH 2* BASH" > > would be nice to have which file I have open, just filename I guess.
For me, it's not completly clear what you want.
But just if I understood correctly...
I use zsh, and in my precmd function (that gets executed each
time before a prompt is drawn) I set my prompt to something that
contains "kzsh" (note: That is an escape character, then k,
then "zsh", then an escape character again). If I run inside
screen, this sets the current window title to zsh; if I run
outside screen, I see an extra "zsh" in my prompt...
(bash has the PROMPT_COMMAND that can be used for something like
this)
Then, in my preexec function (that gets executed each time before
a command is being executed) I check for $TERM=screen, and if it
matches I get the first word from the commandline (usually the
command without the arguments) and echo -e -n "\033k$word\033".
That way, I see the current command in screen's title (that is
displayed in the hardstatus line).
I'd expect you could adapt bash's PROMPT_COMMAND to be something
like "echo 'k' $PWD ''" or similar. Unfortunately, bash hangs
when I try something like that. Something seems to be wrong with
my version of bash...
Ciao,
Thomas
--
Thomas Köhler Email: [EMAIL PROTECTED]
<>< WWW: http://gott-gehabt.de
IRC: tkoehler
PGP public key available from Homepage!
signature.asc
Description: Digital signature
_______________________________________________ screen-users mailing list [email protected] http://lists.gnu.org/mailman/listinfo/screen-users
