Skip to content

Commit

Permalink
Add telescope-project (#68)
Browse files Browse the repository at this point in the history
  • Loading branch information
dycw authored Apr 13, 2024
1 parent 2bb82c7 commit 3630ef3
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .bumpversion.cfg
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
[bumpversion]
current_version = 0.1.66
current_version = 0.1.67
4 changes: 4 additions & 0 deletions nvim/lazy-lock.json
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,10 @@
"branch": "master",
"commit": "20656efd7a0dbb4483290649c9671af14b0cfb0d"
},
"telescope-project.nvim": {
"branch": "master",
"commit": "1aaf16580a614601a7f7077d9639aeb457dc5559"
},
"telescope-recent-files.nvim": {
"branch": "main",
"commit": "9f8cb7d22b999346ce819390e75a509e4048f4de"
Expand Down
16 changes: 15 additions & 1 deletion nvim/lua/custom/plugins/telescope.lua
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,14 @@ return {
file_browser = {
hidden = { file_browser = true, folder_browser = true },
},
project = {
base_dirs = {
{ "~/dotfiles", max_depth = 1 },
{ "~/work", max_depth = 1 },
},
hidden_files = true,
sync_with_nvim_tree = true,
},
["ui-select"] = {
require("telescope.themes").get_dropdown(),
},
Expand Down Expand Up @@ -69,7 +77,12 @@ return {
require("telescope").extensions.live_grep_args.live_grep_args()
end, "Live [G]rep (args)")

-- Extension: File Browser
-- Extension: Project
keymap_set("n", "<Leader>pr", function()
require("telescope").extensions.project.project()
end, "P[r]oject")

-- Extension: Recent Files
keymap_set("n", "<Leader>rf", function()
require("telescope").extensions["recent-files"].recent_files({})
end, "Recent [F]iles")
Expand All @@ -89,6 +102,7 @@ return {
"nvim-telescope/telescope-live-grep-args.nvim",
version = "^1.0.0",
},
"nvim-telescope/telescope-project.nvim",
"nvim-telescope/telescope-ui-select.nvim",
{ "nvim-tree/nvim-web-devicons", enabled = v.g.have_nerd_font },
},
Expand Down

0 comments on commit 3630ef3

Please sign in to comment.