From a4d2744f08b192842226863a097f4bb676fcf007 Mon Sep 17 00:00:00 2001 From: Simon Let Date: Tue, 30 Jun 2020 15:56:26 +0200 Subject: [PATCH] Revert "Only turn on keybindings once per session" This reverts commit cf8a7df70b70123cd0b5bf917e7a3a51155932eb. --- scripts/shellrc.sh | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/scripts/shellrc.sh b/scripts/shellrc.sh index fa9728a..7b55f9b 100644 --- a/scripts/shellrc.sh +++ b/scripts/shellrc.sh @@ -79,6 +79,14 @@ if [ -z "${__RESH_SESSION_ID+x}" ]; then # TODO add sesson time __resh_reset_variables __resh_session_init +fi + +# block for anything we only want to do once per shell +if [ -z "${__RESH_INIT_DONE+x}" ]; then + preexec_functions+=(__resh_preexec) + precmd_functions+=(__resh_precmd) + + __resh_reset_variables if [ "$__RESH_SHELL" = bash ] ; then [ "$(resh-config --key BindArrowKeysBash)" = true ] && __resh_bind_arrows @@ -89,14 +97,6 @@ if [ -z "${__RESH_SESSION_ID+x}" ]; then echo "$__RESH_SHELL" fi [ "$(resh-config --key BindControlR)" = true ] && __resh_bind_control_R -fi - -# block for anything we only want to do once per shell -if [ -z "${__RESH_INIT_DONE+x}" ]; then - preexec_functions+=(__resh_preexec) - precmd_functions+=(__resh_precmd) - - __resh_reset_variables __RESH_INIT_DONE=1 fi