1
0
Fork 0
mirror of https://github.com/ItsDrike/dotfiles.git synced 2025-02-23 11:59:03 +00:00
dotfiles/home/.local/bin/scripts/gui/prompt/menuman
2022-11-20 03:15:56 +01:00

11 lines
243 B
Bash
Executable file

#!/bin/sh
# Menu prompt to easily search for a man page to open
page="$(apropos --long "$1" | menuprompt --choose -p "Pick man page" | awk '{print $2, $1}' | tr -d '()')"
if tty -s; then
man "$page"
else
$TERMINAL -e man "$page"
fi