summaryrefslogtreecommitdiff
path: root/.config/nvim/after/plugin/telescope.lua
blob: c7f4937b13c54912dfac870913865934f13dc005 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
local os = require('os')
local builtin = require('telescope.builtin')
local lib = require('mango.lib')

lib.remap('n', '<leader>pf', function()
	if os.execute('git rev-parse --is-inside-work-tree') == 0 then
		builtin.git_files()
	else
		builtin.find_files()
	end
end)

lib.remap('n', '<leader>ps', function()
	builtin.grep_string({ search = vim.fn.input('Grep > ') })
end)