ref: 7ae78bc3363349f6af9b93e43dec67259467fdc9
parent: 810e423e40326ed30bb8ce06e86b6b54925e6310
author: phil9 <[email protected]>
date: Wed Dec 22 06:46:33 EST 2021
change keyword behaviour to handle man pages When pressing K, VIM will run: '!<keywordprg> <keyword> There is special handling for the case when keywordprg=man which works well on linux where there is manpager. As this will not work on plan9, we do not prepend ! to keywordprg if it starts with a colon (e.g. :Man).
--- a/normal.c
+++ b/normal.c
@@ -5424,7 +5424,8 @@
if (cap->count0 != 0 && !(isman || isman_s))
sprintf((char *)buf, ".,.+%ld", cap->count0 - 1);
- STRCAT(buf, "! ");
+ if(kp[0] != ':')
+ STRCAT(buf, "! ");
if (cap->count0 == 0 && isman_s)
STRCAT(buf, "man");
else