Update fish aliases & keybinds, update git config, update Neovim config

Neovim:
- Replace typescript-tools with ts_ls
- Add Markview
- Modify Neo-tree keybinds
- Modify CodeCompanion models
- Add Svelte linting/fixing
This commit is contained in:
mitchell 2025-05-08 15:12:45 -04:00
parent 33da7ca122
commit e511802ea3
5 changed files with 58 additions and 23 deletions

View file

@ -1,6 +1,7 @@
function define_aliases -a uname -d 'Defines aliases for commonly used commands' function define_aliases -a uname -d 'Defines aliases for commonly used commands'
alias q exit alias q exit
alias cl clear alias cl clear
alias ls lsd
alias rcp 'rsync -aP' alias rcp 'rsync -aP'
alias vg vagrant alias vg vagrant
alias tf terraform alias tf terraform

View file

@ -1,5 +1,4 @@
function fish_user_key_bindings function fish_user_key_bindings
bind --mode insert jj "if commandline -P; commandline -f cancel; else; set fish_bind_mode default; commandline -f backward-char repaint-mode; end"
bind --mode insert comma,a 'ssh_add; commandline -f repaint' bind --mode insert comma,a 'ssh_add; commandline -f repaint'
bind --mode insert comma,p 'nvim +"Telescope git_files"; commandline -f repaint' bind --mode insert comma,p 'nvim +"Telescope git_files"; commandline -f repaint'
bind --mode insert comma,f 'nvim +"Telescope find_files"; commandline -f repaint' bind --mode insert comma,f 'nvim +"Telescope find_files"; commandline -f repaint'
@ -9,4 +8,5 @@ function fish_user_key_bindings
bind --mode insert comma,t 'fzf-file-widget' bind --mode insert comma,t 'fzf-file-widget'
bind --mode insert comma,r 'fzf-history-widget' bind --mode insert comma,r 'fzf-history-widget'
bind --mode insert comma,c 'fzf-cd-widget' bind --mode insert comma,c 'fzf-cd-widget'
bind --mode insert comma,l 'clear; commandline -f repaint'
end end

View file

