aboutsummaryrefslogtreecommitdiff
path: root/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
commit7ed2303648bf83bb081d9bd863660ebf2344ce47 (patch)
tree702f5f832796b572d0faee31c0eb15507e91f49a /lua/plugins/navic.lua
parent2a8020a2e9b7ef2ee77ddee14892127a4eb95187 (diff)
downloaddotfiles-7ed2303648bf83bb081d9bd863660ebf2344ce47.tar.gz
dotfiles-7ed2303648bf83bb081d9bd863660ebf2344ce47.zip
Squashed 'common/config/nvim/' changes from 2a8020a..966d12a
966d12a Update/Overhaul git-subtree-dir: common/config/nvim git-subtree-split: 966d12ac730c83da90d60ab24eae539b2ea69441
Diffstat (limited to 'lua/plugins/navic.lua')
-rwxr-xr-x[-rw-r--r--]lua/plugins/navic.lua97
1 files changed, 49 insertions, 48 deletions
diff --git a/lua/plugins/navic.lua b/lua/plugins/navic.lua
index a95485d..a574d5c 100644..100755
--- a/lua/plugins/navic.lua
+++ b/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