diff options
Diffstat (limited to '.local/bin/open_man')
| -rwxr-xr-x | .local/bin/open_man | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/.local/bin/open_man b/.local/bin/open_man index b37d94b..778a479 100755 --- a/.local/bin/open_man +++ b/.local/bin/open_man @@ -2,12 +2,7 @@ MENU_CMD=dmenu "$@" -if [ "$XDG_SESSION_TYPE" = "wayland" ]; then - MENU_CMD=bemenu "$@" - TERM=$TERM -d none -else - MENU_CMD=dmenu "$@" -fi +[ "$XDG_SESSION_TYPE" = "wayland" ] && MENU_CMD=bemenu "$@" cachedir=${XDG_CACHE_HOME:-"$HOME/.cache"} if [ -d "$cachedir" ]; then @@ -18,6 +13,8 @@ else # if no xdg dir, fall back to dotfiles in ~ historyfile=$HOME/.dmenu_man_history fi +#FONT="DejaVuSansMono Nerd Font Mono:pixelsize=16:antialias=true:autohint=true:style=book" + # Generate a new cache if necessary if stest -dqr -n "$cache" /usr/share/man/**/*; then ls /usr/share/man/**/* \ @@ -60,7 +57,6 @@ awk -v histfile=$historyfile ' | while read MAN; do VERSION=$(echo $MAN | sed -Ee 's/.* \(([0-9].*)\)/\1/g') PAGE=$(echo $MAN | sed -Ee 's/(.*) \([0-9].*\)/\1/g') - ## Uncomment for debugging #echo "Man: $VERSION $PAGE" $TERM man $VERSION $PAGE done |
