rcoedo/telescope-ghq
is an extension that integrates the ghq repository manager with telescope.nvim.
{
"nvim-telescope/telescope.nvim",
dependencies = {
"rcoedo/telescope-ghq.nvim",
},
config = function()
require("telescope").load_extension("ghq")
end,
},
use({
"nvim-telescope/telescope.nvim",
requires = {
"rcoedo/telescope-ghq.nvim",
},
config = function()
require("telescope").load_extension("ghq")
end,
}),
:Telescope ghq
lists all repositories.
telescope-ghq
has the following default settings:
require("telescope").setup({
extensions = {
ghq = {
quiet = false,
bin = "ghq",
mappings = {
["i"] = {
["<c-c>"] = require("telescope").extensions.ghq.actions.cd,
["<c-t>"] = require("telescope").extensions.ghq.actions.tcd,
["<c-l>"] = require("telescope").extensions.ghq.actions.lcd,
},
["n"] = {
["c"] = require("telescope").extensions.ghq.actions.cd,
["t"] = require("telescope").extensions.ghq.actions.tcd,
["l"] = require("telescope").extensions.ghq.actions.lcd,
},
},
select = require("telescope.builtin").find_files,
},
},
})
require("telescope").setup({
extensions = {
ghq = {
theme = "ivy",
},
},
})
require("telescope").setup({
extensions = {
ghq = {
select = require("telescope.builtin").git_files,
},
},
})
require("telescope").setup({
extensions = {
ghq = {
select = function(opts)
local selected_dir = opts.cwd
require("telescope.builtin").git_files({ cwd = selected_dir })
end,
},
},
})