From 12c77cfe006922838dab71ba72520bbe2d7ff99b Mon Sep 17 00:00:00 2001 From: Davide Depau Date: Mon, 9 Sep 2019 01:55:42 +0200 Subject: [PATCH] Add explicit configuration options --- shcrt | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/shcrt b/shcrt index 50d59da..3be1150 100755 --- a/shcrt +++ b/shcrt @@ -1,7 +1,22 @@ #!/bin/bash +############ Script config ############# +## GUI mode +# +# Console based: +# dialog - ncurses, runs fine on WSL +# none - works everywhere +# +# GUI based: +# yad, gtkdialog, kdialog, Xdialog - GNU/Linux only +# zenity - Windows port available, doesn't work very well because Microsoft is a little bitch and +# argument passing between Linux and Windows doesn't work well. export supermode="dialog" +## Emojis - auto, yes, no +export emojis="auto" +########### /Script config ############# + function is_wsl { grep -q Microsoft /proc/version return $? @@ -21,6 +36,8 @@ while [ -h "$SOURCE" ]; do # resolve $SOURCE until the file is no longer a symli done DIR="$( cd -P "$( dirname "$SOURCE" )" >/dev/null 2>&1 && pwd )" +export supertitle="shcrt" + export SHELL_LIBRARY_PATH="$SHELL_LIBRARY_PATH:$DIR/easybashgui/lib" export PATH="$PATH:$DIR/easybashgui/src" source easybashgui @@ -62,7 +79,7 @@ function scrt_session_path { fi } -if is_wsl; then +if [[ "$emojis" == "no" ]] || ([[ "$emojis" != "yes" ]] && is_wsl); then dir_char="+" file_char=" " search_entry="> Search"