-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy patheman
More file actions
executable file
·27 lines (23 loc) · 820 Bytes
/
Copy patheman
File metadata and controls
executable file
·27 lines (23 loc) · 820 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/bin/bash
source $(dirname "${BASH_SOURCE[0]}")/.abash/abash.sh
MAN=/usr/bin/man
export GROFF_NO_SGR=1
[ $# -gt 0 ] || exec $MAN
istty || exec $MAN "$@"
$MAN -w "$@" > /dev/null || exit $?
exec emacs --eval "
(progn
(man \"$*\")
(delete-window)
(local-set-key (kbd \"q\") 'save-buffers-kill-emacs)
(local-set-key (kbd \"/\") 'isearch-forward)
(local-set-key (kbd \",\") 'isearch-repeat-backward)
(local-set-key (kbd \".\") 'isearch-repeat-forward)
(local-set-key (kbd \"<down>\") 'scroll-up-line)
(local-set-key (kbd \"<up>\") 'scroll-down-line)
(local-unset-key [?\r])
(setq lazy-highlight-buffer t)
(setq lazy-highlight-cleanup nil)
(setq line-timer (run-with-timer 0 0.001 'display-line-numbers-update))
(run-with-timer 1 nil 'cancel-timer line-timer)
)"