summaryrefslogtreecommitdiffstats
path: root/pkgs/applications/editors/kakoune
diff options
context:
space:
mode:
authorDaniel Gorin <jcpetruzza@gmail.com>2020-10-18 16:19:09 +0100
committerDaniel Gorin <jcpetruzza@gmail.com>2020-11-01 14:35:49 +0000
commit464804b43f6e414d4a6eadcf220a43040640cc34 (patch)
tree5fd5a39d58c282696bd532295a980f096166b8d9 /pkgs/applications/editors/kakoune
parent550389392a54a81e750aabb54b69a77c9e5d18af (diff)
kakoune: Fix :doc when using plugins
So, kakoune takes the documentation shown for `:doc` from `$KAKOUNE_RUNTIME/share/kak/doc`. Unfortunately, it seems that it will ignore files that are symlinks. This is arguably a bug in kakoune, we workaround it for now by copying the content of the docfiles.
Diffstat (limited to 'pkgs/applications/editors/kakoune')
-rw-r--r--pkgs/applications/editors/kakoune/wrapper.nix7
1 files changed, 7 insertions, 0 deletions
diff --git a/pkgs/applications/editors/kakoune/wrapper.nix b/pkgs/applications/editors/kakoune/wrapper.nix
index 6d6e23f1dac9..7ac56d9cb1e0 100644
--- a/pkgs/applications/editors/kakoune/wrapper.nix
+++ b/pkgs/applications/editors/kakoune/wrapper.nix
@@ -18,6 +18,13 @@ in
# unless explicitly overriden with KAKOUNE_RUNTIME
rm "$out/bin/kak"
makeWrapper "${kakoune}/bin/kak" "$out/bin/kak" --set KAKOUNE_RUNTIME "$out/share/kak"
+
+ # currently kakoune ignores doc files if they are symlinks, so workaround by
+ # copying doc files over, so they become regular files...
+ mkdir "$out/DELETE_ME"
+ mv "$out/share/kak/doc" "$out/DELETE_ME"
+ cp -r --dereference "$out/DELETE_ME/doc" "$out/share/kak"
+ rm -Rf "$out/DELETE_ME"
'';
meta = kakoune.meta // { priority = (kakoune.meta.priority or 0) - 1; };