Skip to content

Commit

Permalink
nvim: update a bunch of plugins
Browse files Browse the repository at this point in the history
  • Loading branch information
sfrieds3 committed Jul 10, 2024
1 parent e07397e commit 16f015e
Show file tree
Hide file tree
Showing 5 changed files with 92 additions and 209 deletions.
138 changes: 0 additions & 138 deletions roles/dotfiles/files/nvim/lua/plugins/code.lua
Original file line number Diff line number Diff line change
@@ -1,48 +1,6 @@
local is_executable = vim.fn.executable

return {
{
"Vigemus/iron.nvim",
config = function()
local iron = require("iron.core")
iron.setup({
config = {
scratch_repl = true,
repl_definition = {
sh = {
command = { "zsh" },
},
},
-- repl_open_cmd = require("iron.view").right(function()
-- return math.floor(vim.o.columns * 0.4)
-- end),
repl_open_cmd = "vsplit",
},
keymaps = {
send_motion = "\\sc",
visual_send = "\\sc",
send_file = "\\sf",
send_line = "\\sl",
send_until_cursor = "\\su",
send_mark = "\\sm",
mark_motion = "\\mc",
mark_visual = "\\mc",
remove_mark = "\\md",
cr = "\\s<cr>",
interrupt = "\\s<space>",
exit = "\\sq",
clear = "\\cl",
},
highlight = {
italic = true,
},
ignore_blank_lines = true,
})

vim.keymap.set("n", "\\i", "<Cmd>IronRepl<CR>")
vim.keymap.set("n", "\\I", "<Cmd>IronReplHere<CR>")
end,
},
{
"L3MON4D3/LuaSnip",
event = "InsertEnter",
Expand All @@ -56,79 +14,6 @@ return {
require("luasnip.loaders.from_lua").lazy_load({ paths = { vim.fn.stdpath("data") .. "/snippets_local" } })
end,
},
{
"Vonr/align.nvim",
branch = "v2",
keys = {
{
"aa",
function()
require("align").align_to_char({
length = 1,
})
end,
mode = "x",
{ desc = "Align to 1 Character" },
},

{
"ad",
function()
require("align").align_to_char({
preview = true,
length = 2,
})
end,
mode = "x",
{ desc = "Align to 2 Characters with Previews" },
},

{
"aw",
function()
require("align").align_to_string({
preview = true,
regex = false,
})
end,
mode = "x",
{ desc = "Align to String with Previews" },
},

{
"ar",
function()
require("align").align_to_string({
preview = true,
regex = true,
})
end,
mode = "x",
{ desc = "Align to Vim Regex with Previews" },
},

{
"gaw",
function()
local a = require("align")
a.operator(a.align_to_string, {
regex = false,
preview = true,
})
end,
{ desc = "Align Paragraph to a String with Previews" },
},

{
"gaa",
function()
local a = require("align")
a.operator(a.align_to_char)
end,
{ desc = "Align Paragraph to 1 Character" },
},
},
},
{
"kevinhwang91/nvim-ufo",
dependencies = {
Expand Down Expand Up @@ -210,29 +95,6 @@ return {
},
},
},
{
"echasnovski/mini.ai",
-- keys = {
-- { "a", mode = { "x", "o" } },
-- { "i", mode = { "x", "o" } },
-- },
event = "VeryLazy",
opts = function()
local ai = require("mini.ai")
return {
n_lines = 500,
custom_textobjects = {
o = ai.gen_spec.treesitter({
a = { "@block.outer", "@conditional.outer", "@loop.outer" },
i = { "@block.inner", "@conditional.inner", "@loop.inner" },
}, {}),
f = ai.gen_spec.treesitter({ a = "@function.outer", i = "@function.inner" }, {}),
c = ai.gen_spec.treesitter({ a = "@class.outer", i = "@class.inner" }, {}),
t = { "<([%p%w]-)%f[^<%w][^<>]->.-</%1>", "^<.->().*()</[^/]->$" },
},
}
end,
},
{
"danymat/neogen",
keys = {
Expand Down
22 changes: 8 additions & 14 deletions roles/dotfiles/files/nvim/lua/plugins/colorschemes.lua
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ return {
config = function()
require("github-theme").setup({
options = {
dim_inactive = false,
dim_inactive = true,
styles = {
functions = "italic",
},
Expand Down Expand Up @@ -47,6 +47,11 @@ return {
light = "frappe",
dark = "mocha",
},
dim_inactive = {
enabled = true,
shade = "dark",
percentage = 0.80,
},
term_colors = true,
styles = {
booleans = { "bold" },
Expand Down Expand Up @@ -87,7 +92,7 @@ return {
vim.g.gruvbox_material_foreground = "material"
vim.g.gruvbox_material_statusline_stype = "material"
vim.g.gruvbox_better_performance = 1
vim.g.gruvbox_material_dim_inactive_windows = 0
vim.g.gruvbox_material_dim_inactive_windows = 1
end,
},
{
Expand All @@ -114,7 +119,7 @@ return {
})
require("kanagawa").setup({
compile = true,
dimInactive = false,
dimInactive = true,
globalStatus = true,
terminalColors = true,
background = {
Expand Down Expand Up @@ -227,15 +232,4 @@ return {
},
},
},
{
"comfysage/evergarden",
event = "VeryLazy",
opts = {
contrast_dark = "hard",
},
},
{
"nyoom-engineering/oxocarbon.nvim",
event = "VeryLazy",
},
}
79 changes: 23 additions & 56 deletions roles/dotfiles/files/nvim/lua/plugins/editor.lua
Original file line number Diff line number Diff line change
Expand Up @@ -35,28 +35,6 @@ return {
wk.register(opts.defaults)
end,
},
{
"levouh/tint.nvim",

event = "WinEnter",

opts = {
tint = -10,
saturation = 0.6,
window_ignore_function = function(winid)
local exclude_filetypes = {
["neo-tree"] = true,
}
local bufid = vim.api.nvim_win_get_buf(winid)
local buftype = vim.api.nvim_get_option_value("buftype", { buf = bufid })
local floating = vim.api.nvim_win_get_config(winid).relative ~= ""
local filetype = vim.api.nvim_get_option_value("filetype", { buf = bufid })

-- Do not tint `terminal` or floating windows, tint everything else
return buftype == "terminal" or floating or exclude_filetypes[filetype]
end,
},
},
{
"nvim-neo-tree/neo-tree.nvim",
branch = "v3.x",
Expand All @@ -75,6 +53,21 @@ return {
dependencies = {
"nvim-tree/nvim-web-devicons",
"MunifTanjim/nui.nvim",
{
"s1n7ax/nvim-window-picker",
version = "v2.*",
config = true,
keys = {
{
"<Leader>w",
function()
local winid = require("window-picker"):pick_window() or vim.api.nvim_get_current_win()
vim.api.nvim_set_current_win(winid)
end,
desc = "Pick a window",
},
},
},
},
config = function()
vim.g.neo_tree_remove_legacy_commands = 1
Expand Down Expand Up @@ -207,7 +200,6 @@ return {
},
},
},
{ "kylechui/nvim-surround", keys = { "cs", "ds", "ys" }, event = "InsertEnter", config = true },
{
"folke/flash.nvim",

Expand Down Expand Up @@ -323,43 +315,18 @@ return {
end,
},
{
"hedyhli/outline.nvim",
"stevearc/aerial.nvim",
cmd = { "AerialOpen", "AerialToggle", "AerialNavOpen", "AerialNavToggle" },
opts = {
outline_items = {
highlight_hovered_item = true,
show_symbol_details = true,
show_symbol_lineno = false,
},
outline_window = {
show_cursorline = true,
hide_cursor = false,
},
symbol_folding = {
autofold_depth = 1,
},
winblend = 10,
keymaps = {
hover_symbol = "<leader>e",
},
filter_kind = false,
},
cmd = { "Outline", "OutlineOpen" },
keys = {
{ "<Leader><CR>", "<cmd>Outline<cr>", desc = "Outline: toggle" },
-- Optional dependencies
dependencies = {
"nvim-treesitter/nvim-treesitter",
"nvim-tree/nvim-web-devicons",
},
},
{
"s1n7ax/nvim-window-picker",
version = "v2.*",
config = true,
keys = {
{
"<Leader>w",
function()
local winid = require("window-picker"):pick_window() or vim.api.nvim_get_current_win()
vim.api.nvim_set_current_win(winid)
end,
desc = "Pick a window",
},
{ "<leader><cr>", "<cmd>AerialOpen<cr>", desc = "AerialOpen" },
},
},
{
Expand Down
61 changes: 61 additions & 0 deletions roles/dotfiles/files/nvim/lua/plugins/mini.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
return {
{
"echasnovski/mini.ai",
-- keys = {
-- { "a", mode = { "x", "o" } },
-- { "i", mode = { "x", "o" } },
-- },
event = "VeryLazy",
opts = function()
local ai = require("mini.ai")
return {
n_lines = 500,
custom_textobjects = {
o = ai.gen_spec.treesitter({
a = { "@block.outer", "@conditional.outer", "@loop.outer" },
i = { "@block.inner", "@conditional.inner", "@loop.inner" },
}, {}),
f = ai.gen_spec.treesitter({ a = "@function.outer", i = "@function.inner" }, {}),
c = ai.gen_spec.treesitter({ a = "@class.outer", i = "@class.inner" }, {}),
t = { "<([%p%w]-)%f[^<%w][^<>]->.-</%1>", "^<.->().*()</[^/]->$" },
},
}
end,
},
{
"echasnovski/mini.align",
version = false,
config = true,
keys = {
"ga",
"gA",
},
},
{
"echasnovski/mini.surround",
version = false,
keys = {
"<localleader>sa",
"<localleader>sd",
"<localleader>sr",
"<localleader>sf",
"<localleader>sF",
"<localleader>sh",
"<localleader>sn",
},
opts = {
mappings = {
add = "<localleader>sa", -- Add surrounding in Normal and Visual modes
delete = "<localleader>sd", -- Delete surrounding
find = "<localleader>sf", -- Find surrounding (to the right)
find_left = "<localleader>sF", -- Find surrounding (to the left)
highlight = "<localleader>sh", -- Highlight surrounding
replace = "<localleader>sr", -- Replace surrounding
update_n_lines = "<localleader>sn", -- Update `n_lines`

suffix_last = "l", -- Suffix to search with "prev" method
suffix_next = "n", -- Suffix to search with "next" method
},
},
},
}
1 change: 0 additions & 1 deletion roles/dotfiles/files/nvim/lua/plugins/telescope/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ function TelescopeConfig.get_config()
"nvim-telescope/telescope-fzf-native.nvim",
build = "make",
},
"Marskey/telescope-sg",
"debugloop/telescope-undo.nvim",
"nvim-telescope/telescope-ui-select.nvim",
},
Expand Down

0 comments on commit 16f015e

Please sign in to comment.