testing gcm

This commit is contained in:
2025-09-12 08:51:30 -04:00
parent e4569a70e8
commit c1e349cdce
12 changed files with 3 additions and 93 deletions
+89
View File
@@ -0,0 +1,89 @@
function ColorMyPencils(color)
color = color or 'rose-pine-moon'
vim.cmd.colorscheme(color)
vim.api.nvim_set_hl(0, 'Normal', { bg = 'none' })
vim.api.nvim_set_hl(0, 'NormalFloat', { bg = 'none' })
end
return {
{
'erikbackman/brightburn.vim',
},
{
'folke/tokyonight.nvim',
lazy = false,
opts = {},
config = function()
ColorMyPencils()
end,
},
{
'ellisonleao/gruvbox.nvim',
name = 'gruvbox',
config = function()
require('gruvbox').setup {
terminal_colors = true, -- add neovim terminal colors
undercurl = true,
underline = false,
bold = true,
italic = {
strings = false,
emphasis = false,
comments = false,
operators = false,
folds = false,
},
strikethrough = true,
invert_selection = false,
invert_signs = false,
invert_tabline = false,
invert_intend_guides = false,
inverse = true, -- invert background for search, diffs, statuslines and errors
contrast = '', -- can be "hard", "soft" or empty string
palette_overrides = {},
overrides = {},
dim_inactive = false,
transparent_mode = false,
}
end,
},
{
'folke/tokyonight.nvim',
config = function()
require('tokyonight').setup {
-- your configuration comes here
-- or leave it empty to use the default settings
style = 'storm', -- The theme comes in three styles, `storm`, `moon`, a darker variant `night` and `day`
transparent = true, -- Enable this to disable setting the background color
terminal_colors = true, -- Configure the colors used when opening a `:terminal` in Neovim
styles = {
-- Style to be applied to different syntax groups
-- Value is any valid attr-list value for `:help nvim_set_hl`
comments = { italic = false },
keywords = { italic = false },
-- Background styles. Can be "dark", "transparent" or "normal"
sidebars = 'dark', -- style for sidebars, see below
floats = 'dark', -- style for floating windows
},
}
end,
},
{
'rose-pine/neovim',
name = 'rose-pine',
config = function()
require('rose-pine').setup {
disable_background = true,
styles = {
italic = false,
},
}
ColorMyPencils()
end,
},
}
+42
View File
@@ -0,0 +1,42 @@
return {
'stevearc/conform.nvim',
cmd = { 'ConformInfo' },
opts = {
format = {
timeout_ms = 3000,
async = false,
quiet = false,
},
formatters_by_ft = {
c = { 'clang-format' },
cpp = { 'clang-format' },
html = { 'htmlbeautifier' },
lua = { 'stylua' },
go = { 'goimports', 'gofumpt' },
hcl = { 'packer_fmt' },
python = { 'black' },
sh = { 'shfmt' },
terraform = { 'terraform_fmt' },
['terraform-vars'] = { 'terraform_fmt' },
tf = { 'terraform_fmt' },
toml = { 'taplo' },
yaml = { 'yamlfmt' },
},
formatters = {
['clang-format'] = {
prepend_args = { '-style=file', '-fallback-style=LLVM' },
},
injected = { options = { ignore_errors = true } },
},
},
keys = {
{
'<leader>f',
function()
require('conform').format { async = true, lsp_fallback = true }
end,
mode = 'n',
desc = 'Conform format',
},
},
}
+194
View File
@@ -0,0 +1,194 @@
vim.api.nvim_create_augroup('DapGroup', { clear = true })
local function navigate(args)
local buffer = args.buf
local wid = nil
local win_ids = vim.api.nvim_list_wins() -- Get all window IDs
for _, win_id in ipairs(win_ids) do
local win_bufnr = vim.api.nvim_win_get_buf(win_id)
if win_bufnr == buffer then
wid = win_id
end
end
if wid == nil then
return
end
vim.schedule(function()
if vim.api.nvim_win_is_valid(wid) then
vim.api.nvim_set_current_win(wid)
end
end)
end
local function create_nav_options(name)
return {
group = 'DapGroup',
pattern = string.format('*%s*', name),
callback = navigate,
}
end
return {
{
'mfussenegger/nvim-dap',
lazy = false,
config = function()
local dap = require 'dap'
dap.set_log_level 'DEBUG'
vim.keymap.set('n', '<F8>', dap.continue, { desc = 'Debug: Continue' })
vim.keymap.set('n', '<F10>', dap.step_over, { desc = 'Debug: Step Over' })
vim.keymap.set('n', '<F11>', dap.step_into, { desc = 'Debug: Step Into' })
vim.keymap.set('n', '<F12>', dap.step_out, { desc = 'Debug: Step Out' })
vim.keymap.set('n', '<leader>b', dap.toggle_breakpoint, { desc = 'Debug: Toggle Breakpoint' })
vim.keymap.set('n', '<leader>B', function()
dap.set_breakpoint(vim.fn.input 'Breakpoint condition: ')
end, { desc = 'Debug: Set Conditional Breakpoint' })
end,
},
{
'rcarriga/nvim-dap-ui',
dependencies = { 'mfussenegger/nvim-dap', 'nvim-neotest/nvim-nio' },
config = function()
local dap = require 'dap'
local dapui = require 'dapui'
local function layout(name)
return {
elements = {
{ id = name },
},
enter = true,
size = 40,
position = 'right',
}
end
local name_to_layout = {
repl = { layout = layout 'repl', index = 0 },
stacks = { layout = layout 'stacks', index = 0 },
scopes = { layout = layout 'scopes', index = 0 },
console = { layout = layout 'console', index = 0 },
watches = { layout = layout 'watches', index = 0 },
breakpoints = { layout = layout 'breakpoints', index = 0 },
}
local layouts = {}
for name, config in pairs(name_to_layout) do
table.insert(layouts, config.layout)
name_to_layout[name].index = #layouts
end
local function toggle_debug_ui(name)
dapui.close()
local layout_config = name_to_layout[name]
if layout_config == nil then
error(string.format('bad name: %s', name))
end
local uis = vim.api.nvim_list_uis()[1]
if uis ~= nil then
layout_config.size = uis.width
end
pcall(dapui.toggle, layout_config.index)
end
vim.keymap.set('n', '<leader>dr', function()
toggle_debug_ui 'repl'
end, { desc = 'Debug: toggle repl ui' })
vim.keymap.set('n', '<leader>ds', function()
toggle_debug_ui 'stacks'
end, { desc = 'Debug: toggle stacks ui' })
vim.keymap.set('n', '<leader>dw', function()
toggle_debug_ui 'watches'
end, { desc = 'Debug: toggle watches ui' })
vim.keymap.set('n', '<leader>db', function()
toggle_debug_ui 'breakpoints'
end, { desc = 'Debug: toggle breakpoints ui' })
vim.keymap.set('n', '<leader>dS', function()
toggle_debug_ui 'scopes'
end, { desc = 'Debug: toggle scopes ui' })
vim.keymap.set('n', '<leader>dc', function()
toggle_debug_ui 'console'
end, { desc = 'Debug: toggle console ui' })
vim.api.nvim_create_autocmd('BufEnter', {
group = 'DapGroup',
pattern = '*dap-repl*',
callback = function()
vim.wo.wrap = true
end,
})
vim.api.nvim_create_autocmd('BufWinEnter', create_nav_options 'dap-repl')
vim.api.nvim_create_autocmd('BufWinEnter', create_nav_options 'DAP Watches')
dapui.setup {
layouts = layouts,
enter = true,
}
dap.listeners.before.event_terminated.dapui_config = function()
dapui.close()
end
dap.listeners.before.event_exited.dapui_config = function()
dapui.close()
end
dap.listeners.after.event_output.dapui_config = function(_, body)
if body.category == 'console' then
dapui.eval(body.output) -- Sends stdout/stderr to Console
end
end
end,
},
{
'jay-babu/mason-nvim-dap.nvim',
dependencies = {
'williamboman/mason.nvim',
'mfussenegger/nvim-dap',
'neovim/nvim-lspconfig',
},
config = function()
require('mason-nvim-dap').setup {
ensure_installed = {
'delve',
},
automatic_installation = true,
handlers = {
function(config)
require('mason-nvim-dap').default_setup(config)
end,
delve = function(config)
table.insert(config.configurations, 1, {
args = function()
return vim.split(vim.fn.input 'args> ', ' ')
end,
type = 'delve',
name = 'file',
request = 'launch',
program = '${file}',
outputMode = 'remote',
})
table.insert(config.configurations, 1, {
args = function()
return vim.split(vim.fn.input 'args> ', ' ')
end,
type = 'delve',
name = 'file args',
request = 'launch',
program = '${file}',
outputMode = 'remote',
})
require('mason-nvim-dap').default_setup(config)
end,
},
}
end,
},
}
+102
View File
@@ -0,0 +1,102 @@
return {
'ThePrimeagen/harpoon',
branch = 'harpoon2',
dependencies = { 'nvim-lua/plenary.nvim' },
config = function()
require('harpoon'):setup()
end,
keys = function()
local harpoon = require 'harpoon'
local keybinds = {
{
'<C-e>',
function()
harpoon.ui:toggle_quick_menu(harpoon:list())
end,
mode = 'n',
desc = 'Harpoon: Show marks',
},
{
'<leader>a',
function()
harpoon:list():add()
end,
mode = 'n',
desc = 'Harpoon: Mark file',
},
}
for k, v in pairs { '+', '[', '{', '(', '&', '=', ')', '}', ']', '*' } do
table.insert(keybinds, {
'<leader>' .. v,
function()
harpoon:list():select(k)
end,
mode = 'n',
desc = 'Harpoon: Go to mark ' .. k,
})
end
return keybinds
end,
-- return {
-- {
-- '<C-e>',
-- function()
-- harpoon.ui:toggle_quick_menu(harpoon:list())
-- end,
-- mode = 'n',
-- desc = 'Harpoon: Show marks',
-- },
-- {
-- '<leader>a',
-- function()
-- harpoon:list():add()
-- end,
-- mode = 'n',
-- desc = 'Harpoon: Mark file',
-- },
-- {
-- '<leader>+',
-- function()
-- harpoon:list():select(1)
-- end,
-- mode = 'n',
-- desc = 'Harpoon: Go to mark 1',
-- },
-- {
-- '<leader>[',
-- function()
-- harpoon:list():select(2)
-- end,
-- mode = 'n',
-- desc = 'Harpoon: Go to mark 2',
-- },
-- {
-- '<leader>{',
-- function()
-- harpoon:list():select(3)
-- end,
-- mode = 'n',
-- desc = 'Harpoon: Go to mark 3',
-- },
-- {
-- '<leader>(',
-- function()
-- harpoon:list():select(4)
-- end,
-- mode = 'n',
-- desc = 'Harpoon: Go to mark 4',
-- },
-- {
-- '<leader>&',
-- function()
-- harpoon:list():select(5)
-- end,
-- mode = 'n',
-- desc = 'Harpoon: Go to mark 5',
-- },
-- }
-- end,
}
+6
View File
@@ -0,0 +1,6 @@
-- You can add your own plugins here or in other files in this directory!
-- I promise not to create any merge conflicts in this directory :)
--
-- See the kickstart.nvim README for more information
-- Hello world!
return {}
+22
View File
@@ -0,0 +1,22 @@
return {
{
'folke/trouble.nvim',
config = function()
require('trouble').setup {
icons = false,
}
vim.keymap.set('n', '<leader>tt', function()
require('trouble').toggle()
end)
vim.keymap.set('n', '[t', function()
require('trouble').next { skip_groups = true, jump = true }
end)
vim.keymap.set('n', ']t', function()
require('trouble').previous { skip_groups = true, jump = true }
end)
end,
},
}
+7
View File
@@ -0,0 +1,7 @@
return {
'mbbill/undotree',
config = function()
vim.keymap.set('n', '<leader>u', vim.cmd.UndotreeToggle)
end,
}
+9
View File
@@ -0,0 +1,9 @@
return {
'theprimeagen/vim-be-good',
dependencies = {
'nvim-lua/plenary.nvim',
},
config = function() end,
}
+33
View File
@@ -0,0 +1,33 @@
return {
'folke/zen-mode.nvim',
config = function()
vim.keymap.set('n', '<leader>zz', function()
require('zen-mode').setup {
window = {
width = 90,
options = {},
},
}
require('zen-mode').toggle()
vim.wo.wrap = false
vim.wo.number = true
vim.wo.rnu = true
ColorMyPencils()
end)
vim.keymap.set('n', '<leader>zZ', function()
require('zen-mode').setup {
window = {
width = 80,
options = {},
},
}
require('zen-mode').toggle()
vim.wo.wrap = false
vim.wo.number = false
vim.wo.rnu = false
vim.opt.colorcolumn = '0'
ColorMyPencils()
end)
end,
}