You are not logged in.
Hi,
Two questions:
1) I use zsh. How can I set the title of urxvt to be my current directory?
2) I'm having an issue in urxvt wih backspacing/deleting/end-of-line/beginning-of-line. What are the proper bindkey's for that?
Offline
Here's straight from my ~/.zshrc file
# This sets the window title to the last run command.
[[ -t 1 ]] || return
case $TERM in
*xterm*|rxvt|(dt|k|E|a)term)
preexec () {
print -Pn "\e]2;$1\a"
}
;;
screen*)
preexec () {
print -Pn "\e\"$1\e\134"
}
;;
esac
# Setting HOME and END keys
case $TERM in (xterm*|aterm|rxvt)
bindkey '\e[H' beginning-of-line
bindkey '\e[F' end-of-line ;;
esac
The preexec codes actually print out my last command.
So, in order for it to do what you want, you would need to change:
case $TERM in
*xterm*|rxvt|(dt|k|E|a)term)
preexec () {
print -Pn "\e]2;$1\a"
}
to:
case $TERM in
*xterm*|rxvt|(dt|k|E|a)term)
preexec () {
print -Pn "\e]2;%~\a"
}
That should do it for ya.
Last edited by Knute (2009-09-06 00:57:18)
Knute
Offline