Im accessing a remote computer using ssh and running a bash command to input symbols using standard input stream:
read test;echo $test
It's ok to input english letters and use backspace to delete them, then input other characters and iterate this steps any amount of times. But it becomes a disaster when I use other utf-8 symbols, like russian ones, which require 2 bytes instead of 1, as english ones do. E.g., I input:
абвгдежз
After that, I use backspace for 8 times, and input other symbols:
привет
And press Enter key. But instead of the result which would equal my last input, I get the following:
абвгпривет
Which means that 8 backspace deleted only 4 symbols.
I do use linux ubuntu 12.04. Tried different consoles: standard one, terminator; different types of backspace options (as ASCII-del or Ctrl+H); setting $LC_TYPE to ru_RU.UTF-8, but nothing works. There is no such a problem using local console. Thank you in advance.
update: I've also got a video of this issue, please watch it at youtube