initial commit
This commit is contained in:
17
src/sh/awk.sh
Normal file
17
src/sh/awk.sh
Normal file
@@ -0,0 +1,17 @@
|
||||
if [ ! "${AWK_LOADED:-}" ]; then
|
||||
AWK_LASTMESSAGEINTHREAD=$(
|
||||
cat <<'EOF'
|
||||
@@include awk/lastmessageinthread.awk
|
||||
EOF
|
||||
)
|
||||
export AWK_LASTMESSAGEINTHREAD
|
||||
|
||||
AWK_THREADOVERVIEW=$(
|
||||
cat <<'EOF'
|
||||
@@include awk/threadoverview.awk
|
||||
EOF
|
||||
)
|
||||
export AWK_THREADOVERVIEW
|
||||
|
||||
export AWK_LOADED=1
|
||||
fi
|
||||
11
src/sh/info.sh
Normal file
11
src/sh/info.sh
Normal file
@@ -0,0 +1,11 @@
|
||||
# Application information
|
||||
if [ ! "${INFO_LOADED:-}" ]; then
|
||||
APP_NAME="nmf"
|
||||
APP_VERSION="0.1"
|
||||
APP_WEBSITE="https://git.indyfac.ch/amin/not-much-fuzz/"
|
||||
WINDOW_TITLE="📨 $APP_NAME | not much fuzz"
|
||||
export APP_NAME APP_VERSION APP_WEBSITE WINDOW_TITLE
|
||||
|
||||
export INFO_LOADED=1
|
||||
fi
|
||||
|
||||
13
src/sh/theme.sh
Normal file
13
src/sh/theme.sh
Normal file
@@ -0,0 +1,13 @@
|
||||
# Default theme
|
||||
if [ ! "${THEME_LOADED:-}" ]; then
|
||||
COLDATE="$(printf '\033[38;5;195m')"
|
||||
COLCNTS="$(printf '\033[38;5;244m')"
|
||||
COLFROM="$(printf '\033[38;5;208m')"
|
||||
COLSUBJ="$(printf '\033[38;5;179m\033[3m')"
|
||||
COLTAGS="$(printf '\033[38;5;106m\033[2m')"
|
||||
RESET="$(printf '\033[0m')"
|
||||
|
||||
export COLDATE COLCNTS COLFROM COLSUBJ COLTAGS
|
||||
|
||||
export THEME_LOADED=1
|
||||
fi
|
||||
28
src/sh/tools.sh
Normal file
28
src/sh/tools.sh
Normal file
@@ -0,0 +1,28 @@
|
||||
if [ ! "${TOOLS_LOADED:-}" ]; then
|
||||
if command -v "fzf" >/dev/null; then
|
||||
FZF="fzf --black --ansi --cycle --tiebreak=chunk,index"
|
||||
else
|
||||
err "Did not find the command-line fuzzy finder fzf."
|
||||
exit 1
|
||||
fi
|
||||
export FZF
|
||||
|
||||
if command -v "notmuch" >/dev/null; then
|
||||
NOTMUCH="notmuch"
|
||||
else
|
||||
err "Did not find the command-line email system notmuch."
|
||||
exit 1
|
||||
fi
|
||||
export NOTMUCH
|
||||
|
||||
if command -v "bat" >/dev/null; then
|
||||
CAT="bat"
|
||||
elif command -v "batcat" >/dev/null; then
|
||||
CAT="batcat"
|
||||
fi
|
||||
CAT=${CAT:+$CAT -l email --style=plain --color=always --wrap}
|
||||
CAT=${CAT:-cat}
|
||||
export CAT
|
||||
|
||||
export TOOLS_LOADED=1
|
||||
fi
|
||||
Reference in New Issue
Block a user