From 4e8b3dfa3ac3a1967e8fe68b45fef8c060a93c1c Mon Sep 17 00:00:00 2001 From: Sathvik Birudavolu <8377116+BSathvik@users.noreply.github.com> Date: Wed, 24 Apr 2024 00:47:52 -0400 Subject: [PATCH] nvim fix , add gh pr open command --- nvim/init.lua | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/nvim/init.lua b/nvim/init.lua index 44b7510..a4bc484 100644 --- a/nvim/init.lua +++ b/nvim/init.lua @@ -418,7 +418,7 @@ require("lazy").setup({ local opts = { buffer = bufnr } vim.keymap.set("n", "gd", vim.lsp.buf.definition, opts) vim.keymap.set("n", "K", vim.lsp.buf.hover, opts) - vim.keymap.set("n", "", vim.lsp.buf.signature_help, opts) + vim.keymap.set("n", "", vim.lsp.buf.signature_help, opts) vim.keymap.set("n", "D", vim.lsp.buf.type_definition, opts) vim.keymap.set("n", "rn", vim.lsp.buf.rename, opts) vim.keymap.set("n", "gr", vim.lsp.buf.references, opts) @@ -688,6 +688,10 @@ local function urlencode(url) return url end +vim.api.nvim_create_user_command("PR", function() + vim.api.nvim_command("!gh pr view --web") +end, {}) + vim.api.nvim_create_user_command("Maps", function() local left, right = vim.api.nvim_buf_get_mark(0, "<"), vim.api.nvim_buf_get_mark(0, ">") local text = vim.api.nvim_buf_get_text(0, left[1] - 1, left[2], right[1] - 1, right[2], {})