@ -23,6 +23,7 @@ require("lazy").setup({
install = { colorscheme = { "kanagawa" } }, install = { colorscheme = { "kanagawa" } },
spec = { spec = {
-- UI and appearance -- UI and appearance
"edkolev/tmuxline.vim",
{ {
"rebelot/kanagawa.nvim", "rebelot/kanagawa.nvim",
lazy = false, lazy = false,
@ -98,7 +99,18 @@ require("lazy").setup({
}, },
}, },
}, },
"edkolev/tmuxline.vim", {
"OXY2DEV/markview.nvim",
lazy = false,
dependencies = { "saghen/blink.cmp" },
opts = {
preview = {
icon_provider = "devicons",
filetypes = { "markdown", "codecompanion" },
ignore_buftypes = {},
},
},
},
-- Editor enhancements -- Editor enhancements
{ {
@ -117,8 +129,9 @@ require("lazy").setup({
typescript = { "eslint", "stylelint", "biome" }, typescript = { "eslint", "stylelint", "biome" },
javascriptreact = { "eslint", "stylelint", "biome" }, javascriptreact = { "eslint", "stylelint", "biome" },
typescriptreact = { "eslint", "stylelint", "biome" }, typescriptreact = { "eslint", "stylelint", "biome" },
svelte = { "eslint" },
go = { "golint", "go vet" }, go = { "golint", "go vet" },
vue = { "eslint", "stylelint" }, vue = { "eslint", "stylelint", "biome" },
make = { "checkmake" }, make = { "checkmake" },
proto = { "protoc-gen-lint" }, proto = { "protoc-gen-lint" },
dockerfile = { "hadolint" }, dockerfile = { "hadolint" },
@ -129,7 +142,7 @@ require("lazy").setup({
cs = { "OmniSharp" }, cs = { "OmniSharp" },
terraform = { "tflint" }, terraform = { "tflint" },
ruby = { "rubocop" }, ruby = { "rubocop" },
css = { "stylelint" }, css = { "stylelint", "biome" },
sh = { "shellcheck" }, sh = { "shellcheck" },
python = { "pylint" }, python = { "pylint" },
} }
@ -141,8 +154,9 @@ require("lazy").setup({
typescript = { "prettier", "biome" }, typescript = { "prettier", "biome" },
javascriptreact = { "prettier", "biome" }, javascriptreact = { "prettier", "biome" },
typescriptreact = { "prettier", "biome" }, typescriptreact = { "prettier", "biome" },
vue = { "prettier" }, svelte = { "prettier" },
css = { "prettier" }, vue = { "prettier", "biome" },
css = { "prettier", "biome" },
yaml = { "prettier", "biome" }, yaml = { "prettier", "biome" },
json = { "prettier", "biome" }, json = { "prettier", "biome" },
dart = { "dartfmt" }, dart = { "dartfmt" },
@ -245,14 +259,14 @@ require("lazy").setup({
keys = { keys = {
{ {
"<leader>nn", "<leader>nn",
"<cmd>Neotree toggle git_status<cr>", "<cmd>Neotree toggle reveal_force_cwd<cr>",
desc = "Neo-tree Toggle Git Status", desc = "Neo-tree Toggle Sidebar",
silent = true, silent = true,
}, },
{ {
"<leader>np", "<leader>nf",
"<cmd>Neotree float reveal_force_cwd<cr>", "<cmd>Neotree float reveal_force_cwd<cr>",
desc = "Neo-tree Float Reveal CWD", desc = "Neo-tree Float",
silent = true, silent = true,
}, },
}, },
@ -369,6 +383,8 @@ require("lazy").setup({
"terraform", "terraform",
"yaml", "yaml",
"json", "json",
"markdown",
"markdown_inline",
}, },
auto_install = false, auto_install = false,
highlight = { highlight = {
@ -405,9 +421,9 @@ require("lazy").setup({
opts = { opts = {
display = { diff = { provider = "mini_diff" }, chat = { show_settings = true } }, display = { diff = { provider = "mini_diff" }, chat = { show_settings = true } },
strategies = { strategies = {
chat = { adapter = "anthro_deep" }, chat = { adapter = "gemini_deep" },
inline = { adapter = "anthro" }, inline = { adapter = "gemini" },
cmd = { adapter = "anthro" }, cmd = { adapter = "gemini" },
}, },
adapters = { adapters = {
anthro = function() anthro = function()
@ -424,10 +440,17 @@ require("lazy").setup({
}, },
}) })
end, end,
gemini = function()
return require("codecompanion.adapters").extend("gemini", {
schema = {
model = { default = "gemini-2.5-flash-preview-04-17" },
},
})
end,
gemini_deep = function() gemini_deep = function()
return require("codecompanion.adapters").extend("gemini", { return require("codecompanion.adapters").extend("gemini", {
schema = { schema = {
model = { default = "gemini-2.5-pro-preview-03-25" }, model = { default = "gemini-2.5-pro-preview-05-06" },
}, },
}) })
end, end,
@ -550,27 +573,40 @@ local capabilities = require("blink.cmp").get_lsp_capabilities()
local lsp_flags = { debounce_text_changes = 150 } local lsp_flags = { debounce_text_changes = 150 }
-- Unused for now -- Unused for now
local vue_plugin_location = vim.fn.expand("$HOME/.bun/install/global/node_modules/@vue/language-server") local vue_plugin_location = vim.fn.expand("$HOME/.bun/install/global/node_modules/@vue/typescript-plugin")
require("typescript-tools").setup({ vim.lsp.config("ts_ls", {
on_attach = on_attach, on_attach = on_attach,
flags = lsp_flags, flags = lsp_flags,
capabilities = capabilities, capabilities = capabilities,
filetypes = { filetypes = {
"typescript",
"javascript", "javascript",
"typescript",
"javascriptreact", "javascriptreact",
"typescriptreact", "typescriptreact",
"vue", "vue",
}, },
settings = { tsserver_plugins = { "@vue/typescript-plugin" } }, init_options = {
plugins = {
{
name = "@vue/typescript-plugin",
location = vue_plugin_location,
languages = { "javascript", "typescript", "vue" },
},
},
},
}) })
local servers = { "volar", "elixirls", "gopls", "pylsp" } vim.lsp.enable("ts_ls")
require("lspconfig").volar.setup({})
local servers = { "elixirls", "gopls", "pylsp", "svelte" }
for _, lsp in ipairs(servers) do for _, lsp in ipairs(servers) do
lspconfig[lsp].setup({ vim.lsp.config(lsp, {
on_attach = on_attach, on_attach = on_attach,
flags = lsp_flags, flags = lsp_flags,
capabilities = capabilities, capabilities = capabilities,
}) })
vim.lsp.enable(lsp)
end end

View file

@ -1,5 +1,5 @@
[alias] [alias]
co = checkout sw = switch
rs = restore rs = restore
rss = restore --staged rss = restore --staged
br = branch br = branch
@ -21,7 +21,6 @@
puff = pull --ff-only puff = pull --ff-only
merff = merge --ff-only merff = merge --ff-only
fa = fetch --all fa = fetch --all
pa = push --all
ap = add --patch ap = add --patch
[core] [core]

View file

@ -11,7 +11,6 @@ This repo contains my preferred configurations for:
- tmux - tmux
- git - git
- Wez's terminal - Wez's terminal
- Jetbrains vim plugin
- keepassxc - keepassxc
- bspwm (Linux) - bspwm (Linux)
- sxhkd (Linux) - sxhkd (Linux)