aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormoxie <moxie@3kgcat.fi>2026-03-16 02:59:48 +0200
committermoxie <moxie@3kgcat.fi>2026-03-16 02:59:48 +0200
commit0d5557b5185916913f08215eb7d987d25d3e09e0 (patch)
treeedc1177c667d85c4c8be3026a44070dc7fce947d
parentc566653a645c8317f336043117766745304b7887 (diff)
feat: add xdg-open dependency check
-rw-r--r--doc/muwiki.txt2
-rw-r--r--doc/tags2
-rw-r--r--lua/muwiki/health.lua10
3 files changed, 12 insertions, 2 deletions
diff --git a/doc/muwiki.txt b/doc/muwiki.txt
index 02d6ced..26faa65 100644
--- a/doc/muwiki.txt
+++ b/doc/muwiki.txt
@@ -229,7 +229,7 @@ Open with menu example~ *muwiki-au
})
<
-Custom open handler using get_link()~ *muwiki-autocmd-custom-open*
+Custom open handler using get_link()~ *muwiki-autocmd-open-custom*
>
vim.api.nvim_create_autocmd("FileType", {
pattern = "markdown",
diff --git a/doc/tags b/doc/tags
index e7e777a..5f52c12 100644
--- a/doc/tags
+++ b/doc/tags
@@ -1,7 +1,7 @@
muwiki muwiki.txt /*muwiki*
muwiki-api muwiki.txt /*muwiki-api*
muwiki-autocmd muwiki.txt /*muwiki-autocmd*
-muwiki-autocmd-custom-open muwiki.txt /*muwiki-autocmd-custom-open*
+muwiki-autocmd-open-custom muwiki.txt /*muwiki-autocmd-open-custom*
muwiki-autocmd-mkdir muwiki.txt /*muwiki-autocmd-mkdir*
muwiki-autocmd-open-with muwiki.txt /*muwiki-autocmd-open-with*
muwiki-autocmd-template muwiki.txt /*muwiki-autocmd-template*
diff --git a/lua/muwiki/health.lua b/lua/muwiki/health.lua
index fc1c9db..118c1fe 100644
--- a/lua/muwiki/health.lua
+++ b/lua/muwiki/health.lua
@@ -43,6 +43,16 @@ M.check = function()
vim.health.info('Install with: :TSInstall markdown_inline')
vim.health.info('Link detection requires both parsers')
end
+
+ vim.health.start('External Dependencies')
+
+ if vim.fn.executable('xdg-open') == 1 then
+ vim.health.ok('xdg-open is installed')
+ else
+ vim.health.warn('xdg-open is not installed')
+ vim.health.info('xdg-open is required for web and file links')
+ vim.health.info('Alternative: Configure custom handlers - see :help muwiki-autocmd-open-custom')
+ end
end
return M