Update after.sh

This commit is contained in:
Baltrust 2026-10-03 07:28:00 +03:00
parent e9a863f9cd
commit 133610b00d

View file

@ -112,7 +112,20 @@ setopt HIST_IGNORE_SPACE
# Manual to pdf
# ─────────────────────────────────────
manual() { man -Tpdf "$1" | okular -; }
manual() {
local pdf
pdf=$(mktemp --suffix=.pdf) || return 1
if ! man -Tpdf "$1" > "$pdf" 2>/dev/null; then
rm -f "$pdf"
echo "No manual entry for $1"
return 1
fi
okular "$pdf"
rm -f "$pdf"
}
EOF
# Make everything we created belong to the user