aboutsummaryrefslogtreecommitdiff
path: root/common/config/nvim/lua/plugins/navic.lua
diff options
context:
space:
mode:
authorsrdusr <trevorgray@srdusr.com>2025-09-24 04:19:28 +0200
committersrdusr <trevorgray@srdusr.com>2025-09-24 04:19:28 +0200
commite95332b121672abaf9fd02692d81869b1e46c02d (patch)
tree9dc0def690d7941b18783733045ba091112e9452 /common/config/nvim/lua/plugins/navic.lua
parent0f6cee92221dc517bd756083e260dd9373851b82 (diff)
parent7ed2303648bf83bb081d9bd863660ebf2344ce47 (diff)
downloaddotfiles-e95332b121672abaf9fd02692d81869b1e46c02d.tar.gz
dotfiles-e95332b121672abaf9fd02692d81869b1e46c02d.zip
Merge commit '7ed2303648bf83bb081d9bd863660ebf2344ce47'
Diffstat (limited to 'common/config/nvim/lua/plugins/navic.lua')
-rwxr-xr-x[-rw-r--r--]common/config/nvim/lua/plugins/navic.lua97
1 files changed, 49 insertions, 48 deletions
diff --git a/common/config/nvim/lua/plugins/navic.lua b/common/config/nvim/lua/plugins/navic.lua
index a95485d..a574d5c 100644..100755
--- a/common/config/nvim/lua/plugins/navic.lua
+++ b/common/config/nvim/lua/plugins/navic.lua
@@ -1,50 +1,51 @@
-local navic = require("nvim-navic")
---local on_attach = function(client, bufnr)
--- if client.server_capabilities.documentSymbolProvider then
--- navic.attach(client, bufnr)
--- end
---end
+local M = {}
---require("lspconfig").clangd.setup {
--- on_attach = on_attach
---}
+function M.setup()
+ local ok, navic = pcall(require, "nvim-navic")
+ if not ok or not navic then
+ return false
+ end
-navic.setup {
- icons = {
- File = " ",
- Module = " ",
- Namespace = " ",
- Package = " ",
- Class = " ",
- Method = " ",
- Property = " ",
- Field = " ",
- Constructor = " ",
- Enum = "練",
- Interface = "練",
- Function = " ",
- Variable = " ",
- Constant = " ",
- String = " ",
- Number = " ",
- Boolean = "◩ ",
- Array = " ",
- Object = " ",
- Key = " ",
- Null = "ﳠ ",
- EnumMember = " ",
- Struct = " ",
- Event = " ",
- Operator = " ",
- TypeParameter = " ",
- },
- lsp = {
- auto_attach = true,
- --preference = nil,
- },
- highlight = false,
- separator = " > ",
- depth_limit = 0,
- depth_limit_indicator = "..",
- safe_output = true
-}
+ navic.setup({
+ icons = {
+ File = " ",
+ Module = " ",
+ Namespace = " ",
+ Package = " ",
+ Class = " ",
+ Method = " ",
+ Property = " ",
+ Field = " ",
+ Constructor = " ",
+ Enum = "練",
+ Interface = "練",
+ Function = " ",
+ Variable = " ",
+ Constant = " ",
+ String = " ",
+ Number = " ",
+ Boolean = "◩ ",
+ Array = " ",
+ Object = " ",
+ Key = " ",
+ Null = "ﳠ ",
+ EnumMember = " ",
+ Struct = " ",
+ Event = " ",
+ Operator = " ",
+ TypeParameter = " "
+ },
+ highlight = false,
+ separator = " > ",
+ depth_limit = 0,
+ depth_limit_indicator = "..",
+ safe_output = true,
+ lsp = {
+ auto_attach = true
+ }
+ })
+
+ return true
+end
+
+return M