diff options
| author | Ariel D'Alessandro <ariel.dalessandro@auto1.com> | 2021-12-10 16:38:33 +0100 |
|---|---|---|
| committer | Ariel D'Alessandro <ariel.dalessandro@auto1.com> | 2021-12-10 16:38:33 +0100 |
| commit | 6808767d0f8bb36cee3f65358af47fddb671df7b (patch) | |
| tree | 5e53319bbe59f12f252580c7e87f4edae9bb08f0 | |
| parent | d877fb6f0cd64d847c7e19bc4d0a04dedd14aa69 (diff) | |
| download | nvim-conf-6808767d0f8bb36cee3f65358af47fddb671df7b.tar.gz nvim-conf-6808767d0f8bb36cee3f65358af47fddb671df7b.zip | |
Some updates
| -rw-r--r-- | lua/alpha/status-line.lua | 2 | ||||
| -rw-r--r-- | lua/alpha/telescope.lua | 9 | ||||
| -rw-r--r-- | plugin/telescope.vim | 2 |
3 files changed, 11 insertions, 2 deletions
diff --git a/lua/alpha/status-line.lua b/lua/alpha/status-line.lua index 7e31975..e504b2d 100644 --- a/lua/alpha/status-line.lua +++ b/lua/alpha/status-line.lua @@ -8,7 +8,7 @@ require('lualine').setup{ lualine_a = { { 'mode', upper = true } }, lualine_b = { { 'branch', icon = '' }, 'diff' }, lualine_c = { { 'filename', file_status = true, path = 1 } }, - lualine_x = { { 'diagnostics', sources = { 'nvim_lsp' } },'encoding', 'fileformat', 'filetype' }, + lualine_x = { { 'diagnostics', sources = { 'nvim_diagnostic' } },'encoding', 'fileformat', 'filetype' }, lualine_y = { 'progress' }, lualine_z = { 'location' }, }, diff --git a/lua/alpha/telescope.lua b/lua/alpha/telescope.lua index daa4cd8..0033e7a 100644 --- a/lua/alpha/telescope.lua +++ b/lua/alpha/telescope.lua @@ -56,4 +56,13 @@ end M.laravel_artisan = require('alpha.telescope_laravel').artisan M.project_find = require('alpha.telescope_projectionist').find +M.grep_string = function () + vim.ui.input("Grep for > ", function (input) + if input == nil then + return + end + require('telescope.builtin').grep_string({ search = input}) + end) +end + return M diff --git a/plugin/telescope.vim b/plugin/telescope.vim index cf77ffe..48c4b68 100644 --- a/plugin/telescope.vim +++ b/plugin/telescope.vim @@ -1,7 +1,7 @@ let g:telescope_cache_results = 1 let g:telescope_prime_fuzzy_find = 1 -nnoremap <leader>ps :lua require('telescope.builtin').grep_string({ search = vim.fn.input("Grep For > ")})<CR> +nnoremap <leader>ps :lua require('alpha.telescope').grep_string()<CR> nnoremap <leader>pw :lua require('telescope.builtin').grep_string({ search = vim.fn.expand("<cword>")})<CR> nnoremap <leader>pp :lua require('alpha.telescope').project_files()<CR> |