lucc / nvimpager

Use nvim as a pager to view manpages, diffs, etc with nvim's syntax highlighting
Other
395 stars 21 forks source link

R help displayed incorrectly #88

Open ghost opened 1 year ago

ghost commented 1 year ago
❯ PAGER=nvimpager R
>?file

image

❯ PAGER=moar R
>?file

image

lucc commented 1 year ago

It looks like R calls its own pager which then calls $PAGER (or is that a NixOS thing / I am on NixOS). Can you confirm this? This kind of messes up our parent process detection because we only look at the parent process of nvimpager and not its parent process(es). Is there any way to detect the pager R uses?

ghost commented 1 year ago

It looks like R calls its own pager which then calls $PAGER (or is that a NixOS thing / I am on NixOS). Can you confirm this?

How do I check that out?

I have no idea how you did find that out. Except some gdb/strace or other black magic.

lucc commented 1 year ago

I was looking at the pstree/htop while nvimpager was running from R.

PS: That is also what nvimpager does to detect its parent process. This works for man, git, python, perldoc and ruby.