0

I currently have:

man () { emacs -nw --eval "(man \"$1\")"; }

in my .zshrc. However, this has the problem of not working with something like read(2) or command-line arguments to man. The same problem exists in eshell for something like read(2) not working. However, M-x man RET read(2) RET works. Any suggestions?

4
  • What is the point of this? If you want the man page, just run man on the command line. If you want emacs, just open emacs. In any case, I doubt this is emacs-related: it looks more like a quoting problem in zsh and so more appropriate for Unix & Linux SE perhaps.
    – NickD
    Apr 25, 2023 at 2:33
  • I want the man page to display within emacs if I run man from the command-line. Apr 25, 2023 at 3:36
  • Then at least, run a server and use emacsclient for that: starting a full session of Emacs just to display a manual page is rather wasteful.
    – NickD
    Apr 25, 2023 at 3:56
  • You're probably right, and I'm considering switching to emacsclient but don't really see the purpose for me since it takes imperceivable time for emacs to launch for me (literally instantly) and I configured my eshell so that emacs aliases for find-file. I don't know what else I'd need it for except performance, which I have. Apr 25, 2023 at 4:06

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.