Skip to content

Commit 517ea40

Browse files
committed
Show hidden files with <leader>sf
The regular shortcut will not show hidden files, and it was annoying when I had to edit a file like .yarnrc.yml and it wouldn't show up in the picker.
1 parent 1fe413e commit 517ea40

1 file changed

Lines changed: 4 additions & 3 deletions

File tree

lua/plugins/telescope.lua

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -71,9 +71,10 @@ return { -- Fuzzy Finder (files, lsp, etc)
7171
vim.keymap.set('n', '<leader>sk', builtin.keymaps, { desc = '[S]earch [K]eymaps' })
7272

7373
vim.keymap.set('n', '<C-p>', builtin.find_files, { desc = '[S]earch [F]iles' })
74-
-- Why the duplicate keymap? With the ergodox keyboard, moving your pinkies that much lateral
75-
-- distance can get annoying. Sometimes easier to just use the larger fingers.
76-
vim.keymap.set('n', '<leader>sf', builtin.find_files, { desc = '[S]earch [F]iles' })
74+
-- Not a duplicate keymap, notice that this will show hidden files!
75+
vim.keymap.set('n', '<leader>sf', function()
76+
builtin.find_files { hidden = true }
77+
end, { desc = '[S]earch [F]iles' })
7778

7879
-- vim.keymap.set('n', '<leader>ss', builtin.builtin, { desc = '[S]earch [S]elect Telescope' })
7980
-- I wasn't using Search Select Telescope, and because ElixirLS doesn't have a good rename function, this will

0 commit comments

Comments
 (0)