Sergiy Seletskyy
Sergiy Seletskyy

Reputation: 17110

When using zeus in zsh cursor position shifts after the the termination of zeus command

Sometimes there is a strange issue with terminal cursor in zsh when zeus command was terminated. The position of cursor shifts and each line of the output in the console has extra indentation, e.g.

           services GET        /services(.:format)                                services#index
                         payments GET        /payments(.:format)                                payments#index
                                        orders_verify POST       /orders_verify(.:format)                           orders_verify#index
                                                        orders GET        /orders(.:format)                                  orders#index
        diets GET        /diets(.:format)                                   diets#index

The only way to fix that is to open a new terminal window/tab

Upvotes: 3

Views: 150

Answers (2)

Thomas Dickey
Thomas Dickey

Reputation: 54505

Staircasing is unrelated to locale. Full-screen programs manipulate the terminal-mode settings to let them read single characters from the screen as well as send special characters (such as carriage return and line-feed) to the screen without having the terminal driver "translate" them.

The quick fix — run this command:

reset

(you may have to press controlJ after typing "reset" to enter this properly)

Further reading:

Upvotes: 3

Sergiy Seletskyy
Sergiy Seletskyy

Reputation: 17110

Make sure you have set LOCALE environment vars to UTF-8 in your .zshrc file

  1. Open .zshrc

    vim ~/.zshrc
    
  2. Add these lines

    export LC_ALL=en_US.UTF-8
    
    export LANG=en_US.UTF-8
    
  3. Close the file (Shift-ZZ) and reload it in the current session (or open a new terminal window/tab)

    . ~/.zshrc
    

Upvotes: 0

Related Questions