On Mon, Aug 28, 2006 at 02:44:24AM +0200, Axel Liljencrantz wrote:
> >i figured that i should be able to do the same inside the function:
> >function fish_title
> >  echo -ne '\033ksometitle\033\\'
> >end
> function fish_title
>  echo sometitle
> end
> should work.

no, that will change the xterm title,
i want to change the screen title inside the xterm.
for that the above escapes need to be used for screen to pick them up.

the problem is that fish takes the fish_title output
and wraps it in the escapes needed for the xterm.

so this helps:
function fish_title
  echo -ne '\007\033k'$_'\033\\\033]0;'
end

for some reason this produces a beep though (the beep is the end of the
sequence so it should be caught and not make a noise.)

> To get the name of the job currently being
> executed, you can use the $_ variable.

ah, thanks.

> Because backslash escapes are disabled in quoted strings. This may
> seem backwards, but it's not if you think about it. The role of quotes
> in shells is to _disable_ most types of string transformations. Why
> should backslash escapes be any different?

true. that makes sense.
btw, i find that whereever i need to expand a variable i can just do:
"foo"$var"baz"
which makes variable interpolation in strings unnecessary, or is there a
case where this would not work?

greetings, martin.
-- 
cooperative communication with sTeam      -     caudium, pike, roxen and unix
offering: programming, training and administration   -  anywhere in the world
--
pike programmer   travelling and working in europe             open-steam.org
unix system-      bahai.or.at                        iaeste.(tuwien.ac|or).at
administrator     (caudium|gotpike).org                          is.schon.org
Martin Bähr       http://www.iaeste.or.at/~mbaehr/

-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Fish-users mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/fish-users

Reply via email to