You are not logged in.
I'm using Arch with Openbox.
Compton as composite manager, ẅith the open source Xf86-video-ati driver,
URxvt as terminal emulator (with the perl extension collection, more specifically tabbedex,default,keyboard-select,url-select,clipboard,matcher)
and zsh with Oh-My-Zsh as shell.
Recently switched to Arch from Ubuntu, and I'm loving it. But as the topic says, I'm getting some strange behaviors while using URxvt. If I type a command into the terminal, using tab-completetion as i usually do, and then delete some character or press tab again, in about 50% of the cases some characters from the previous command remain on the command line. Also, if I type in for example 'sudo tail -f /var/log', and delete the entire line, the 'S' letter will persistantly remain after my prompt, making the next command 'ssudo'. Other times, the '/' might remain stuck from the '/var/log' part, as shown in the screenshot.
Tried my best to reproduce the problem for a screenshot, so see the image below, the two upmost terminals for an example of what it usually looks like.
Could anybody help me out finding out the cause of this problem? Is it related to zsh, urxvt or the graphics driver?
Offline
Does it happen without Oh-my-zsh? It is likely your prompt (with incorrect or missing escapes) or you are exporting your term.
Offline
Does it happen without Oh-my-zsh? It is likely your prompt (with incorrect or missing escapes) or you are exporting your term.
How would I check the prompt for missing escapes? Haven't tried not using Oh-My-Zsh, would rather fix it if that's the problem.
My current prompt/Oh-My-Zsh-theme:
PROMPT='[%{$fg_bold[white]%}%n%{$reset_color%}@%{$fg_bold[red]%}%m%{$reset_color%} %{$fg[cyan]%}%c%{$reset_color%} $(git_prompt_info)%{$reset_color%}]$ '
ZSH_THEME_GIT_PROMPT_PREFIX="(%{$fg_bold[green]%}"
ZSH_THEME_GIT_PROMPT_SUFFIX=")"
ZSH_THEME_GIT_PROMPT_DIRTY="%{$fg[green]%} %{$fg[yellow]%}✗%{$reset_color%}"
ZSH_THEME_GIT_PROMPT_CLEAN="%{$reset_color%}"Thank you for your time ![]()
Last edited by heroinsunrise (2014-10-13 08:28:14)
Offline
The easiest way is to remove Oh-my-Zsh (which is a heap of bloated ****, IMO) and see if you can replicate the issue. Similarly with your prompt, comment out that one and test with a vanilla prompt.
Offline
From what you posted none of the color codes are escaped in that prompt - so that would seem to be the problem.
I'm not a zsh user, but in bash the color codes would need to be enclosed in \[ \] pairs:
PROMPT='[\[%{$fg_bold[white]%}\]%n\[%{$reset_color%}\]@\[%{$fg_bold[red]%}\]%m\[%{$reset_color%}\] \[%{$fg[cyan]%}\]%c\[%{$reset_color%}\] $(git_prompt_info)\[%{$reset_color%}\]]$ 'You'd probably need to do something with that git_prompt_info too, but I don't know what that is.
EDIT: I'm not seeing these \[ \] in any zsh examples I can find, so these maybe bash-specific - you'll need to check how to do this in zsh.
Last edited by Trilby (2014-10-13 11:57:53)
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
The easiest way is to remove Oh-my-Zsh (which is a heap of bloated ****, IMO) and see if you can replicate the issue. Similarly with your prompt, comment out that one and test with a vanilla prompt.
zsh -f - disabling oh-my-zsh - made the problem go away. I parsed the .zshrc file, and found it to be a setting that I'd kept in the process of moving to Arch (as you said, by the way.) - "export TERM=uxterm". Removed this line, and the problem was gone. Thank you for your help!
On another note, that of Oh-My-Zsh being bloated: Is there an alternative to this that you would recommend over OMZSH? I'm mainly after the tab completion features of it.
Offline
The only reasonably alternative is to write your own configuration. You can look at oh-my-zsh for ideas, though that might be hard to do as it is just so damn big. Look at other users' config files and pick and chose which settings you'd like to use, but only when you understand what those settings do.
Many users share their configs in various threads here; some even post links to them in their signatures. JWR uses zsh, I think, and has a dot-file repo around somewhere.
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
Zsh's tab completion is awesome out of the box. If you really want to use a framework, use grml. My approach is to start with vanilla and then add functionality in increments as you discover or need it, this way you learn how it works and what is important to you.
Having said that, as Trilby mentioned, my dots are in my signature...
Offline