From: Joerg Jaspert Date: Fri, 15 Aug 2014 12:23:51 +0000 (+0200) Subject: Fix mc subshell X-Git-Url: https://git.ganneff.de//index.cgi?p=zsh.git;a=commitdiff_plain;h=427769d093f32e3510cc6bc7413588fe9aad7c5c Fix mc subshell --- diff --git a/.zsh/80_KeyBindings.zsh b/.zsh/80_KeyBindings.zsh index f5d5742..46f2743 100644 --- a/.zsh/80_KeyBindings.zsh +++ b/.zsh/80_KeyBindings.zsh @@ -94,7 +94,13 @@ do zle -N ${widget} done -accept-line +# control+j: add new-line for multi-line edits in zle (needs exception for midnight commander) +if [[ "$MC_SID" != "" || "$MC_CONTROL_PID" != "" ]]; then + bindkey "^J" accept-line +else + bindkey "^J" self-insert + accept-line +fi bind2maps emacs -- Home beginning-of-somewhere bind2maps viins vicmd -- Home vi-beginning-of-line