feat(cvs): snacks gitbrowse for personal gitea

This commit is contained in:
2025-09-09 17:21:48 +02:00
parent ae95eb1480
commit 77a32b9eef

View File

@@ -1,2 +1,23 @@
---@type LazySpec ---@type LazySpec
return {} return {
{
"folke/snacks.nvim",
optional = true,
--@type snacks.Config
opts = {
gitbrowse = {
remote_patterns = {
{ "^gitea@(.+):(.+)$", "https://%1/%2" },
},
url_patterns = {
["git.niverton.ovh"] = {
branch = "/src/branch/{branch}",
file = "/src/branch/{branch}/{file}#L{line_start}-L{line_end}",
permalink = "/src/commit/{commit}/{file}#L{line_start}-L{line_end}",
commit = "/commit/{commit}",
},
},
},
},
},
}