misc/quitcd/quitcd.bash | 5 +++++ misc/quitcd/quitcd.csh | 5 +++++ misc/quitcd/quitcd.fish | 5 +++++ misc/quitcd/quitcd.zsh | 5 +++++ diff --git a/misc/quitcd/quitcd.bash b/misc/quitcd/quitcd.bash index 95939a009929cd60c4b9de74a4dabe4b55c233c4..70498cbf709f6527550d05ad88700247641220c9 100644 --- a/misc/quitcd/quitcd.bash +++ b/misc/quitcd/quitcd.bash @@ -6,6 +6,11 @@ echo "nnn is already running" return fi + # Unmask ^Q (, ^V etc.) (if required, see `stty -a`) to Quit nnn + # stty start undef + # stty stop undef + # stty lwrap undef + # The default behaviour is to cd on quit (nnn checks if NNN_TMPFILE is set) # To cd on quit only on ^G, export NNN_TMPFILE after the call to nnn export NNN_TMPFILE=${XDG_CONFIG_HOME:-$HOME/.config}/nnn/.lastd diff --git a/misc/quitcd/quitcd.csh b/misc/quitcd/quitcd.csh index b9db423c1e503818d3bfa4a5f337e7d8d06471bb..9806cefb6b41e872ccacf32c86034460f82d7588 100644 --- a/misc/quitcd/quitcd.csh +++ b/misc/quitcd/quitcd.csh @@ -4,4 +4,9 @@ # The default behaviour is to cd on quit (nnn checks if NNN_TMPFILE is set) # To cd on quit only on ^G, export NNN_TMPFILE after the call to nnn set NNN_TMPFILE=~/.config/nnn/.lastd +# Unmask ^Q (, ^V etc.) (if required, see `stty -a`) to Quit nnn +# stty start undef +# stty stop undef +# stty lwrap undef + alias n 'nnn -fis; source "$NNN_TMPFILE"; rm -f "$NNN_TMPFILE"' diff --git a/misc/quitcd/quitcd.fish b/misc/quitcd/quitcd.fish index 12fccedb4617dd260a43dadd40a6087369ae79c1..3053656ab3ce71d7ef1eff5da833df84749f2fb1 100644 --- a/misc/quitcd/quitcd.fish +++ b/misc/quitcd/quitcd.fish @@ -17,6 +17,11 @@ else set -x NNN_TMPFILE "$HOME/.config/nnn/.lastd" end + # Unmask ^Q (, ^V etc.) (if required, see `stty -a`) to Quit nnn + # stty start undef + # stty stop undef + # stty lwrap undef + nnn $argv if test -e $NNN_TMPFILE diff --git a/misc/quitcd/quitcd.zsh b/misc/quitcd/quitcd.zsh index 20a613f93a7c9aeaadf2c86a6ac4947a3cfd1b15..57f0fcf331f6b6c1ec8f47134f42eb600c5fe629 100644 --- a/misc/quitcd/quitcd.zsh +++ b/misc/quitcd/quitcd.zsh @@ -10,6 +10,11 @@ # The default behaviour is to cd on quit (nnn checks if NNN_TMPFILE is set) # To cd on quit only on ^G, export NNN_TMPFILE after the call to nnn export NNN_TMPFILE=${XDG_CONFIG_HOME:-$HOME/.config}/nnn/.lastd + # Unmask ^Q (, ^V etc.) (if required, see `stty -a`) to Quit nnn + # stty start undef + # stty stop undef + # stty lwrap undef + nnn "$@" if [ -f $NNN_TMPFILE ]; then