mirror of
https://gitlab.com/dwt1/dotfiles.git
synced 2026-04-22 11:00:27 +10:00
Setting function for using Emacs as manpager.
This commit is contained in:
3
.bashrc
3
.bashrc
@@ -152,7 +152,8 @@ IFS=$SAVEIFS
|
||||
# Function for using Emacs as our manpage reader.
|
||||
# Use :q to quit out of Emacs and return to the shell.
|
||||
macsman() {
|
||||
emacsclient -nw -e "(let ((Man-notify-method 'bully)) (man \"$1\") (define-key Man-mode-map \"q\" 'save-buffers-kill-emacs))"
|
||||
# emacsclient -nw -e "(man \"$1\")"
|
||||
emacsclient -nw -e "(let ((Man-notify-method 'bully)) (man \"$1\"))"
|
||||
}
|
||||
|
||||
# navigation
|
||||
|
||||
@@ -136,6 +136,13 @@ function org-search -d "send a search string to org-mode"
|
||||
printf $output
|
||||
end
|
||||
|
||||
# Function for using Emacs as our manpage reader.
|
||||
# Use :q to quit out of Emacs and return to the shell.
|
||||
function macsman
|
||||
# emacsclient -nw -e "(man \"$argv\")"
|
||||
emacsclient -nw -e "(let ((Man-notify-method 'bully)) (man \"$argv\"))"
|
||||
end
|
||||
|
||||
### END OF FUNCTIONS ###
|
||||
|
||||
|
||||
|
||||
3
.zshrc
3
.zshrc
@@ -133,7 +133,8 @@ IFS=$SAVEIFS
|
||||
# Function for using Emacs as our manpage reader.
|
||||
# Use :q to quit out of Emacs and return to the shell.
|
||||
macsman() {
|
||||
emacsclient -nw -e "(let ((Man-notify-method 'bully)) (man \"$1\") (define-key Man-mode-map \"q\" 'save-buffers-kill-emacs))"
|
||||
# emacsclient -nw -e "(man \"$1\")"
|
||||
emacsclient -nw -e "(let ((Man-notify-method 'bully)) (man \"$1\"))"
|
||||
}
|
||||
|
||||
# navigation
|
||||
|
||||
Reference in New Issue
Block a user