Refactors dot files Telescope command

Changed files
+12 -8
.config
nvim
+11 -8
.config/nvim/lua/plugins.lua
··· 52 52 {defaults = {mappings = {i = {["<Esc>"] = actions.close}}}} 53 53 ) 54 54 55 + _G.find_dotfiles = function() 56 + require("telescope.builtin").find_files( 57 + { 58 + find_command = {"fd", "--type", "l", "--type", "f", "-H"}, 59 + search_dirs = {"~/Dropbox/Projects/dotfiles"}, 60 + } 61 + ) 62 + end 63 + 55 64 local opts = {noremap = true} 56 65 local mappings = { 57 66 {"n", "<Leader>g", [[<Cmd>Telescope git_files<CR>]], opts}, ··· 60 69 {"n", "<Leader>b", [[<Cmd>Telescope buffers<CR>]], opts}, 61 70 {"n", "<Leader>o", [[<Cmd>Telescope oldfiles<CR>]], opts}, 62 71 {"n", "<Leader>/", [[<Cmd>Telescope live_grep<CR>]], opts}, 63 - { 64 - "n", 65 - "<Leader>df", 66 - [[<Cmd>lua require("telescope.builtin").find_files({ search_dirs = {"~/Dropbox/Projects/dotfiles/.config" }})<CR>]], 67 - opts, 68 - }, 72 + {"n", "<Leader>df", [[<Cmd>lua find_dotfiles()<CR>]], opts}, 69 73 } 70 74 for _, val in pairs(mappings) do 71 75 vim.api.nvim_set_keymap(unpack(val)) ··· 255 259 vim.api.nvim_set_keymap("", "m", "<Plug>Sneak_s", {}) 256 260 vim.api.nvim_set_keymap("", "M", "<Plug>Sneak_S", {}) 257 261 end, 258 - 259 262 } 260 263 use { 261 264 "terryma/vim-expand-region", ··· 293 296 294 297 -- general tools 295 298 use {"tpope/vim-abolish"} 296 - use {"vim-scripts/greplace.vim", cmd = "Gsearch"} 297 299 use {"tpope/vim-fugitive"} 300 + use {"vim-scripts/greplace.vim", cmd = "Gsearch"} 298 301 use { 299 302 "lewis6991/gitsigns.nvim", 300 303 requires = {"nvim-lua/plenary.nvim"},
+1
.fdignore
··· 1 + .git/