diff --git a/.config/nvim/lazy-lock.json b/.config/nvim/lazy-lock.json index c36b8e26..fc45e230 100644 --- a/.config/nvim/lazy-lock.json +++ b/.config/nvim/lazy-lock.json @@ -109,6 +109,7 @@ "search-replace.nvim": { "branch": "main", "commit": "d92290a02d97f4e9b8cd60d28b56b403432158d5" }, "semshi": { "branch": "master", "commit": "0182447e2ff4dfa04cd2dfe5f189e012c581ca45" }, "smart-splits.nvim": { "branch": "master", "commit": "f0003bf9c3f11b8b9209264f865b8864453ca926" }, + "sniprun": { "branch": "master", "commit": "639877399a23e375a8c07b75c14d017735eab7cb" }, "sqlite.lua": { "branch": "master", "commit": "b7e28c8463254c46a8e61c52d27d6a2040492fc3" }, "suda.vim": { "branch": "master", "commit": "8b0fc3711760195aba104e2d190cff9af8267052" }, "telescope-all-recent.nvim": { "branch": "main", "commit": "766d79bedf8dd59c2d0a944a7cf3c98795ab5f07" }, diff --git a/.config/nvim/lazyvim.json b/.config/nvim/lazyvim.json index e41942be..97027272 100644 --- a/.config/nvim/lazyvim.json +++ b/.config/nvim/lazyvim.json @@ -13,6 +13,7 @@ "plugins.extras.coding.dial", "plugins.extras.coding.multicursor", "plugins.extras.coding.refactoring", + "plugins.extras.coding.sniprun", "plugins.extras.coding.treesitter.endwise", "plugins.extras.coding.treesitter.mini-align", "plugins.extras.coding.treesitter.node-action", @@ -23,6 +24,7 @@ "plugins.extras.dap.core", "plugins.extras.dap.persistent-breakpoints", "plugins.extras.editor.color", + "plugins.extras.editor.compiler", "plugins.extras.editor.docs.devdocs", "plugins.extras.editor.git.diffview", "plugins.extras.editor.git.github", @@ -57,7 +59,6 @@ "plugins.extras.linting.eslint-extended", "plugins.extras.linting.shellcheck", "plugins.extras.lsp.actions-preview", - "plugins.extras.lsp.compiler", "plugins.extras.lsp.file-operations", "plugins.extras.lsp.garbage-day", "plugins.extras.lsp.glance", diff --git a/.config/nvim/lua/plugins/extras/coding/code-runner.lua b/.config/nvim/lua/plugins/extras/coding/code-runner.lua deleted file mode 100644 index e74d9399..00000000 --- a/.config/nvim/lua/plugins/extras/coding/code-runner.lua +++ /dev/null @@ -1,75 +0,0 @@ -return { - "michaelb/sniprun", - run = "bash ./install.sh", - cmd = { "SnipRun", "SnipInfo", "SnipLive", "SnipClose", "SnipReset", "SnipReplMemoryClean" }, - opts = { - selected_interpreters = {}, --# use those instead of the default for the current filetype - repl_enable = { "javascript", "typescript" }, --# enable REPL-like behavior for the given interpreters - repl_disable = {}, --# disable REPL-like behavior for the given interpreters - - interpreter_options = { - --# interpreter-specific options, see docs / :SnipInfo - - --# use the interpreter name as key - GFM_original = { - use_on_filetypes = { "markdown.pandoc" }, --# the 'use_on_filetypes' configuration key is - --# available for every interpreter - }, - Python3_original = { - error_truncate = "auto", --# Truncate runtime errors 'long', 'short' or 'auto' - --# the hint is available for every interpreter - --# but may not be always respected - }, - }, - - --# you can combo different display modes as desired and with the 'Ok' or 'Err' suffix - --# to filter only sucessful runs (or errored-out runs respectively) - display = { - -- "Classic", --# display results in the command-line area - -- "VirtualTextOk", --# display ok results as virtual text (multiline is shortened) - - "VirtualText", --# display results as virtual text - -- "TempFloatingWindow", --# display results in a floating window - -- "LongTempFloatingWindow", --# same as above, but only long results. To use with VirtualText[Ok/Err] - -- "Terminal", --# display results in a vertical split - -- "TerminalWithCode", --# display results and code history in a vertical split - -- "NvimNotify", --# display with the nvim-notify plugin - -- "Api" --# return output to a programming interface - }, - - live_display = { "VirtualTextOk" }, --# display mode used in live_mode - - display_options = { - terminal_scrollback = vim.o.scrollback, --# change terminal display scrollback lines - terminal_line_number = false, --# whether show line number in terminal window - terminal_signcolumn = false, --# whether show signcolumn in terminal window - terminal_persistence = true, --# always keep the terminal open (true) or close it at every occasion (false) - terminal_width = 45, --# change the terminal display option width - notification_timeout = 5, --# timeout for nvim_notify output - }, - - --# You can use the same keys to customize whether a sniprun producing - --# no output should display nothing or '(no output)' - show_no_output = { - "Classic", - "TempFloatingWindow", --# implies LongTempFloatingWindow, which has no effect on its own - }, - - --# customize highlight groups (setting this overrides colorscheme) - -- snipruncolors = { - -- SniprunVirtualTextOk = { bg = "#66eeff", fg = "#000000", ctermbg = "Cyan", cterfg = "Black" }, - -- SniprunFloatingWinOk = { fg = "#66eeff", ctermfg = "Cyan" }, - -- SniprunVirtualTextErr = { bg = "#881515", fg = "#000000", ctermbg = "DarkRed", cterfg = "Black" }, - -- SniprunFloatingWinErr = { fg = "#881515", ctermfg = "DarkRed" }, - -- }, - - live_mode_toggle = "off", --# live mode toggle, see Usage - Running for more info - - --# miscellaneous compatibility/adjustement settings - inline_messages = false, --# inline_message (0/1) is a one-line way to display messages - --# to workaround sniprun not being able to display anything - - borders = "single", --# display borders around floating windows - --# possible values are 'none', 'single', 'double', or 'shadow' - }, -} diff --git a/.config/nvim/lua/plugins/extras/coding/sniprun.lua b/.config/nvim/lua/plugins/extras/coding/sniprun.lua new file mode 100644 index 00000000..e4f3af47 --- /dev/null +++ b/.config/nvim/lua/plugins/extras/coding/sniprun.lua @@ -0,0 +1,69 @@ +return { + { + "michaelb/sniprun", + run = "bash ./install.sh", + cmd = { "SnipRun", "SnipInfo", "SnipLive", "SnipClose", "SnipReset", "SnipReplMemoryClean" }, + opts = { + selected_interpreters = {}, --# use those instead of the default for the current filetype + repl_enable = { "javascript", "typescript" }, --# enable REPL-like behavior for the given interpreters + repl_disable = {}, --# disable REPL-like behavior for the given interpreters + + interpreter_options = { + GFM_original = { + use_on_filetypes = { "markdown.pandoc" }, --# the 'use_on_filetypes' configuration key is + }, + Python3_original = { + error_truncate = "auto", --# Truncate runtime errors 'long', 'short' or 'auto' + }, + }, + + display = { + "VirtualText", --# display results as virtual text + }, + + live_display = { "VirtualTextOk" }, --# display mode used in live_mode + + display_options = { + terminal_scrollback = vim.o.scrollback, --# change terminal display scrollback lines + terminal_line_number = false, --# whether show line number in terminal window + terminal_signcolumn = false, --# whether show signcolumn in terminal window + terminal_persistence = true, --# always keep the terminal open (true) or close it at every occasion (false) + terminal_width = 45, --# change the terminal display option width + notification_timeout = 5, --# timeout for nvim_notify output + }, + + --# You can use the same keys to customize whether a sniprun producing + --# no output should display nothing or '(no output)' + show_no_output = { + "Classic", + "TempFloatingWindow", --# implies LongTempFloatingWindow, which has no effect on its own + }, + + live_mode_toggle = "off", --# live mode toggle, see Usage - Running for more info + + inline_messages = false, --# inline_message (0/1) is a one-line way to display messages + + borders = "single", --# display borders around floating windows + --# possible values are 'none', 'single', 'double', or 'shadow' + }, + -- stylua: ignore + keys = { + { "cur", "SnipRun", desc = "Run" }, + { "", "SnipRun", desc = "Run" }, + { "cur", function() require("sniprun").run("v") end, mode = { "v" }, desc = "Run" }, + { "", function() require("sniprun").run("v") end, mode = { "v" }, desc = "Run" }, + { "cui", function() require("sniprun").info() end, desc = "Info" }, + { "cuR", function() require("sniprun").reset() end, desc = "Reset" }, + { "", function() require("sniprun").reset() end, desc = "Reset" }, + { "cul", function() require("sniprun.live_mode").toggle() end, desc = "Live" }, + }, + }, + { + "folke/which-key.nvim", + opts = { + defaults = { + ["cu"] = { name = "runner" }, + }, + }, + }, +} diff --git a/.config/nvim/lua/plugins/extras/lsp/compiler.lua b/.config/nvim/lua/plugins/extras/editor/compiler.lua similarity index 75% rename from .config/nvim/lua/plugins/extras/lsp/compiler.lua rename to .config/nvim/lua/plugins/extras/editor/compiler.lua index 809c652e..a1b9df13 100644 --- a/.config/nvim/lua/plugins/extras/lsp/compiler.lua +++ b/.config/nvim/lua/plugins/extras/editor/compiler.lua @@ -16,6 +16,21 @@ return { }, { "stevearc/overseer.nvim", + cmd = { + "OverseerOpen", + "OverseerClose", + "OverseerToggle", + "OverseerSaveBundle", + "OverseerLoadBundle", + "OverseerDeleteBundle", + "OverseerRunCmd", + "OverseerRun", + "OverseerInfo", + "OverseerBuild", + "OverseerQuickAction", + "OverseerTaskAction ", + "OverseerClearCache", + }, opts = { task_list = { direction = "bottom",