about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--fnl/nvrc/pack.fnl5
-rw-r--r--fnl/nvrc/packs/cmp.fnl8
2 files changed, 10 insertions, 3 deletions
diff --git a/fnl/nvrc/pack.fnl b/fnl/nvrc/pack.fnl
index fd13659..04771ff 100644
--- a/fnl/nvrc/pack.fnl
+++ b/fnl/nvrc/pack.fnl
@@ -28,9 +28,12 @@
 (pack! :stefandtw/quickfix-reflector.vim {:ft :qf})
 
 (pack! :L3MON4D3/LuaSnip {:module :luasnip})
-(pack! :hrsh7th/nvim-cmp {:req :cmp :event :InsertEnter})
+(pack! :hrsh7th/nvim-cmp {:req :cmp :event :InsertEnter
+                          :requires [(pack :hrsh7th/cmp-buffer {:after :nvim-cmp})
+                                     (pack :lukas-reineke/cmp-rg {:after :nvim-cmp})]})
 (pack! :numToStr/Comment.nvim {:module :Comment :init :Comment})
 (pack! :ibhagwan/fzf-lua {:req :fzf :module :fzf-lua})
 (pack! :ggandor/lightspeed.nvim)
 
 (unpack!)
+
diff --git a/fnl/nvrc/packs/cmp.fnl b/fnl/nvrc/packs/cmp.fnl
index 616a39d..06c3ea4 100644
--- a/fnl/nvrc/packs/cmp.fnl
+++ b/fnl/nvrc/packs/cmp.fnl
@@ -38,7 +38,9 @@
                                                        (. icons vim-item.kind)
                                                        vim-item.kind))
                                    (set vim-item.menu
-                                        (. {:nvim_lsp "[LSP]"}
+                                        (. {:nvim_lsp "[LSP]"
+                                            :buffer "[BUF]"
+                                            :rg "[RG]"}
                                            entry.source.name))
                                    vim-item)}
             :mapping {:<C-p> (cmp.mapping.select_prev_item)
@@ -60,4 +62,6 @@
                                                   (fallback)))
                                              :c (cmp.mapping.select_prev_item {:select true})})}
             :sources [{:name :nvim_lsp}
-                      {:name :nvim_lsp_signature_help}]})
+                      {:name :nvim_lsp_signature_help}
+                      {:name :buffer}
+                      {:name :rg}]})