Open maver1ck opened 5 years ago
How do you start your shell?
Task is default:
exec zsh
from within bash and then enabling oh-my-zsh plugins.
.zshrc
export ZSH="/home/maverick/.oh-my-zsh"
ZSH_THEME="agnoster"
ENABLE_CORRECTION="true"
COMPLETION_WAITING_DOTS="true"
plugins=(git git-extras pip python aws common-aliases debian docker kubectl zsh-autosuggestions)
source $ZSH/oh-my-zsh.sh
Way to reproduce it in my env: 1) Run new shell 2) cat bigger file (for example .bashrc) 3) use up arrow to find longer command 4) backspace will be messed up
Task is default
Please don't cut down words. "Default" to you is unclear and ambiguous to me
Hi,
i have the same issue. It works fine in normal bash mode and zsh mode in wsl ubuntu.
if i use conemu with wsl with bash and then start profile it to zsh enviroment its ok in the beginning. When the directory is a git project with long directory names and i press "backspace". A new line is opened instead of deleting the characters.
But zsh environment is running correctly with normal ubuntu wsl shell without conemu. I think it has to with the shell size in conemu maybe. I dont know.
But..
i want to use conemu, i think it is the best emulator i tried! ;-)
thanks in advance, prophess
Hi,
i have the same issue. It works fine in normal bash mode and zsh mode in wsl ubuntu.
if i use conemu with wsl with bash and then start profile it to zsh enviroment its ok in the beginning. When the directory is a git project with long directory names and i press "backspace". A new line is opened instead of deleting the characters.
But zsh environment is running correctly with normal ubuntu wsl shell without conemu. I think it has to with the shell size in conemu maybe. I dont know.
But..
i want to use conemu, i think it is the best emulator i tried! ;-)
thanks in advance, prophess
Found a issue with the linesize, if i set it to 80 i dont have the problems. if i add more than 80 or do fullscreen i have the same problem described above.
Hi, i have the same issue. It works fine in normal bash mode and zsh mode in wsl ubuntu. if i use conemu with wsl with bash and then start profile it to zsh enviroment its ok in the beginning. When the directory is a git project with long directory names and i press "backspace". A new line is opened instead of deleting the characters. But zsh environment is running correctly with normal ubuntu wsl shell without conemu. I think it has to with the shell size in conemu maybe. I dont know. But.. i want to use conemu, i think it is the best emulator i tried! ;-) thanks in advance, prophess
Found a issue with the linesize, if i set it to 80 i dont have the problems. if i add more than 80 or do fullscreen i have the same problem described above.
Ok first i thought linesize, but know i think the problem is the tab key, with autocompletion in zsh. if i switch to the git directory with normal cd, i had no problems. If i use tab, problem with backspace exists. Have to check zsh with tab completion
Ok i fixed my environment, it was a problem with my .zsh_profile. conemu works great.
What's the fix ?
I'm also interested in the fix for this, I've gone over my zsh config and don't see any issues
I fixed it on my side by switching font that I used to Literation Mono Powerline from Consolas. Hope that helps
I have this problem as well. Here's how my task is configured:
set MSYSTEM=MINGW64 & set "PATH=D:\MSYS2\usr\bin;%PATH%" & %ConEmuBaseDirShort%\conemu-msys2-64.exe /usr/bin/zsh --login -i
and I also use oh-my-zsh, here's relevant parts from .zshrc:
POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=(status time)
COMPLETION_WAITING_DOTS="true"
DISABLE_UNTRACKED_FILES_DIRTY="true"
ZSH_THEME="powerlevel9k/powerlevel9k"
plugins=(git zsh-syntax-highlighting)
I should also add that it only actually screws up with something pasted or with something in my history that is kind of long
That's not accurate, sorry. I just made it happen by typing berks
and using my arrow keys to scroll through history matching berks, finding the first one, and pressing backspace. The line was just berks update foodb
, so quite short. I'm running latest oh-my-zsh and latest plugins as well, and pacman -Syuu
is fully up to date.
@prophess It'd be great if you could come back and document your fix
@prophess It'd be great if you could come back and document your fix
Hi, i dont remember it :( i switched to hyper, for me it was a little bit faster in some cases. please try to fix the .zsh_profile, maybe there was a bug.. sorry.
best regards, prophess
I had this same issue and (for now) my fix was to uncheck "Compress long strings to fit space" under the font settings in the General section. I hope this helps.
I had this same issue but the solutions above are not working, I tried for multiple times, and found some other strange issues that may be helpful to the final solution.
I lanuched the WSL with wsl:bash, but since I'm using WSL2, the command actually being executed is:
set "PATH=%ConEmuBaseDirShort%\wsl;%PATH%" & wsl.exe -cur_console:pm:/mnt
When typing too long and cause the problem happened, extending the width causes the terminal sometimes to print a newline, or showing in original line, with a character deleted, hit backspace multiple times will have the right amount of characters deleted, so it's should just be something wrong in the visualization.
A too long text (It just happens if the input string is too long
Before resizing:
After resizing:
Also, the maximum length that cmder works without wrong is actually determined by the total length of segment and the text input.
This maybe involve some length calculation of special characters of powerline font, since I found that cd into a git direcory will made the length decrease, what I think should be constant before.
The two text both cause the bug happened, but the length is different, the lower one accepts the same text like the upper one without bug.
Resizing the width to a smaller one is being complex and behaves different in different situations.
If the width is able to include the text in one line, it works just like what happened if the width is extended:
but if the width causes the text was broken into two lines, the line will be print again like above, but the problem will not appear if you delete the characters of new line, the problem was delayed until returning to the first line, making the cursor stopped.
If resize the window width below the valve length, the problem will not happen.
As far as I can figure out, this problem may involve how zsh and the cmder process the text and cache, but since I have little knowledge of this field, I can't produce a clear solution, hope this comment will produce some useful information.
I also have this problem. All mentioned fixes above are not working.
Running ConEmu 191012
, (latest alpha as of writing) on Microsoft Windows [Version 10.0.19041.208]
Have same problem, ConEmu 191012, bash on remote server over ssh running from WSL debian.
set "PATH=%ConEmuBaseDirShort%\wsl;%PATH%" & %ConEmuBaseDirShort%\conemu-cyg-64.exe --wsl --distro-guid={GUID} -C~ -cur_console:pm:/mnt
Something I'm noticing is that we all seem to have ZSH_THEME="powerlevel9k/powerlevel9k"
. I can make this happen reliably:
If I type a 5 and then backspace, it will ALWAYS go to a new line - even if I copy-paste the whole string.
Things I have tried to no effect:
POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=()
to disable the right prompt elementsDISABLE_MAGIC_FUNCTIONS=true
COMPLETION_WAITING_DOTS=true
Here is my .zshrc, if it helps:
export ZSH="/home/keith/.oh-my-zsh"
POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=(dir_writable dir vcs)
POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=()
ZSH_THEME="powerlevel9k/powerlevel9k"
DISABLE_MAGIC_FUNCTIONS=true
COMPLETION_WAITING_DOTS="true"
DISABLE_UNTRACKED_FILES_DIRTY="true"
plugins=(git zsh-syntax-highlighting)
source $ZSH/oh-my-zsh.sh
My task command looks like this (I'm SSHing to a virtual machine):
set MSYSTEM=MINGW64 & set "PATH=D:\MSYS2\usr\bin;%PATH%" & %ConEmuBaseDirShort%\conemu-msys2-64.exe ssh keith@keith-p920-gentoo
This only seems to happen if my scrollback buffer (set to 32766) is full. I see that #1960 is a similar issue, and the suggestion there was to uncheck "Inject ConEmuHk" under Features. This seems to fix my problem, even with a full scrollback buffer.
Hopefully that's enough information to reproduce it yourself :)
uncheck "Inject ConEmuHk" under Features. This seems to fix my problem, even with a full scrollback buffer.
Confirm! Disable "Inject ConEmuHk" (Settings -> Featurs -> In-console options) fix problem in my case!
I have to unconfirm. Unchecking Inject ConEmuHk
did not resolve my issue :(
@Dyllaann That checkbox won't affect any currently open tabs; you have to open a new one for it to take effect. Are you saying that unchecking that doesn't resolve it on a new tab?
Yep! Even tried restarting the whole program. Unfortunately still no success :(. I can reproduce it easily and the behaviour is exactly the same after unchecking the option and making new tab (or new Cmder instance).
And I can now confirm that disabling ConEmuHk does not work, either.... and I'm able to reproduce it on line 188 of my scrollback, rather than the end.
This is very, very strange.
Is there any update on this? Any information that I can provide?
It is still happening on 200713 alpha
and it's extremely annoying to work with.
Besides jumping to a new line, sometimes the console gets stuck and doesnt allow any input or output.
There are too many notes in this issue. Hard to track.
To resume:
Correct?
To answer most of your questions:
Microsoft Windows [Version 10.0.19041.330
. Running Ubuntu 18.04.4LTS on WSL2wsl.exe ~ -cur_console:p1:t:"Ubuntu"
zsh
, (or any other shell in specific), as the normal wsl window works reliable, but yes, the backspace behaves strangeTo add something; I'm not sure if this is fully similar, but sometimes general output gets cut off, causing the terminal to get stuck. I will post a screenshot of what this looks like as soon as it will happen again. For example, when SSH'ing into a machine, it will print some default output like system load, disk usage, memory usage etc. Halfway during this print, it will randomly stop and the console will freeze. Forcing me to shut down this terminal, open up a new one and attempt again.
As you don't use connector, the -cur_console:p1
it's not required and may cause bad things.
Generally, when you run wsl.exe such wear, ConEmu doesn't process ANSI, all things are done by conhost. And that means all bugs comes from conhost too.
Is there any way where I can let ConEmu process the ANSI too then?
Connector+wslbridge, but this was broken by WSL2.
Well, some users report in gh-1930 that wslbridge2 is working, but I'm not going to include it in ConEmu. My goal is to get rid of wslbridge completely.
As for me, running wsl.exe
in ConEmu without bridge or -cur_console:p1
should work for now.
This does it for me in MSYS2 zsh, MSYS2 SSH with a remote Bash, and MSYS2 SSH with a remote zsh. Unchecking ConEmuHk doesn't fix it for me.
For msys2 shells you should use connector
For me, the fix was Settings -> Startup -> Tasks -> {bash::ubuntu} and change the big edit box to say %windir%\system32\bash.exe ~
Removing the cur_console:p did the trick.
uncheck "Inject ConEmuHk" under Features. This seems to fix my problem, even with a full scrollback buffer.
Confirm! Disable "Inject ConEmuHk" (Settings -> Featurs -> In-console options) fix problem in my case!
This solved my issue as well.
After doing some tests with the new windows terminal, installing the new terminal and setting it as the default terminal might be a better fix. Just make sure you explicitly dedicate either the integrated or discrete in the windows setting and not let windows automatically choose.
Just confirming that the problem still exists, and that I could remove it by disabling "Inject ConEmuHk" (Settings -> Features -> In-console options).
My startup task: "wsl.exe" --cd "/home/alelom/repos"
.
I can confirm this problem exists. Deleting characters creates new lines and you are unable to see where exactly you're typing - pretty much renders nano unusable. I will test the step above from @alelom and see if it works.
Had the same issue (windows, conemu (in cmder), WSL2). Disabling ConEmuHk and opening a new console fixed the issue for me
Versions
ConEmu build: 19.03.10 x64 OS version: Windows Version 10.0.17763 Build 17763 x64 Used shell version (Far Manager, git-bash, cmd, powershell, cygwin, whatever): Ubuntu 18.04 + bash + zsh + oh-my-zsh
Problem description
Backspace key is moving cursor to newline when the line is too long
Everything working correctly on standard terminal (bash.exe)
Steps to reproduce
Actual results
Before backspace![image](https://user-images.githubusercontent.com/4006010/54761884-45b2e980-4bf3-11e9-99ae-8cae5b93c7d3.png)
After backspace![image](https://user-images.githubusercontent.com/4006010/54761924-57948c80-4bf3-11e9-9758-dbcb98b4d50d.png)
Expected results
Chars are removed. No cursor in new line