about summary refs log tree commit diff
path: root/mless
diff options
context:
space:
mode:
authorLeah Neukirchen <leah@vuxu.org>2021-09-28 16:18:35 +0200
committerLeah Neukirchen <leah@vuxu.org>2021-09-28 16:18:35 +0200
commit958e3e08bd74e6bec3e5baee87041025fe59494d (patch)
tree28014e10bd6e89060eb279c23fa7b0accc269ebc /mless
parentfcd8428b729eb4047f467384b5f9be93ce1419a0 (diff)
downloadmblaze-958e3e08bd74e6bec3e5baee87041025fe59494d.tar.gz
mblaze-958e3e08bd74e6bec3e5baee87041025fe59494d.tar.xz
mblaze-958e3e08bd74e6bec3e5baee87041025fe59494d.zip
mless: prefer setting LESSKEYIN and .mlesskey
Fixes #215.
Diffstat (limited to 'mless')
-rwxr-xr-xmless8
1 files changed, 7 insertions, 1 deletions
diff --git a/mless b/mless
index 08ce513..ddead98 100755
--- a/mless
+++ b/mless
@@ -72,7 +72,13 @@ nl="
 "
 export MLESS_RAW=0
 export MLESS_HTML=0
-if [ -f "$MBLAZE/mless" ]; then
+if [ -f "$MBLAZE/mlesskey" ]; then
+	export LESSKEYIN="$MBLAZE/mlesskey"
+elif [ -f "$HOME/.mblaze/mlesskey" ]; then
+	export LESSKEYIN="$HOME/.mblaze/mlesskey"
+elif [ -f "$HOME/.mlesskey" ]; then
+	export LESSKEYIN="$HOME/.mlesskey"
+elif [ -f "$MBLAZE/mless" ]; then
 	export LESSKEY="$MBLAZE/mless"
 elif [ -f "$HOME/.mblaze/mless" ]; then
 	export LESSKEY="$HOME/.mblaze/mless"