bruh...
This commit is contained in:
parent
2cb34c3868
commit
91512247f1
|
@ -10,6 +10,7 @@ vim.keymap.set("n", "<leader>gfo", ":G fetch origin<CR>")
|
|||
vim.keymap.set("n", "<leader>gd", ":Gdiff<CR>")
|
||||
vim.keymap.set("n", "<leader>ge", ":Gedit<CR>")
|
||||
vim.keymap.set("n", "<leader>gr", ":Gread<CR>")
|
||||
vim.keymap.set("n", "<leader>grb", ":G rebase -i<CR>")
|
||||
vim.keymap.set("n", "<leader>gw", ":Gwrite<CR><CR>")
|
||||
vim.keymap.set("n", "<leader>gl", ":silent! Glog<CR>:bot copen<CR>")
|
||||
vim.keymap.set("n", "<leader>gp", ":Ggrep<Space>")
|
||||
|
|
|
@ -0,0 +1,22 @@
|
|||
local Worktree = require("git-worktree")
|
||||
|
||||
-- op = Operations.Switch, Operations.Create, Operations.Delete
|
||||
-- metadata = table of useful values (structure dependent on op)
|
||||
-- Switch
|
||||
-- path = path you switched to
|
||||
-- prev_path = previous worktree path
|
||||
-- Create
|
||||
-- path = path where worktree created
|
||||
-- branch = branch name
|
||||
-- upstream = upstream remote name
|
||||
-- Delete
|
||||
-- path = path where worktree deleted
|
||||
|
||||
Worktree.on_tree_change(function(op, metadata)
|
||||
if op == Worktree.Operations.Switch then
|
||||
print("Switched from " .. metadata.prev_path .. " to " .. metadata.path)
|
||||
end
|
||||
end)
|
||||
|
||||
vim.keymap.set("n", "<leader>bw", require("telescope").extensions.git_worktree.git_worktrees, { desc = "[B]rowse Git Worktrees" })
|
||||
vim.keymap.set("n", "<leader>cw", require("telescope").extensions.git_worktree.create_git_worktree, { desc = "[C]reate Git [W]orktree" })
|
|
@ -299,23 +299,24 @@ require('telescope').setup {
|
|||
|
||||
-- Enable telescope fzf native, if installed
|
||||
pcall(require('telescope').load_extension, 'fzf')
|
||||
pcall(require('telescope').load_extension, 'git_worktree')
|
||||
|
||||
-- See `:help telescope.builtin`
|
||||
vim.keymap.set('n', '<leader>?', require('telescope.builtin').oldfiles, { desc = '[?] Find recently opened files' })
|
||||
vim.keymap.set('n', '<leader><space>', require('telescope.builtin').buffers, { desc = '[ ] Find existing buffers' })
|
||||
vim.keymap.set('n', '<leader>/', function()
|
||||
-- You can pass additional configuration to telescope to change theme, layout, etc.
|
||||
require('telescope.builtin').current_buffer_fuzzy_find(require('telescope.themes').get_dropdown {
|
||||
winblend = 10,
|
||||
previewer = false,
|
||||
})
|
||||
end, { desc = '[/] Fuzzily search in current buffer' })
|
||||
-- vim.keymap.set('n', '<leader><space>', require('telescope.builtin').buffers, { desc = '[ ] Find existing buffers' })
|
||||
-- vim.keymap.set('n', '<leader>/', function()
|
||||
-- -- You can pass additional configuration to telescope to change theme, layout, etc.
|
||||
-- require('telescope.builtin').current_buffer_fuzzy_find(require('telescope.themes').get_dropdown {
|
||||
-- winblend = 10,
|
||||
-- previewer = false,
|
||||
-- })
|
||||
-- end, { desc = '[/] Fuzzily search in current buffer' })
|
||||
|
||||
vim.keymap.set('n', '<leader>gf', require('telescope.builtin').git_files, { desc = 'Search [G]it [F]iles' })
|
||||
vim.keymap.set('n', '<leader><space>', require('telescope.builtin').git_files, { desc = 'Search [G]it [F]iles' })
|
||||
vim.keymap.set('n', '<leader>sf', require('telescope.builtin').find_files, { desc = '[S]earch [F]iles' })
|
||||
vim.keymap.set('n', '<leader>sh', require('telescope.builtin').help_tags, { desc = '[S]earch [H]elp' })
|
||||
vim.keymap.set('n', '<leader>sw', require('telescope.builtin').grep_string, { desc = '[S]earch current [W]ord' })
|
||||
vim.keymap.set('n', '<leader>sg', require('telescope.builtin').live_grep, { desc = '[S]earch by [G]rep' })
|
||||
vim.keymap.set('n', '<leader>/', require('telescope.builtin').live_grep, { desc = '[S]earch by [G]rep' })
|
||||
vim.keymap.set('n', '<leader>sd', require('telescope.builtin').diagnostics, { desc = '[S]earch [D]iagnostics' })
|
||||
vim.keymap.set('n', '<leader>sr', require('telescope.builtin').resume, { desc = '[S]earch [R]esume' })
|
||||
|
||||
|
|
|
@ -9,6 +9,9 @@ return {
|
|||
require("refactoring").setup({})
|
||||
end,
|
||||
},
|
||||
{
|
||||
"ThePrimeagen/git-worktree.nvim",
|
||||
},
|
||||
{
|
||||
"folke/tokyonight.nvim",
|
||||
lazy = false, -- make sure we load this during startup if it is your main colorscheme
|
||||
|
|
|
@ -58,8 +58,6 @@ nmap("<C-s>", ":wa<CR>")
|
|||
|
||||
-- See `:help telescope.builtin`
|
||||
vim.keymap.set("n", "<leader>m", require("telescope.builtin").oldfiles, { desc = "[?] Find recently opened files" })
|
||||
vim.keymap.set("n", "<leader><space>", require("telescope.builtin").git_files, { desc = "[ ] Find git files" })
|
||||
|
||||
vim.keymap.set("n", "<leader>gb", require("telescope.builtin").git_branches, { desc = "[G]it [B]ranches" })
|
||||
vim.keymap.set("n", "<leader>sb", require("telescope.builtin").buffers, { desc = "[ ] Find existing buffers" })
|
||||
|
||||
|
|
|
@ -6,5 +6,7 @@
|
|||
co = checkout
|
||||
ph = push -u origin HEAD
|
||||
ff = pull --ff-only
|
||||
stashgrep = "!f() { for i in `git stash list --format=\"%gd\"` ; \
|
||||
do git stash show -p $i | grep -H --label=\"$i\" \"$@\" ; done ; }; f"
|
||||
[core]
|
||||
excludesFile = ~/.config/git/ignore
|
||||
|
|
|
@ -24,6 +24,7 @@ bind-key -n C-S-Right swap-window -t +1
|
|||
# forget the find window. That is for chumps
|
||||
bind-key -r f run-shell "tmux neww ~/.local/bin/tmux-sessionizer"
|
||||
bind-key -r i run-shell "tmux neww tmux-cht.sh"
|
||||
bind-key -r v run-shell "tmux neww nvim ."
|
||||
|
||||
|
||||
## COLORSCHEME: gruvbox dark (medium)
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
nodejs 16.18.1
|
||||
kubectl 1.23.6
|
||||
ruby 2.7.6
|
||||
nodejs 18.18.1
|
||||
|
|
Loading…
Reference in New Issue