Compare commits

..
5 Commits
28 changed files with 693 additions and 664 deletions
Vendored
BIN
View File
Binary file not shown.
+1
View File
@@ -26,3 +26,4 @@ brew "go"
brew "wget" brew "wget"
brew "jq" brew "jq"
brew "ruby" brew "ruby"
brew "opencode"
+5 -1
View File
@@ -26,7 +26,6 @@ DOTFILES_DIR="$HOME/dotfiles"
if [ ! -d "$DOTFILES_DIR" ]; then if [ ! -d "$DOTFILES_DIR" ]; then
echo "Cloning dotfiles..." echo "Cloning dotfiles..."
git clone https://git@moo:dmm/dotfiles.git git clone https://git@moo:dmm/dotfiles.git
cd dotfiles
fi fi
cd "$DOTFILES_DIR" cd "$DOTFILES_DIR"
brew bundle --file=.Brewfile brew bundle --file=.Brewfile
@@ -34,6 +33,11 @@ brew bundle --file=.Brewfile
stow . stow .
cd ~/ cd ~/
TPM_DIR="$HOME/.config/tmux/plugins/tpm/"
if [ ! -d "$TPM_DIR" ]; then
echo "Cloning tpm..."
git clone https://github.com/tmux-plugins/tpm ~/.config/tmux/plugins/tpm
fi
# Enable Touch ID for sudo # Enable Touch ID for sudo
BIN
View File
Binary file not shown.
+1 -24
View File
@@ -1,28 +1,5 @@
--- Options
require('DarthMooMancer.plugins')
require('DarthMooMancer.opts') require('DarthMooMancer.opts')
require('DarthMooMancer.colors') require('DarthMooMancer.plugins')
require('DarthMooMancer.keymaps') require('DarthMooMancer.keymaps')
require('DarthMooMancer.ui') require('DarthMooMancer.ui')
require('DarthMooMancer.lsp') require('DarthMooMancer.lsp')
require('DarthMooMancer.tools')
vim.api.nvim_create_autocmd('FileType', {
pattern = {
'c',
'cpp',
'rust',
'lua',
'typescript',
'javascript',
'css',
'html',
'python',
'go',
'yaml',
},
callback = function()
vim.treesitter.start()
vim.bo.indentexpr = "v:lua.require'nvim-treesitter'.indentexpr()"
end,
})
@@ -1,25 +0,0 @@
require('kanso').setup({
transparent = true,
-- foreground = {
-- dark = "saturated", -- Use default colors in dark mode
-- },
overrides = function(colors)
local theme = colors.theme
return {
Normal = { bg = "none" },
NormalFloat = { bg = "none" },
FloatBorder = { bg = "none" },
FloatTitle = { bg = "none" },
TelescopeBorder = { fg = theme.ui.special, bg = "none" },
TelescopePromptBorder = { fg = theme.ui.special, bg = "none" },
TelescopeResultsBorder = { fg = theme.ui.special, bg = "none" },
TelescopePreviewBorder = { fg = theme.ui.special, bg = "none" },
NotifyBackground = { bg = "none" },
NotifyBorder = { fg = theme.ui.special, bg = "none" },
NotifyBody = { fg = theme.ui.fg, bg = "none" },
NotifyTitle = { fg = theme.ui.special, bg = "none" },
}
end,
})
vim.cmd.colorscheme('kanso-zen')
@@ -11,36 +11,36 @@ vim.keymap.set('n', '<C-d>', '<C-d>zz')
vim.keymap.set('n', 'n', 'nzzzv') vim.keymap.set('n', 'n', 'nzzzv')
vim.keymap.set('n', 'N', 'Nzzzv') vim.keymap.set('n', 'N', 'Nzzzv')
vim.keymap.set('x', '<leader>p', [["_dP]]) vim.keymap.set('x', '<leader>p', [["_dP]])
local builtin = require('telescope.builtin')
vim.keymap.set( vim.keymap.set(
'n', 'n',
'<leader><leader>', '<leader><leader>',
builtin.find_files, function() Snacks.picker.files() end
{ desc = 'Telescope find files' }
) )
vim.keymap.set( vim.keymap.set(
'n', 'n',
'<leader>fh', '<leader>fh',
builtin.help_tags, function() Snacks.picker.help() end
{ desc = 'Telescope help tags' }
) )
vim.keymap.set( vim.keymap.set(
'n', 'n',
'<leader>fg', '<leader>fg',
builtin.live_grep, function() Snacks.picker.grep() end
{ desc = 'Telescope live grep' }
) )
vim.keymap.set( vim.keymap.set(
'n', 'n',
'<leader>fm', '<leader>fm',
builtin.man_pages, function() Snacks.picker.man() end
{ desc = 'Telescope man_pages' }
) )
vim.keymap.set( vim.keymap.set(
'n', 'n',
'<leader>xn', '<leader>xn',
':Telescope notify<CR>', function() Snacks.picker.notifications() end
{ desc = 'Telescope notify' } )
vim.keymap.set(
'n',
'<leader>uu',
function() Snacks.picker.undo() end
) )
vim.keymap.set('n', '<leader>fs', vim.lsp.buf.document_symbol) vim.keymap.set('n', '<leader>fs', vim.lsp.buf.document_symbol)
@@ -48,7 +48,6 @@ vim.keymap.set('n', '<leader>gd', vim.lsp.buf.definition)
vim.keymap.set('n', '<leader>gr', vim.lsp.buf.references) vim.keymap.set('n', '<leader>gr', vim.lsp.buf.references)
vim.keymap.set('n', '<leader>gR', vim.lsp.buf.rename) vim.keymap.set('n', '<leader>gR', vim.lsp.buf.rename)
vim.keymap.set('n', '<leader>gc', vim.lsp.buf.code_action) vim.keymap.set('n', '<leader>gc', vim.lsp.buf.code_action)
vim.keymap.set('n', '<leader>uu', ':UndotreeToggle<CR>')
vim.keymap.set('n', '<leader>[', '<c-w>H', { silent = true, noremap = true }) vim.keymap.set('n', '<leader>[', '<c-w>H', { silent = true, noremap = true })
vim.keymap.set('n', '<leader>]', '<c-w>K', { silent = true, noremap = true }) vim.keymap.set('n', '<leader>]', '<c-w>K', { silent = true, noremap = true })
vim.keymap.set('n', '[q', ':cprev<CR>zz', { desc = 'Previous Quickfix Item' }) vim.keymap.set('n', '[q', ':cprev<CR>zz', { desc = 'Previous Quickfix Item' })
@@ -61,8 +60,4 @@ vim.keymap.set('n', '<C-j>', ':NvimTmuxNavigateDown<CR>', { silent = true })
vim.keymap.set('n', '<C-k>', ':NvimTmuxNavigateUp<CR>', { silent = true }) vim.keymap.set('n', '<C-k>', ':NvimTmuxNavigateUp<CR>', { silent = true })
vim.keymap.set('n', '<C-l>', ':NvimTmuxNavigateRight<CR>', { silent = true }) vim.keymap.set('n', '<C-l>', ':NvimTmuxNavigateRight<CR>', { silent = true })
vim.keymap.set('n', '<leader>xx', ':Trouble diagnostics toggle<cr>') vim.keymap.set('n', '<leader>xx', ':Trouble diagnostics toggle<cr>')
vim.keymap.set('n', '<leader>zz', ':ZenMode<cr>') vim.keymap.set('n', '<leader>zz', function() Snacks.zen() end)
local dropbar_api = require("dropbar.api")
vim.keymap.set("n", "<Leader>;", dropbar_api.pick, { desc = "Pick symbols in winbar" })
vim.keymap.set("n", "[;", dropbar_api.goto_context_start, { desc = "Go to start of current context" })
vim.keymap.set("n", "];", dropbar_api.select_next_context, { desc = "Select next context" })
@@ -1,53 +1,3 @@
require('mason').setup()
require('mason-lspconfig').setup({
ensure_installed = {
'vtsls',
'lua_ls',
'pylsp',
'gopls',
'html',
'cssls',
'bashls',
},
automatic_enable = false,
})
require('nvim-treesitter').install({
'rust',
'c',
'cpp',
'lua',
'javascript',
'go',
'typescript',
'css',
'html',
'python',
'yaml',
})
require('conform').setup({
formatters_by_ft = {
rust = { 'rustfmt', lsp_format = 'fallback' },
lua = { 'stylua', lsp_format = 'fallback' },
javascript = { 'prettier', stop_after_first = true },
typescript = { 'prettier', stop_after_first = true },
json = { 'prettier' },
html = { 'prettier' },
go = { 'goimports' },
c = { 'clang-format' },
cpp = { 'clang-format' },
css = { 'csskit' },
dart = { 'dart_format', lsp_format = 'fallback' },
python = { 'autopep8' },
['_'] = { 'trim_whitespace' },
},
format_on_save = {
timeout_ms = 2000,
lsp_format = 'fallback',
},
})
local capabilities = require('blink.cmp').get_lsp_capabilities() local capabilities = require('blink.cmp').get_lsp_capabilities()
vim.lsp.config('lua_ls', { vim.lsp.config('lua_ls', {
capabilities = capabilities, capabilities = capabilities,
+46 -33
View File
@@ -2,29 +2,29 @@ vim.opt.termguicolors = true
vim.g.mapleader = ' ' vim.g.mapleader = ' '
vim.opt.number = true vim.opt.number = true
vim.opt.relativenumber = true vim.opt.relativenumber = true
vim.opt.tabstop = 8 -- Number of spaces a <Tab> counts for vim.opt.tabstop = 8 -- Number of spaces a <Tab> counts for
vim.opt.shiftwidth = 8 -- Number of spaces for autoindent (>>, <<, etc.) vim.opt.shiftwidth = 8 -- Number of spaces for autoindent (>>, <<, etc.)
vim.opt.softtabstop = 8 -- Number of spaces for <Tab> in insert mode (backspace deletes 4 spaces) vim.opt.softtabstop = 8 -- Number of spaces for <Tab> in insert mode (backspace deletes 4 spaces)
vim.opt.expandtab = true -- Use spaces instead of tabs vim.opt.expandtab = true -- Use spaces instead of tabs
vim.api.nvim_create_autocmd('FileType', { vim.api.nvim_create_autocmd('FileType', {
callback = function(ev) callback = function(ev)
local map = { local map = {
rust = { ts = 4, sw = 4, sts = 4 }, rust = { ts = 4, sw = 4, sts = 4 },
lua = { ts = 4, sw = 4, sts = 4 }, lua = { ts = 4, sw = 4, sts = 4 },
python = { ts = 4, sw = 4, sts = 4 }, python = { ts = 4, sw = 4, sts = 4 },
dart = { ts = 2, sw = 2, sts = 2 }, dart = { ts = 2, sw = 2, sts = 2 },
html = { ts = 2, sw = 2, sts = 2 }, html = { ts = 2, sw = 2, sts = 2 },
javascript = { ts = 2, sw = 2, sts = 2 }, javascript = { ts = 2, sw = 2, sts = 2 },
typescript = { ts = 2, sw = 2, sts = 2 }, typescript = { ts = 2, sw = 2, sts = 2 },
} }
local ft = map[ev.match] local ft = map[ev.match]
if ft then if ft then
vim.bo[ev.buf].tabstop = ft.ts vim.bo[ev.buf].tabstop = ft.ts
vim.bo[ev.buf].shiftwidth = ft.sw vim.bo[ev.buf].shiftwidth = ft.sw
vim.bo[ev.buf].softtabstop = ft.sts vim.bo[ev.buf].softtabstop = ft.sts
vim.bo[ev.buf].expandtab = ft.et ~= nil and ft.et or true vim.bo[ev.buf].expandtab = ft.et ~= nil and ft.et or true
end end
end, end,
}) })
vim.opt.autoindent = true -- Copy indent from current line when starting a new line vim.opt.autoindent = true -- Copy indent from current line when starting a new line
vim.opt.wrap = false vim.opt.wrap = false
@@ -39,27 +39,40 @@ vim.g.netrw_browse_split = 0
vim.g.netrw_banner = 0 vim.g.netrw_banner = 0
vim.g.netrw_liststyle = 3 vim.g.netrw_liststyle = 3
vim.g.netrw_winsize = 25 vim.g.netrw_winsize = 25
vim.opt.wrapscan = true -- begin search from top of the file when nothng is found vim.opt.wrapscan = true -- begin search from top of the file when nothng is found
vim.opt.cursorline = true -- enable cursorline vim.opt.cursorline = true -- enable cursorline
vim.opt.cursorlineopt = { 'screenline', 'number' } -- cursorline look vim.opt.cursorlineopt = { 'screenline', 'number' } -- cursorline look
vim.opt.foldmethod = 'indent' vim.opt.foldmethod = 'indent'
vim.opt.foldcolumn = '1' vim.opt.foldcolumn = '1'
vim.opt.foldenable = false vim.opt.foldenable = false
vim.opt.shortmess = 'aF' -- abbreviates messages and prevents file name being echoed when opened vim.opt.shortmess = 'aF' -- abbreviates messages and prevents file name being echoed when opened
vim.opt.ignorecase = false -- ignore cases when searching vim.opt.ignorecase = false -- ignore cases when searching
vim.opt.smartcase = true -- However if we use a capital in search string we then consider case-sensitivity, ignorecase is disabled vim.opt.smartcase = true -- However if we use a capital in search string we then consider case-sensitivity, ignorecase is disabled
vim.opt.smartindent = false -- smarter indentation vim.opt.smartindent = false -- smarter indentation
vim.opt.smarttab = true -- make tab behaviour smarter vim.opt.smarttab = true -- make tab behaviour smarter
vim.opt.laststatus = 3 vim.opt.laststatus = 3
vim.opt.showmode = false vim.opt.showmode = false
vim.opt.cmdheight = 0 vim.opt.cmdheight = 0
vim.opt.smoothscroll = true vim.opt.smoothscroll = true
vim.opt.spell = true vim.opt.spell = true
vim.diagnostic.config({ vim.diagnostic.config({
virtual_text = true, -- This is the magic line virtual_text = true, -- This is the magic line
signs = true, -- Shows icons in the gutter signs = true, -- Shows icons in the gutter
underline = true, underline = true,
update_in_insert = false, -- Don't clutter the screen while typing update_in_insert = false, -- Don't clutter the screen while typing
severity_sort = true, severity_sort = true,
})
vim.o.winborder = 'rounded'
vim.api.nvim_create_autocmd('FileType', {
pattern = { 'text', 'plaintex' },
callback = function()
-- Enable visual soft-wrapping
vim.opt_local.wrap = true
vim.opt_local.linebreak = true
vim.opt_local.breakindent = true
-- Remap j/k to visual lines only inside this buffer
vim.keymap.set('n', 'j', 'gj', { buffer = true })
vim.keymap.set('n', 'k', 'gk', { buffer = true })
end,
}) })
vim.o.winborder = "rounded"
@@ -1,43 +1,12 @@
vim.pack.add({ require('DarthMooMancer.plugins.utils')
-- Themes require('DarthMooMancer.plugins.blink-cmp')
{ src = 'https://github.com/webhooked/kanso.nvim' }, require('DarthMooMancer.plugins.kanso')
require('DarthMooMancer.plugins.mini-nvim')
-- The rest require('DarthMooMancer.plugins.polydev')
{ src = 'https://github.com/mbbill/undotree' }, require('DarthMooMancer.plugins.treesitter')
{ require('DarthMooMancer.plugins.incline')
src = 'https://github.com/nvim-mini/mini.pairs', require('DarthMooMancer.plugins.mason')
version = vim.version.range('*'), require('DarthMooMancer.plugins.noice')
}, require('DarthMooMancer.plugins.snacks')
{ require('DarthMooMancer.plugins.trouble')
src = 'https://github.com/nvim-mini/mini.hipatterns', require('DarthMooMancer.plugins.conform')
version = vim.version.range('*'),
},
{ src = 'https://github.com/nvim-tree/nvim-web-devicons' },
{ src = 'https://github.com/nvim-telescope/telescope.nvim' },
{
src = 'https://github.com/saghen/blink.cmp',
version = vim.version.range('*'),
},
{ src = 'https://git.moomancer.xyz/DarthMooMancer/polydev.git' },
{
src = 'https://github.com/nvim-treesitter/nvim-treesitter',
build = ':TSUpdate',
},
{ src = 'https://github.com/alexghergh/nvim-tmux-navigation' },
{ src = 'https://github.com/mason-org/mason.nvim' },
{ src = 'https://github.com/mason-org/mason-lspconfig.nvim' },
{ src = 'https://github.com/neovim/nvim-lspconfig' },
{ src = 'https://github.com/stevearc/conform.nvim' },
{ src = 'https://github.com/b0o/incline.nvim' },
{ src = 'https://github.com/windwp/nvim-ts-autotag' },
{ src = 'https://github.com/MunifTanjim/nui.nvim' },
{ src = 'https://github.com/nvim-lua/plenary.nvim' },
{ src = 'https://github.com/folke/noice.nvim' },
-- { src = 'https://github.com/stevearc/dressing.nvim' },
{ src = 'https://github.com/rcarriga/nvim-notify' },
{ src = 'https://github.com/folke/trouble.nvim' },
{ src = 'https://github.com/brianhuster/live-preview.nvim' },
{ src = 'https://github.com/m4xshen/hardtime.nvim' },
{ src = 'https://github.com/Bekaboo/dropbar.nvim' },
{ src = 'https://github.com/folke/zen-mode.nvim' },
})
@@ -0,0 +1,30 @@
vim.pack.add({
{
src = 'https://github.com/saghen/blink.cmp',
version = vim.version.range('*'),
}
})
require('blink.cmp').setup({
completion = {
documentation = {
auto_show = true,
auto_show_delay_ms = 100,
window = {
winhighlight = 'Normal:NormalFloat,FloatBorder:SnacksPickerBorder,CursorLine:Visual,Search:None',
},
},
menu = {
draw = {
columns = {
{ "label", "label_description", gap = 1 },
{ "kind_icon", "kind", gap = 1 },
{ "source_name", gap = 1 },
},
},
scrollbar = false,
winhighlight =
'Pmenu:NormalFloat,FloatBorder:SnacksPickerBorder,PmenuSel:Visual,CursorLine:Visual,Search:None',
},
},
})
@@ -0,0 +1,23 @@
vim.pack.add({ 'https://github.com/stevearc/conform.nvim' })
require('conform').setup({
formatters_by_ft = {
rust = { 'rustfmt', lsp_format = 'fallback' },
lua = { 'stylua', lsp_format = 'fallback' },
javascript = { 'prettier', stop_after_first = true },
typescript = { 'prettier', stop_after_first = true },
json = { 'prettier' },
html = { 'prettier' },
go = { 'goimports' },
c = { 'clang-format' },
cpp = { 'clang-format' },
css = { 'csskit' },
dart = { 'dart_format', lsp_format = 'fallback' },
python = { 'autopep8' },
['_'] = { 'trim_whitespace' },
},
format_on_save = {
timeout_ms = 2000,
lsp_format = 'fallback',
},
})
@@ -0,0 +1,50 @@
vim.pack.add({
{ src = 'https://github.com/b0o/incline.nvim' },
{ src = 'https://github.com/SmiteshP/nvim-navic' },
})
local helpers = require('incline.helpers')
local navic = require('nvim-navic')
local devicons = require('nvim-web-devicons')
vim.api.nvim_create_autocmd('LspAttach', {
group = vim.api.nvim_create_augroup('UserNavicAttach', { clear = true }),
callback = function(args)
local client = vim.lsp.get_client_by_id(args.data.client_id)
if client and client.server_capabilities.documentSymbolProvider then
navic.attach(client, args.buf)
end
end,
})
require('incline').setup({
window = {
padding = 0,
margin = { horizontal = 0, vertical = 0 },
},
render = function(props)
local filename = vim.fn.fnamemodify(vim.api.nvim_buf_get_name(props.buf), ':t')
if filename == '' then
filename = '[No Name]'
end
local ft_icon, ft_color = devicons.get_icon_color(filename)
local modified = vim.bo[props.buf].modified
local res = {
ft_icon and { ' ', ft_icon, ' ', guibg = ft_color, guifg = helpers.contrast_color(ft_color) } or '',
' ',
{ filename, gui = modified and 'bold,italic' or 'bold' },
guibg = "none",
}
if props.focused then
for _, item in ipairs(navic.get_data(props.buf) or {}) do
table.insert(res, {
{ ' > ', group = 'NavicSeparator' },
{ item.icon, group = 'NavicIcons' .. item.type },
{ item.name, group = 'NavicText' },
})
end
end
table.insert(res, ' ')
return res
end,
})
@@ -0,0 +1,19 @@
vim.pack.add({'https://github.com/webhooked/kanso.nvim' })
require('kanso').setup({
transparent = true,
overrides = function(colors)
local theme = colors.theme
return {
Normal = { bg = "none" },
NormalFloat = { bg = "none" },
FloatBorder = { bg = "none" },
FloatTitle = { bg = "none" },
SnacksPickerBorder = { fg = theme.ui.special, bg = "none" },
SnacksPickerTitle = { fg = theme.ui.special, bg = "none" },
SnacksInputBorder = { fg = theme.ui.special, bg = "none" },
}
end,
})
vim.cmd.colorscheme('kanso-zen')
@@ -0,0 +1,19 @@
vim.pack.add({
{ src = 'https://github.com/mason-org/mason.nvim' },
{ src = 'https://github.com/mason-org/mason-lspconfig.nvim' },
{ src = 'https://github.com/neovim/nvim-lspconfig' },
})
require('mason').setup()
require('mason-lspconfig').setup({
ensure_installed = {
'vtsls',
'lua_ls',
'pylsp',
'gopls',
'html',
'cssls',
'bashls',
},
automatic_enable = false,
})
@@ -0,0 +1,34 @@
vim.pack.add({
{
src = 'https://github.com/nvim-mini/mini.nvim.git',
version = vim.version.range('*')
}
})
local hipatterns = require('mini.hipatterns')
hipatterns.setup({
highlighters = {
-- Highlight standalone 'FIXME', 'HACK', 'TODO', 'NOTE'
fixme = {
pattern = '%f[%w]()FIXME()%f[%W]',
group = 'MiniHipatternsFixme',
},
hack = {
pattern = '%f[%w]()HACK()%f[%W]',
group = 'MiniHipatternsHack',
},
todo = {
pattern = '%f[%w]()TODO()%f[%W]',
group = 'MiniHipatternsTodo',
},
note = {
pattern = '%f[%w]()NOTE()%f[%W]',
group = 'MiniHipatternsNote',
},
hex_color = hipatterns.gen_highlighter.hex_color(),
},
})
require('mini.pairs').setup()
-- require('mini.icons').setup()
@@ -0,0 +1,20 @@
vim.pack.add({
{ src = 'https://github.com/folke/noice.nvim' },
{ src = 'https://github.com/MunifTanjim/nui.nvim' },
})
require('noice').setup({
lsp = {
override = {
['vim.lsp.util.convert_input_to_markdown_lines'] = true,
['vim.lsp.util.stylize_markdown'] = true,
},
},
presets = {
bottom_search = true, -- use a classic bottom cmdline for search
command_palette = true, -- position the cmdline and popupmenu together
long_message_to_split = true, -- long messages will be sent to a split
inc_rename = false, -- enables an input dialog for inc-rename.nvim
lsp_doc_border = false, -- add a border to hover docs and signature help
},
})
@@ -0,0 +1,3 @@
vim.pack.add({'https://git.moomancer.xyz/DarthMooMancer/polydev.git' })
require('Polydev').setup()
@@ -0,0 +1,31 @@
vim.pack.add({ 'https://github.com/folke/snacks.nvim' })
require('snacks').setup({
notifier = {
enabled = true,
},
animate = { enabled = true },
input = { enabled = true },
picker = {
enabled = true,
prompt = '',
icons = {
ui = {
selected = '',
},
},
layout = {
preview = false,
},
},
zen = {
enabled = true,
toggles = {
dim = false,
diagnostics = true,
inlay_hints = true,
},
},
})
@@ -0,0 +1,49 @@
vim.pack.add({
{
src = 'https://github.com/nvim-treesitter/nvim-treesitter',
build = ':TSUpdate',
},
{ src = 'https://github.com/windwp/nvim-ts-autotag' },
})
require('nvim-treesitter').install({
'rust',
'c',
'cpp',
'lua',
'javascript',
'go',
'typescript',
'css',
'html',
'python',
'yaml',
})
require('nvim-ts-autotag').setup({
opts = {
enable_close = true, -- Auto close tags
enable_rename = true, -- Auto rename pairs of tags
enable_close_on_slash = false, -- Auto close on trailing </
},
})
vim.api.nvim_create_autocmd('FileType', {
pattern = {
'c',
'cpp',
'rust',
'lua',
'typescript',
'javascript',
'css',
'html',
'python',
'go',
'yaml',
},
callback = function()
vim.treesitter.start()
vim.bo.indentexpr = "v:lua.require'nvim-treesitter'.indentexpr()"
end,
})
@@ -0,0 +1,2 @@
vim.pack.add({ 'https://github.com/folke/trouble.nvim' })
require('trouble').setup({})
@@ -0,0 +1,13 @@
vim.pack.add({
{ src = 'https://github.com/nvim-tree/nvim-web-devicons' },
{ src = 'https://github.com/alexghergh/nvim-tmux-navigation' },
{ src = 'https://github.com/brianhuster/live-preview.nvim' },
{ src = 'https://github.com/m4xshen/hardtime.nvim' },
})
require('nvim-tmux-navigation').setup({
disable_when_zoomed = true, -- defaults to false
})
require("hardtime").setup()
@@ -1,87 +0,0 @@
local hipatterns = require('mini.hipatterns')
hipatterns.setup({
highlighters = {
-- Highlight standalone 'FIXME', 'HACK', 'TODO', 'NOTE'
fixme = {
pattern = '%f[%w]()FIXME()%f[%W]',
group = 'MiniHipatternsFixme',
},
hack = {
pattern = '%f[%w]()HACK()%f[%W]',
group = 'MiniHipatternsHack',
},
todo = {
pattern = '%f[%w]()TODO()%f[%W]',
group = 'MiniHipatternsTodo',
},
note = {
pattern = '%f[%w]()NOTE()%f[%W]',
group = 'MiniHipatternsNote',
},
hex_color = hipatterns.gen_highlighter.hex_color(),
},
})
require('mini.pairs').setup()
require('nvim-tmux-navigation').setup({
disable_when_zoomed = true, -- defaults to false
})
-- require("zen-mode").toggle({
-- })
require('blink.cmp').setup({
completion = {
documentation = {
auto_show = true,
auto_show_delay_ms = 100,
window = {
winhighlight = 'Normal:NormalFloat,FloatBorder:TelescopeBorder,CursorLine:Visual,Search:None',
},
},
menu = {
draw = {
columns = {
{ "label", "label_description", gap = 1 },
{ "kind_icon", "kind", gap = 1 },
{ "source_name", gap = 1 },
},
},
scrollbar = false,
winhighlight =
'Pmenu:NormalFloat,FloatBorder:TelescopeBorder,PmenuSel:TelescopeSelection,CursorLine:TelescopeSelection,Search:None',
},
},
})
require('Polydev').setup()
require('nvim-ts-autotag').setup({
opts = {
enable_close = true, -- Auto close tags
enable_rename = true, -- Auto rename pairs of tags
enable_close_on_slash = false, -- Auto close on trailing </
},
})
require('trouble').setup({})
require("telescope").setup({
defaults = {
prompt_prefix = "", -- Changes the search icon/prompt prefix
selection_caret = "", -- Changes the arrow/caret next to the selected item
layout_strategy = "horizontal",
layout_config = {
horizontal = {
prompt_position = 'top',
prompt_min_width = 40,
prompt_max_width = 80,
preview_width = 80,
},
},
sorting_strategy = "ascending",
preview = {
hide_on_startup = true,
},
},
})
require("hardtime").setup()
+301 -292
View File
@@ -1,328 +1,337 @@
--- Derive a highlight from an existing scheme group.
local function derive_hl(name, opts) local function derive_hl(name, opts)
local base = opts.base and vim.api.nvim_get_hl(0, { name = opts.base }) local base = opts.base and vim.api.nvim_get_hl(0, { name = opts.base })
or {} or {}
local fg = opts.fg and vim.api.nvim_get_hl(0, { name = opts.fg }) or {} local fg = opts.fg and vim.api.nvim_get_hl(0, { name = opts.fg }) or {}
local bg = opts.bg and vim.api.nvim_get_hl(0, { name = opts.bg }) or {} local bg = opts.bg and vim.api.nvim_get_hl(0, { name = opts.bg }) or {}
vim.api.nvim_set_hl(0, name, { vim.api.nvim_set_hl(0, name, {
fg = fg.fg or base.fg, fg = fg.fg or base.fg,
bg = bg.bg or base.bg, bg = bg.bg or base.bg,
bold = opts.bold, bold = opts.bold,
}) })
end end
--- Derive a mode highlight where bg comes from a syntax group and fg contrasts.
local function derive_mode_hl(name, color_group) local function derive_mode_hl(name, color_group)
local color = vim.api.nvim_get_hl(0, { name = color_group }) local color = vim.api.nvim_get_hl(0, { name = color_group })
local status_bg = vim.api.nvim_get_hl(0, { name = 'StatusLine' }) local status_bg = vim.api.nvim_get_hl(0, { name = 'StatusLine' })
vim.api.nvim_set_hl(0, name, { vim.api.nvim_set_hl(0, name, {
bg = color.fg, bg = color.fg,
fg = status_bg.bg or '#191724', fg = status_bg.bg or '#191724',
bold = true, bold = true,
}) })
end end
--- (Re)build all statusline highlight groups from current scheme.
local function setup_statusline_highlights() local function setup_statusline_highlights()
derive_mode_hl('StatusModeNormal', 'Type') derive_mode_hl('StatusModeNormal', 'Type')
derive_mode_hl('StatusModeInsert', 'String') derive_mode_hl('StatusModeInsert', 'String')
derive_mode_hl('StatusModeVisual', 'Statement') derive_mode_hl('StatusModeVisual', 'Statement')
derive_mode_hl('StatusModeCommand', 'PreProc') derive_mode_hl('StatusModeCommand', 'PreProc')
derive_mode_hl('StatusModeReplace', 'WarningMsg') derive_mode_hl('StatusModeReplace', 'WarningMsg')
derive_mode_hl('StatusModeTerminal', 'Special') derive_mode_hl('StatusModeTerminal', 'Special')
derive_hl('StatusGit', { base = 'CursorLine', fg = 'LineNr' }) derive_hl('StatusGit', { base = 'CursorLine', fg = 'Normal' })
derive_hl('StatusLsp', { base = 'StatusLine', fg = 'DiagnosticInfo' }) derive_hl(
derive_hl('StatusLspSpinner', { base = 'StatusLine', fg = 'Constant' }) 'StatusLspWorking',
derive_hl( { base = 'StatusLine', fg = 'DiagnosticInfo' }
'StatusDiagError', )
{ base = 'StatusLine', fg = 'DiagnosticError' } derive_hl('StatusLspReady', { base = 'StatusLine', fg = 'Constant' })
) derive_hl('StatusLspNone', { base = 'StatusLine', fg = 'NonText' })
derive_hl('StatusDiagWarn', { base = 'StatusLine', fg = 'DiagnosticWarn' }) derive_hl(
derive_hl('StatusDiagHint', { base = 'StatusLine', fg = 'DiagnosticHint' }) 'StatusDiagError',
derive_hl('StatusCursor', { base = 'CursorLine', fg = 'Normal' }) { base = 'StatusLine', fg = 'DiagnosticError' }
-- derive_hl('StatusGitAdded', { base = 'StatusLine', fg = 'OkMsg' }) )
derive_hl('StatusGitAdded', { base = 'StatusLine', fg = 'MoreMsg' }) derive_hl('StatusDiagWarn', { base = 'StatusLine', fg = 'DiagnosticWarn' })
derive_hl( derive_hl('StatusDiagHint', { base = 'StatusLine', fg = 'DiagnosticHint' })
'StatusGitRemoved', derive_hl('StatusCursor', { base = 'CursorLine', fg = 'Normal' })
{ base = 'StatusLine', fg = 'DiagnosticError' } derive_hl('StatusGitAdded', { base = 'StatusLine', fg = 'DiagnosticOk' })
) derive_hl(
derive_hl('StatusRecording', { base = 'StatusLine', fg = 'WarningMsg' }) 'StatusGitRemoved',
{ base = 'StatusLine', fg = 'DiagnosticError' }
)
derive_hl('StatusRecording', { base = 'StatusLine', fg = 'WarningMsg' })
end end
vim.api.nvim_create_autocmd('ColorScheme', { vim.api.nvim_create_autocmd('ColorScheme', {
callback = setup_statusline_highlights, callback = setup_statusline_highlights,
}) })
setup_statusline_highlights() setup_statusline_highlights()
--- Mode text mapping.
local mode_map = { local mode_map = {
['n'] = ' NORM ', n = ' NORM ',
['i'] = ' INS ', i = ' INS ',
['v'] = ' VIS ', v = ' VIS ',
['V'] = ' V-LINE ', V = ' V-LINE ',
[''] = ' V-BLK ', ['\22'] = ' V-BLK ',
['R'] = ' REPL ', ['\19'] = ' V-BLK ',
['c'] = ' CMD ', s = ' VIS ',
['t'] = ' TERM ', S = ' V-LINE ',
R = ' REPL ',
c = ' CMD ',
r = ' PROMPT ',
t = ' TERM ',
['!'] = ' SHELL ',
} }
local mode_hl_map = { local mode_hl_map = {
['n'] = 'StatusModeNormal', n = 'StatusModeNormal',
['i'] = 'StatusModeInsert', i = 'StatusModeInsert',
['v'] = 'StatusModeVisual', v = 'StatusModeVisual',
['V'] = 'StatusModeVisual', V = 'StatusModeVisual',
[''] = 'StatusModeVisual', ['^V'] = 'StatusModeVisual',
['R'] = 'StatusModeReplace', s = 'StatusModeVisual',
['c'] = 'StatusModeCommand', S = 'StatusModeVisual',
['t'] = 'StatusModeTerminal', ['^S'] = 'StatusModeVisual',
R = 'StatusModeReplace',
c = 'StatusModeCommand',
r = 'StatusModeCommand',
['!'] = 'StatusModeCommand',
t = 'StatusModeTerminal',
} }
--- Git branch (async, cached per buffer, refreshed every 5s) local function refresh_status(buf)
local function update_git_branch() local b = vim.b[buf]
if vim.bo.buftype ~= '' then local left, right = {}, {}
return
end
vim.system(
{ 'git', 'branch', '--show-current' },
{ text = true },
function(out)
vim.b.git_branch = (out.code == 0 and out.stdout or ''):gsub(
'%s+',
''
)
end
)
end
vim.uv.new_timer():start(5000, 5000, vim.schedule_wrap(update_git_branch))
vim.api.nvim_create_autocmd({ 'BufEnter', 'FocusGained' }, {
callback = function()
update_git_branch()
end,
})
--- LSP progress (Neovim 0.10+ built-in handler) if b.git_branch and b.git_branch ~= '' then
local progress = {} left[#left + 1] = '%#StatusGit# ' .. b.git_branch .. ' %*'
local spinner_frames = end
{ '⣾', '⣽', '⣻', '⢿', '⡿', '⣟', '⣯', '⣷' } local diff = b.git_diff
if diff then
if diff.added > 0 then
left[#left + 1] = '%#StatusGitAdded# +' .. diff.added .. '%*'
end
if diff.removed > 0 then
left[#left + 1] = '%#StatusGitRemoved# -' .. diff.removed .. '%*'
end
end
if b.recording then
right[#right + 1] = '%#StatusRecording# ' .. b.recording .. ' %*'
end
if b.diag_str then
right[#right + 1] = b.diag_str
end
if b.lsp_icon and b.lsp_icon ~= '' then
right[#right + 1] = '%#'
.. b.lsp_hl
.. '#'
.. b.lsp_icon
.. (b.lsp_name or '')
.. ' %*'
end
local frame = 0 b.status_left = #left > 0 and table.concat(left) or ''
--- Clean stale progress messages periodically b.status_right = #right > 0 and table.concat(right) or ''
local progress_timer = vim.uv.new_timer()
local function start_progress_timer()
if not progress_timer:is_active() then
progress_timer:start(0, 200, function()
local now = vim.loop.now()
for k, v in pairs(progress) do
local ttl = v.done and 2000 or 10000
if now - v.t > ttl then
progress[k] = nil
end
end
if next(progress) then
frame = (frame % #spinner_frames) + 1
vim.schedule(function()
vim.cmd('redrawstatus')
end)
else
progress_timer:stop()
vim.schedule(function()
vim.cmd('redrawstatus')
end)
end
end)
end
end end
vim.api.nvim_create_autocmd('LspProgress', { local lsp_icon = {
callback = function(ev) none = '',
local d = ev.data starting = '',
if not d then working = ' 󰄬 ',
return ready = ' 󰄭 ',
end }
local params = d.params local lsp_hl = {
if not params or not params.token then none = 'StatusLspNone',
return starting = 'StatusLspNone',
end working = 'StatusLspWorking',
local key = d.client_id .. ':' .. tostring(params.token) ready = 'StatusLspReady',
local value = params.value or {} }
if value.kind == 'begin' then local active_progress = {}
progress[key] = {
msg = (value.message or 'working...'):gsub('%%', '%%%%'), local function refresh_lsp(buf)
t = vim.loop.now(), local state = 'ready'
} local clients = vim.lsp.get_clients({ bufnr = buf })
start_progress_timer() if #clients == 0 then
elseif value.kind == 'report' then state = 'none'
local msg_parts = {} vim.b[buf].lsp_name = ''
if value.message then else
msg_parts[#msg_parts + 1] = value.message local names = {}
end for _, client in ipairs(clients) do
if value.percentage ~= nil then names[#names + 1] = client.name
msg_parts[#msg_parts + 1] = '(' .. value.percentage .. '%%)' local prog = active_progress[client.id]
end if prog == 'working' then
progress[key] = { state = 'working'
msg = table.concat(msg_parts, ' '), elseif prog == 'starting' and state ~= 'working' then
t = vim.loop.now(), state = 'starting'
} end
elseif value.kind == 'end' then vim.b[buf].lsp_name = table.concat(names, '/')
if progress[key] then end
progress[key].done = true end
end vim.b[buf].lsp_icon = lsp_icon[state]
vim.cmd('redrawstatus') vim.b[buf].lsp_hl = lsp_hl[state]
end refresh_status(buf)
end, end
})
vim.api.nvim_create_autocmd({ 'LspAttach', 'LspDetach' }, { vim.api.nvim_create_autocmd({ 'LspAttach', 'LspDetach' }, {
callback = function(args) callback = function(ev)
local names = {} if ev.event == 'LspAttach' then
for _, c in ipairs(vim.lsp.get_clients({ bufnr = args.buf })) do local cid = ev.data.client_id
table.insert(names, c.name) if not active_progress[cid] then
end active_progress[cid] = 'starting'
vim.b[args.buf].lsp_names = #names > 0 vim.defer_fn(function()
and (' ● ' .. table.concat(names, ', ') .. ' ') if active_progress[cid] == 'starting' then
or '' active_progress[cid] = nil
end, if vim.api.nvim_buf_is_valid(ev.buf) then
refresh_lsp(ev.buf)
end
end
end, 500) -- 500ms grace period to wait for LspProgress
end
elseif ev.event == 'LspDetach' then
active_progress[ev.data.client_id] = nil
end
refresh_lsp(ev.buf)
end,
}) })
local function lsp_section() vim.api.nvim_create_autocmd('LspProgress', {
local client_ids = {} callback = function(ev)
for _, c in local kind = ev.data.params.value and ev.data.params.value.kind
ipairs(vim.lsp.get_clients({ bufnr = vim.api.nvim_get_current_buf() })) if kind == 'begin' or kind == 'report' then
do active_progress[ev.data.client_id] = 'working'
client_ids[c.id] = true elseif kind == 'end' then
end active_progress[ev.data.client_id] = nil
local latest = nil else
for key, p in pairs(progress) do return
local cid = tonumber(key:match('^(%d+):')) end
if cid and client_ids[cid] then local client = vim.lsp.get_client_by_id(ev.data.client_id)
if not latest or p.t > latest.t then if client then
latest = p for buf in pairs(client.attached_buffers) do
end refresh_lsp(buf)
end end
end end
if latest and (not latest.done or (vim.loop.now() - latest.t < 2000)) then end,
return '%#StatusLspSpinner# ○ ' .. latest.msg .. ' %*' })
end
return '%#StatusLsp#' .. (vim.b.lsp_names or '') .. '%*' local BRANCH_ICON = ''
local function refresh_branch(buf)
local file = vim.api.nvim_buf_get_name(buf)
if file == '' or vim.bo[buf].buftype ~= '' then
vim.b[buf].git_branch = ''
return
end
local cwd = vim.fs.root(buf, '.git') or vim.fs.dirname(file)
vim.system(
{ 'git', 'branch', '--show-current' },
{ text = true, cwd = cwd },
vim.schedule_wrap(function(out)
if not vim.api.nvim_buf_is_valid(buf) then
return
end
local branch = (out.code == 0 and out.stdout or ''):gsub('%s+', '')
vim.b[buf].git_branch = branch ~= '' and (BRANCH_ICON .. branch)
or ''
refresh_status(buf)
end)
)
end end
local diag_cache = {} local function refresh_diff(buf)
local function build_diag_string(counts) local file = vim.api.nvim_buf_get_name(buf)
local parts = {} if file == '' or vim.bo[buf].buftype ~= '' then
if counts[1] and counts[1] > 0 then vim.b[buf].git_diff = nil
table.insert(parts, '%#StatusDiagError# E' .. counts[1] .. ' %*') return
end end
if counts[2] and counts[2] > 0 then local cwd = vim.fs.root(buf, '.git') or vim.fs.dirname(file)
table.insert(parts, '%#StatusDiagWarn# W' .. counts[2] .. ' %*') vim.system(
end { 'git', 'diff', '--numstat', 'HEAD', '--', file },
if counts[4] and counts[4] > 0 then { text = true, cwd = cwd },
table.insert(parts, '%#StatusDiagHint# H' .. counts[4] .. ' %*') vim.schedule_wrap(function(out)
end if not vim.api.nvim_buf_is_valid(buf) then
return table.concat(parts) return
end
if out.code ~= 0 or out.stdout == '' then
vim.b[buf].git_diff = nil
else
local added, removed = out.stdout:match('(%d+)%s+(%d+)')
if added and removed then
vim.b[buf].git_diff = {
added = tonumber(added) or 0,
removed = tonumber(removed) or 0,
}
else
vim.b[buf].git_diff = nil
end
end
refresh_status(buf)
end)
)
end end
local function update_diag_cache(ev) local function refresh_diag(buf)
diag_cache[ev.buf] = build_diag_string(vim.diagnostic.count(ev.buf)) local count = vim.diagnostic.count(buf)
local sev = vim.diagnostic.severity
local parts = {}
if (count[sev.ERROR] or 0) > 0 then
parts[#parts + 1] = '%#StatusDiagError# E' .. count[sev.ERROR] .. ' %*'
end
if (count[sev.WARN] or 0) > 0 then
parts[#parts + 1] = '%#StatusDiagWarn# W' .. count[sev.WARN] .. ' %*'
end
if (count[sev.HINT] or 0) > 0 then
parts[#parts + 1] = '%#StatusDiagHint# H' .. count[sev.HINT] .. ' %*'
end
vim.b[buf].diag_str = #parts > 0 and table.concat(parts) or ''
refresh_status(buf)
end end
vim.api.nvim_create_autocmd(
'DiagnosticChanged',
{ callback = update_diag_cache }
)
local function update_git_diff() vim.api.nvim_create_autocmd('DiagnosticChanged', {
if vim.bo.buftype ~= '' then callback = function(ev)
return refresh_diag(ev.buf)
end end,
local file = vim.fn.expand('%:p') })
if file == '' then
return vim.api.nvim_create_autocmd({ 'BufEnter', 'BufNewFile' }, {
end callback = function(ev)
vim.system( if vim.bo[ev.buf].buftype == '' then
{ 'git', 'diff', '--numstat', 'HEAD', '--', file }, refresh_branch(ev.buf)
{ text = true }, refresh_diff(ev.buf)
function(out) end
if out.code ~= 0 or out.stdout == '' then refresh_lsp(ev.buf)
vim.b.git_diff = nil refresh_diag(ev.buf)
return end,
end })
local added, removed = out.stdout:match('(%d+)%s+(%d+)') vim.api.nvim_create_autocmd('FocusGained', {
vim.b.git_diff = { callback = function()
added = tonumber(added) or 0, local buf = vim.api.nvim_get_current_buf()
removed = tonumber(removed) or 0, if vim.bo[buf].buftype == '' then
} refresh_branch(buf)
end end
) end,
end })
vim.api.nvim_create_autocmd({ 'BufEnter', 'FocusGained', 'BufWritePost' }, { vim.api.nvim_create_autocmd('BufWritePost', {
callback = update_git_diff, callback = function(ev)
refresh_diff(ev.buf)
end,
})
vim.api.nvim_create_autocmd('RecordingEnter', {
pattern = '*',
callback = function(ev)
vim.b[ev.buf].recording = 'Rec @' .. vim.fn.reg_recording()
refresh_status(ev.buf)
end,
})
vim.api.nvim_create_autocmd('RecordingLeave', {
pattern = '*',
callback = function(ev)
vim.b[ev.buf].recording = nil
refresh_status(ev.buf)
end,
}) })
function _G.__statusline() function _G.__statusline()
local m = vim.fn.mode() local m = vim.fn.mode()
local mode_hl = mode_hl_map[m] or 'StatusModeNormal' local key = (m == '\22' or m == '\19') and m or m:sub(1, 1)
local git = vim.b.git_branch or '' local hl = mode_hl_map[key] or 'StatusModeNormal'
local cur_buf = vim.api.nvim_get_current_buf() local b = vim.b
local parts = { return table.concat({
'%#' .. mode_hl .. '#' .. (mode_map[m] or ' ?? ') .. '%*', '%#' .. hl .. '#' .. (mode_map[key] or ' ?? ') .. '%*',
git ~= '' and ('%#StatusGit#  ' .. git .. ' %*') or '', b.status_left or '',
} '%=',
local diff = vim.b.git_diff b.status_right or '',
if diff and (diff.added > 0 or diff.removed > 0) then '%#StatusCursor# %l:%c ',
if diff.added > 0 then '%#' .. hl .. '# %p%% %*',
table.insert(parts, '%#StatusGitAdded# +' .. diff.added .. ' %*') })
end
if diff.removed > 0 then
table.insert(
parts,
'%#StatusGitRemoved# -' .. diff.removed .. ' %*'
)
end
end
table.insert(parts, lsp_section())
table.insert(parts, '%=')
local recording = vim.fn.reg_recording()
if recording ~= '' then
table.insert(
parts,
'%#StatusRecording# ● Rec @' .. recording .. ' %*'
)
end
table.insert(
parts,
diag_cache[cur_buf] or build_diag_string(vim.diagnostic.count(cur_buf))
)
table.insert(parts, '%#StatusCursor# %l:%-2c %*')
table.insert(parts, '%#' .. mode_hl .. '# %p%% %*')
return table.concat(parts)
end end
vim.o.statusline = '%!v:lua.__statusline()' vim.o.statusline = '%!v:lua.__statusline()'
require('incline').setup({
window = { margin = { vertical = 0, horizontal = 1 } },
hide = { cursorline = true },
render = function(props)
local filename = vim.fn.fnamemodify(vim.api.nvim_buf_get_name(props.buf), ":t")
if vim.bo[props.buf].modified then
filename = "[+] " .. filename
end
local icon, color = require("nvim-web-devicons").get_icon_color(filename)
return { { icon, guifg = color }, { " " }, { filename } }
end,
})
require('noice').setup({
lsp = {
override = {
['vim.lsp.util.convert_input_to_markdown_lines'] = true,
['vim.lsp.util.stylize_markdown'] = true,
},
},
presets = {
bottom_search = true, -- use a classic bottom cmdline for search
command_palette = true, -- position the cmdline and popupmenu together
long_message_to_split = true, -- long messages will be sent to a split
inc_rename = false, -- enables an input dialog for inc-rename.nvim
lsp_doc_border = false, -- add a border to hover docs and signature help
},
})
require('notify').setup({
background_colour = '#000000',
})
+15 -36
View File
@@ -9,12 +9,8 @@
"rev": "016802de402556da54c36bd7359b441266b01cdd", "rev": "016802de402556da54c36bd7359b441266b01cdd",
"src": "https://github.com/stevearc/conform.nvim" "src": "https://github.com/stevearc/conform.nvim"
}, },
"dropbar.nvim": {
"rev": "808ba31cde89aec8833e9789f5e04557cd31c9e1",
"src": "https://github.com/Bekaboo/dropbar.nvim"
},
"hardtime.nvim": { "hardtime.nvim": {
"rev": "5165840fe680eab46de1fc6dbff48f148fdcf018", "rev": "721a75b9a0c2eb1fb811d34507708ee315cb04eb",
"src": "https://github.com/m4xshen/hardtime.nvim" "src": "https://github.com/m4xshen/hardtime.nvim"
}, },
"incline.nvim": { "incline.nvim": {
@@ -30,21 +26,16 @@
"src": "https://github.com/brianhuster/live-preview.nvim" "src": "https://github.com/brianhuster/live-preview.nvim"
}, },
"mason-lspconfig.nvim": { "mason-lspconfig.nvim": {
"rev": "b5576cd62899a1a478d0e67ef3d378ee55dba82d", "rev": "b3298993d55fa194279b5eb9dbfb3a43da65cadf",
"src": "https://github.com/mason-org/mason-lspconfig.nvim" "src": "https://github.com/mason-org/mason-lspconfig.nvim"
}, },
"mason.nvim": { "mason.nvim": {
"rev": "2a6940af80375532e5e9e7c1f2fc6319a1b7a69d", "rev": "2a6940af80375532e5e9e7c1f2fc6319a1b7a69d",
"src": "https://github.com/mason-org/mason.nvim" "src": "https://github.com/mason-org/mason.nvim"
}, },
"mini.hipatterns": { "mini.nvim": {
"rev": "607d604e650cdf21d71f863d040c496a1d0cb320", "rev": "1345d191bb3da9c7b0e977f4387c5761f9bff68d",
"src": "https://github.com/nvim-mini/mini.hipatterns", "src": "https://github.com/nvim-mini/mini.nvim.git",
"version": ">=0.0.0"
},
"mini.pairs": {
"rev": "4a014143fcb4e9df26198ccb3ecff3b9e77a048c",
"src": "https://github.com/nvim-mini/mini.pairs",
"version": ">=0.0.0" "version": ">=0.0.0"
}, },
"noice.nvim": { "noice.nvim": {
@@ -56,52 +47,40 @@
"src": "https://github.com/MunifTanjim/nui.nvim" "src": "https://github.com/MunifTanjim/nui.nvim"
}, },
"nvim-lspconfig": { "nvim-lspconfig": {
"rev": "84b6b6c3f13cb34a6c8a0354b0da4c67d8ccf867", "rev": "3e8d598d3b5f8338a41699c436e5fa11d2666cf0",
"src": "https://github.com/neovim/nvim-lspconfig" "src": "https://github.com/neovim/nvim-lspconfig"
}, },
"nvim-notify": { "nvim-navic": {
"rev": "8701bece920b38ea289b457f902e2ad184131a5d", "rev": "455808fd0fae06e6d70fadfd61432275db8f34ce",
"src": "https://github.com/rcarriga/nvim-notify" "src": "https://github.com/SmiteshP/nvim-navic"
}, },
"nvim-tmux-navigation": { "nvim-tmux-navigation": {
"rev": "4898c98702954439233fdaf764c39636681e2861", "rev": "4898c98702954439233fdaf764c39636681e2861",
"src": "https://github.com/alexghergh/nvim-tmux-navigation" "src": "https://github.com/alexghergh/nvim-tmux-navigation"
}, },
"nvim-treesitter": { "nvim-treesitter": {
"rev": "5cb0114e6242625db56dd6440e945ed1ece10bc7", "rev": "910fdf6f49e9dee7e7257c7d11a76b040fdfb9de",
"src": "https://github.com/nvim-treesitter/nvim-treesitter" "src": "https://github.com/nvim-treesitter/nvim-treesitter"
}, },
"nvim-ts-autotag": { "nvim-ts-autotag": {
"rev": "88c1453db4ba7dd24131086fe51fdf74e587d275", "rev": "d7220b55e16ed3c04e88086256def5d282429493",
"src": "https://github.com/windwp/nvim-ts-autotag" "src": "https://github.com/windwp/nvim-ts-autotag"
}, },
"nvim-web-devicons": { "nvim-web-devicons": {
"rev": "5f032a85be210cd1c6ac98861eb3b187ff3bd5eb", "rev": "58447c1fca354bbf184425e4a8d01deecbd6f3c4",
"src": "https://github.com/nvim-tree/nvim-web-devicons" "src": "https://github.com/nvim-tree/nvim-web-devicons"
}, },
"plenary.nvim": {
"rev": "74b06c6c75e4eeb3108ec01852001636d85a932b",
"src": "https://github.com/nvim-lua/plenary.nvim"
},
"polydev": { "polydev": {
"rev": "2b30e36fade3272081f7166bc0ec614b0b7da1c9", "rev": "2b30e36fade3272081f7166bc0ec614b0b7da1c9",
"src": "https://git.moomancer.xyz/DarthMooMancer/polydev.git" "src": "https://git.moomancer.xyz/DarthMooMancer/polydev.git"
}, },
"telescope.nvim": { "snacks.nvim": {
"rev": "40aedd8a68c78a656a10a8d62d80c54af59420fb", "rev": "882c996cf28183f4d63640de0b4c02ec886d01f2",
"src": "https://github.com/nvim-telescope/telescope.nvim" "src": "https://github.com/folke/snacks.nvim"
}, },
"trouble.nvim": { "trouble.nvim": {
"rev": "bd67efe408d4816e25e8491cc5ad4088e708a69a", "rev": "bd67efe408d4816e25e8491cc5ad4088e708a69a",
"src": "https://github.com/folke/trouble.nvim" "src": "https://github.com/folke/trouble.nvim"
},
"undotree": {
"rev": "6fa6b57cda8459e1e4b2ca34df702f55242f4e4d",
"src": "https://github.com/mbbill/undotree"
},
"zen-mode.nvim": {
"rev": "8564ce6d29ec7554eb9df578efa882d33b3c23a7",
"src": "https://github.com/folke/zen-mode.nvim"
} }
} }
} }
BIN
View File
Binary file not shown.
-22
View File
@@ -13,28 +13,6 @@ set -g status-style 'bg=default' # Completely transparent container
set -g status-left-length 100 set -g status-left-length 100
set -g status-left "#[fg=#090E13,bg=colour6,bold] #S " set -g status-left "#[fg=#090E13,bg=colour6,bold] #S "
# palette = 0=#090E13
# palette = 1=#c4746e
# palette = 2=#8a9a7b
# palette = 3=#c4b28a
# palette = 4=#8ba4b0
# palette = 5=#a292a3
# palette = 6=#8ea4a2
# palette = 7=#a4a7a4
# palette = 8=#5C6066
# palette = 9=#e46876
# palette = 10=#87a987
# palette = 11=#e6c384
# palette = 12=#7fb4ca
# palette = 13=#938aa9
# palette = 14=#7aa89f
# palette = 15=#c5c9c7
#
# background = #090E13
# foreground = #c5c9c7
# cursor-color = #c5c9c7
# selection-background = #22262D
# selection-foreground = #c5c9c7
set -g status-right "" set -g status-right ""
+7 -34
View File
@@ -1,14 +1,3 @@
if [[ $(uname) != "Darwin" ]]; then
if [ -z "${WAYLAND_DISPLAY}" ] && [ "${XDG_VTNR}" -eq 1 ]; then
XDG_CURRENT_DESKTOP=sway dbus-run-session sway
fi
bindkey "^[[1;5C" forward-word
bindkey "^[[1;5D" backward-word
bindkey "^[[3~" delete-char
bindkey "^[[5~" up-line
bindkey "^[[6~" down-line
fi
HISTFILE=~/.zsh_history HISTFILE=~/.zsh_history
HISTSIZE=100 HISTSIZE=100
SAVEHIST=200 SAVEHIST=200
@@ -17,9 +6,7 @@ source "$HOME/.local/share/zinit/zinit.git/zinit.zsh"
zinit light zsh-users/zsh-autosuggestions zinit light zsh-users/zsh-autosuggestions
zinit light zdharma-continuum/fast-syntax-highlighting zinit light zdharma-continuum/fast-syntax-highlighting
if [[ $(uname) == "Darwin" ]]; then zinit light junegunn/fzf
zinit light junegunn/fzf
fi
eval "$(starship init zsh)" eval "$(starship init zsh)"
eval "$(zoxide init --cmd cd zsh)" eval "$(zoxide init --cmd cd zsh)"
@@ -30,32 +17,18 @@ autoload -Uz _zinit
export PATH="$HOME/.local/bin:$PATH" export PATH="$HOME/.local/bin:$PATH"
alias cat="bat" alias cat="bat"
alias rebuild="sudo darwin-rebuild switch --flake /etc/nix-darwin/#Andrews-MacBook-Air";
alias enix="nvim /etc/nix-darwin/flake.nix"
alias v="nvim" alias v="nvim"
alias ls="eza -a" alias ls="eza -a"
alias brew-update="brew update && brew upgrade && brew bundle --cleanup --zap --file=~/.Brewfile" alias brew-update="brew update && brew upgrade && brew bundle --cleanup --zap --file=~/.Brewfile"
alias cmake-update="sudo rm -rd build && cmake -S . -B build && cmake --build build" alias cmake-update="sudo rm -rd build && cmake -S . -B build && cmake --build build"
alias oasis="ssh oasis" alias oasis="ssh oasis"
# alias grep="rg" export MANPAGER="sh -c 'sed -u -e \"s/\\x1B\\[[0-9;]*m//g; s/.\\x08//g\" | bat -p -l man'"
# export HOMEBREW_NO_AUTO_UPDATE=1
if [[ $(uname) != "Darwin" ]]; then export HOMEBREW_NO_ENV_HINTS=1
alias update_world='doas emerge --ask --update --newuse --deep @world' export HOMEBREW_DISPLAY_INSTALL_TIMES=0
alias env="sh /home/andrew/personal/dotfiles/env_linux.sh" export HOMEBREW_CLEANUP_PERIODIC_FULL_DAYS=1
else export HOMEBREW_NO_EMOJI=1
alias env='sh ~/personal/dotfiles/env_mac.sh'
export MANPAGER="sh -c 'sed -u -e \"s/\\x1B\\[[0-9;]*m//g; s/.\\x08//g\" | bat -p -l man'"
# export PATH="$HOME/.flutter/bin/:$PATH"
export GOOGLE_CLOUD_PROJECT="development-477121"
export HOMEBREW_NO_AUTO_UPDATE=1
export HOMEBREW_NO_ENV_HINTS=1
export HOMEBREW_DISPLAY_INSTALL_TIMES=0
export HOMEBREW_CLEANUP_PERIODIC_FULL_DAYS=1
export HOMEBREW_NO_EMOJI=1
fi
### End of Zinit's installer chunk
# bun completions # bun completions
[ -s "/Users/andrew/.bun/_bun" ] && source "/Users/andrew/.bun/_bun" [ -s "/Users/andrew/.bun/_bun" ] && source "/Users/andrew/.bun/_bun"