Compare commits
27 Commits
e3593a90aa
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
| 8da615fb2c | |||
| 921bd93db6 | |||
| a5ad1e90f5 | |||
| 21ddfdd09d | |||
| cf16908e4f | |||
| 185887d20d | |||
| 9399fde789 | |||
| b261344f4a | |||
| e4afa6b707 | |||
| 14aaf99bca | |||
| 341bf54dbf | |||
| 893583838f | |||
| 7074c72cb0 | |||
| 459c767e92 | |||
| 34439c0c91 | |||
| 3aec645b22 | |||
| c7955f36e5 | |||
| 0b08441563 | |||
| 08274e8ad8 | |||
| df2acf298b | |||
| 3e5e0c52cd | |||
| f087fd2bdb | |||
| 6af119073f | |||
| 9bd0c15301 | |||
| 582f657423 | |||
| f3dcabed0e | |||
| fc66dfa97b |
9
after/lsp/hls.lua
Normal file
9
after/lsp/hls.lua
Normal file
@@ -0,0 +1,9 @@
|
||||
return {
|
||||
filetypes = { "haskell", "lhaskell" },
|
||||
cmd = { "haskell-language-server-wrapper", "--lsp" },
|
||||
settings = {
|
||||
haskell = {
|
||||
formattingProvider = "fourmolu"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -115,7 +115,7 @@ call s:h('StatusLineNC', s:gray_7, s:gray_2, [s:attrs.italic])
|
||||
" call s:h('StatusLineTerm', s:none, s:bglighter, [s:attrs.bold])
|
||||
" call s:h('StatusLineTermNC', s:none, s:bglight)
|
||||
call s:h('WildMenu', s:none, s:gray_7)
|
||||
call s:h('Cursor', s:black, s:mauve)
|
||||
call s:h('Cursor', s:white, s:burgundy)
|
||||
call s:h('CursorLine', s:none, s:gray_1)
|
||||
call s:h('CursorColumn', s:none, s:gray_1)
|
||||
call s:h('CursorLineNr', s:yellow, s:none)
|
||||
|
||||
61
flake.lock
generated
Normal file
61
flake.lock
generated
Normal file
@@ -0,0 +1,61 @@
|
||||
{
|
||||
"nodes": {
|
||||
"flake-utils": {
|
||||
"inputs": {
|
||||
"systems": "systems"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1731533236,
|
||||
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1762977756,
|
||||
"narHash": "sha256-4PqRErxfe+2toFJFgcRKZ0UI9NSIOJa+7RXVtBhy4KE=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "c5ae371f1a6a7fd27823bc500d9390b38c05fa55",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixos-unstable",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"flake-utils": "flake-utils",
|
||||
"nixpkgs": "nixpkgs"
|
||||
}
|
||||
},
|
||||
"systems": {
|
||||
"locked": {
|
||||
"lastModified": 1681028828,
|
||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"type": "github"
|
||||
}
|
||||
}
|
||||
},
|
||||
"root": "root",
|
||||
"version": 7
|
||||
}
|
||||
24
flake.nix
Normal file
24
flake.nix
Normal file
@@ -0,0 +1,24 @@
|
||||
{
|
||||
description = "Neovim Setup Flake";
|
||||
|
||||
inputs = {
|
||||
nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable";
|
||||
flake-utils.url = "github:numtide/flake-utils";
|
||||
};
|
||||
|
||||
outputs = { self, nixpkgs, flake-utils }:
|
||||
flake-utils.lib.eachDefaultSystem (system:
|
||||
let pkgs = nixpkgs.legacyPackages.${system};
|
||||
in {
|
||||
devShells.default = pkgs.mkShell {
|
||||
name = "nvim-setup";
|
||||
|
||||
buildInputs = with pkgs; [
|
||||
gcc
|
||||
lua51Packages.lua
|
||||
lua51Packages.luarocks
|
||||
];
|
||||
};
|
||||
});
|
||||
}
|
||||
|
||||
5
init.lua
5
init.lua
@@ -4,12 +4,15 @@ vim.cmd("colorscheme pop-punk")
|
||||
vim.opt.tabstop = 4
|
||||
vim.opt.shiftwidth = 4
|
||||
vim.opt.expandtab = true
|
||||
vim.opt.messagesopt = "wait:30,history:500"
|
||||
vim.cmd("set relativenumber")
|
||||
vim.cmd("set number")
|
||||
vim.cmd("set cursorline")
|
||||
vim.cmd("set mouse=a")
|
||||
vim.cmd("set clipboard+=unnamedplus")
|
||||
|
||||
vim.g.python3_host_prog = 'python3.13'
|
||||
|
||||
vim.api.nvim_set_hl(0, "Normal", { bg = "#040404" })
|
||||
vim.api.nvim_set_hl(0, "CursorLine", { bg = "#101010", fg = nil })
|
||||
|
||||
@@ -64,4 +67,4 @@ vim.api.nvim_create_autocmd("TextYankPost", {
|
||||
|
||||
require("config.keymaps")
|
||||
require("config.lazy")
|
||||
require("config.lazy")
|
||||
require("config.hpack")
|
||||
|
||||
@@ -1,34 +1,50 @@
|
||||
{
|
||||
"Comment.nvim": { "branch": "master", "commit": "e30b7f2008e52442154b66f7c519bfd2f1e32acb" },
|
||||
"Korean-IME.nvim": { "branch": "master", "commit": "c733599b9219e25bb05d8aa0467327edc769be94" },
|
||||
"blink.cmp": { "branch": "main", "commit": "bae4bae0eedd1fa55f34b685862e94a222d5c6f8" },
|
||||
"blink.download": { "branch": "main", "commit": "86361b98f3c8317904a08e3bd12cf3cdcbe3e925" },
|
||||
"blink.nvim": { "branch": "main", "commit": "16a597e89cf2ee6215a392c5bc5a945477015534" },
|
||||
"blink.pairs": { "branch": "main", "commit": "d8bf802cca951f0a3b72ddeed21bc5a1d5353f65" },
|
||||
"FixCursorHold.nvim": { "branch": "master", "commit": "1900f89dc17c603eec29960f57c00bd9ae696495" },
|
||||
"Korean-IME.nvim": { "branch": "master", "commit": "1367a854123463f1b0339255aef4012505cd45c2" },
|
||||
"aerial.nvim": { "branch": "master", "commit": "8bb8697d180681746da41bef5c8691d04443af36" },
|
||||
"blink.cmp": { "branch": "main", "commit": "b19413d214068f316c78978b08264ed1c41830ec" },
|
||||
"blink.nvim": { "branch": "main", "commit": "d1e7c7c45d45c6b6a25427bf62db4db73b03ff3d" },
|
||||
"bufferline.nvim": { "branch": "main", "commit": "655133c3b4c3e5e05ec549b9f8cc2894ac6f51b3" },
|
||||
"cmdhistory.nvim": { "branch": "master", "commit": "26d3fbbe53c00422be64afb24cc9228062740074" },
|
||||
"copilot.vim": { "branch": "release", "commit": "206011a8bc5078a02560d5c44177e9849e8f8d6c" },
|
||||
"diffview.nvim": { "branch": "main", "commit": "4516612fe98ff56ae0415a259ff6361a89419b0a" },
|
||||
"friendly-snippets": { "branch": "main", "commit": "572f5660cf05f8cd8834e096d7b4c921ba18e175" },
|
||||
"fzf-lua": { "branch": "main", "commit": "d6e899e8dfdaf47bf849c0875ca3ca0e5a0e0d12" },
|
||||
"gitsigns.nvim": { "branch": "main", "commit": "6e3c66548035e50db7bd8e360a29aec6620c3641" },
|
||||
"fzf-lua": { "branch": "main", "commit": "9a0704e8af8f8442110ff22a83b5608366b235df" },
|
||||
"gitsigns.nvim": { "branch": "main", "commit": "5813e4878748805f1518cee7abb50fd7205a3a48" },
|
||||
"glance.nvim": { "branch": "master", "commit": "bf86d8b79dce808e65fdb6e9269d0b4ed6d2eefc" },
|
||||
"hardtime.nvim": { "branch": "main", "commit": "b4e431934af1fe224a3a801f632c008278cb7628" },
|
||||
"lazy.nvim": { "branch": "main", "commit": "6c3bda4aca61a13a9c63f1c1d1b16b9d3be90d7a" },
|
||||
"haskell-mod.nvim": { "branch": "main", "commit": "f403618030ef9687e63eecfca7798e53b969f763" },
|
||||
"hererocks": { "branch": "master", "commit": "1cefef350109770ffa39e064e0eae5c28a1f5455" },
|
||||
"image.nvim": { "branch": "master", "commit": "446a8a5cc7a3eae3185ee0c697732c32a5547a0b" },
|
||||
"lazy.nvim": { "branch": "main", "commit": "85c7ff3711b730b4030d03144f6db6375044ae82" },
|
||||
"lazydev.nvim": { "branch": "main", "commit": "5231c62aa83c2f8dc8e7ba957aa77098cda1257d" },
|
||||
"lazygit.nvim": { "branch": "main", "commit": "2305deed25bc61b866d5d39189e9105a45cf1cfb" },
|
||||
"lsp-lens.nvim": { "branch": "main", "commit": "48bb1a7e271424c15f3d588d54adc9b7c319d977" },
|
||||
"lualine.nvim": { "branch": "master", "commit": "b8c23159c0161f4b89196f74ee3a6d02cdc3a955" },
|
||||
"mason-lspconfig.nvim": { "branch": "main", "commit": "1ec4da522fa49dcecee8d190efda273464dd2192" },
|
||||
"mason.nvim": { "branch": "main", "commit": "7dc4facca9702f95353d5a1f87daf23d78e31c2a" },
|
||||
"neo-tree.nvim": { "branch": "v3.x", "commit": "cea666ef965884414b1b71f6b39a537f9238bdb2" },
|
||||
"neoconf.nvim": { "branch": "main", "commit": "5aeca07ecb2f506d32e81eb82b0ed384ac2a53c5" },
|
||||
"lualine.nvim": { "branch": "master", "commit": "47f91c416daef12db467145e16bed5bbfe00add8" },
|
||||
"mason-lspconfig.nvim": { "branch": "main", "commit": "7d527c76c43f46294de9c19d39c5a86317809b4b" },
|
||||
"mason.nvim": { "branch": "main", "commit": "57e5a8addb8c71fb063ee4acda466c7cf6ad2800" },
|
||||
"mcphub.nvim": { "branch": "main", "commit": "5193329d510a68f1f5bf189960642c925c177a3a" },
|
||||
"molten-nvim": { "branch": "main", "commit": "4fd7be6a12b5efda5179db642f13bad60893acca" },
|
||||
"neo-tree.nvim": { "branch": "v3.x", "commit": "f3df514fff2bdd4318127c40470984137f87b62e" },
|
||||
"neoconf.nvim": { "branch": "main", "commit": "3fdd84804c397059d4698fd8933f443058c4858e" },
|
||||
"neodev.nvim": { "branch": "main", "commit": "46aa467dca16cf3dfe27098042402066d2ae242d" },
|
||||
"neotest": { "branch": "master", "commit": "deadfb1af5ce458742671ad3a013acb9a6b41178" },
|
||||
"nui.nvim": { "branch": "main", "commit": "de740991c12411b663994b2860f1a4fd0937c130" },
|
||||
"nvim-highlight-colors": { "branch": "main", "commit": "b42a5ccec7457b44e89f7ed3b3afb1b375bb2093" },
|
||||
"nvim-lspconfig": { "branch": "master", "commit": "61fdd3a8609071ce44519e405f3424d84ec94d9d" },
|
||||
"nvim-treesitter": { "branch": "main", "commit": "32cb9f9b9db71b0dc2454817727cd9a5d840658c" },
|
||||
"nvim-web-devicons": { "branch": "master", "commit": "c2599a81ecabaae07c49ff9b45dcd032a8d90f1a" },
|
||||
"outline.nvim": { "branch": "main", "commit": "6b62f73a6bf317531d15a7ae1b724e85485d8148" },
|
||||
"nvim-autopairs": { "branch": "master", "commit": "7a2c97cccd60abc559344042fefb1d5a85b3e33b" },
|
||||
"nvim-highlight-colors": { "branch": "main", "commit": "e0c4a58ec8c3ca7c92d3ee4eb3bc1dd0f7be317e" },
|
||||
"nvim-lspconfig": { "branch": "master", "commit": "07f4e93de92e8d4ea7ab99602e3a8c9ac0fb778a" },
|
||||
"nvim-nio": { "branch": "master", "commit": "21f5324bfac14e22ba26553caf69ec76ae8a7662" },
|
||||
"nvim-tree.lua": { "branch": "master", "commit": "3fb91e18a727ecc0385637895ec397dea90be42a" },
|
||||
"nvim-tree.lua-float-preview": { "branch": "master", "commit": "78b3ff2e0423438a341c9628f2f10f51b80a69c6" },
|
||||
"nvim-treesitter": { "branch": "main", "commit": "17885756e63df73ed90db62e4630f744ceda6514" },
|
||||
"nvim-unception": { "branch": "main", "commit": "df0e505f0f1371c49c2bcf993985962edb5a279d" },
|
||||
"nvim-web-devicons": { "branch": "master", "commit": "8dcb311b0c92d460fac00eac706abd43d94d68af" },
|
||||
"peek.nvim": { "branch": "master", "commit": "5820d937d5414baea5f586dc2a3d912a74636e5b" },
|
||||
"plenary.nvim": { "branch": "master", "commit": "b9fd5226c2f76c951fc8ed5923d85e4de065e509" },
|
||||
"snacks.nvim": { "branch": "main", "commit": "bc0630e43be5699bb94dadc302c0d21615421d93" },
|
||||
"sidekick.nvim": { "branch": "main", "commit": "c2bdf8cfcd87a6be5f8b84322c1b5052e78e302e" },
|
||||
"snacks.nvim": { "branch": "main", "commit": "fe7cfe9800a182274d0f868a74b7263b8c0c020b" },
|
||||
"toggleterm.nvim": { "branch": "main", "commit": "50ea089fc548917cc3cc16b46a8211833b9e3c7c" },
|
||||
"trouble.nvim": { "branch": "main", "commit": "85bedb7eb7fa331a2ccbecb9202d8abba64d37b3" },
|
||||
"which-key.nvim": { "branch": "main", "commit": "fcbf4eea17cb299c02557d576f0d568878e354a4" },
|
||||
"yazi.nvim": { "branch": "main", "commit": "8f44537f60431a7d6e099b8b3e93fc825dde17a1" }
|
||||
"trouble.nvim": { "branch": "main", "commit": "bd67efe408d4816e25e8491cc5ad4088e708a69a" },
|
||||
"which-key.nvim": { "branch": "main", "commit": "3aab2147e74890957785941f0c1ad87d0a44c15a" }
|
||||
}
|
||||
|
||||
13
lua/config/hpack.lua
Normal file
13
lua/config/hpack.lua
Normal file
@@ -0,0 +1,13 @@
|
||||
local function hpack()
|
||||
vim.fn.system("hpack")
|
||||
end
|
||||
|
||||
vim.api.nvim_create_autocmd("BufWritePost", {
|
||||
pattern = "package.yaml",
|
||||
callback = hpack,
|
||||
})
|
||||
|
||||
vim.api.nvim_create_autocmd("BufEnter", {
|
||||
pattern = "*.hs",
|
||||
callback = hpack,
|
||||
})
|
||||
@@ -1,6 +1,8 @@
|
||||
-- LSP keymaps
|
||||
local opts = { noremap = true, silent = true }
|
||||
|
||||
vim.g.mapleader = " "
|
||||
|
||||
-- Go to definition
|
||||
vim.keymap.set("n", "gd", vim.lsp.buf.definition, opts)
|
||||
|
||||
@@ -23,4 +25,22 @@ vim.keymap.set("n", "<C-k>", vim.lsp.buf.signature_help, opts)
|
||||
vim.keymap.set("n", "<leader>rn", vim.lsp.buf.rename, opts)
|
||||
|
||||
-- Code actions
|
||||
vim.keymap.set("n", "<leader>ca", vim.lsp.buf.code_action, opts)
|
||||
vim.keymap.set("n", "ca", vim.lsp.buf.code_action, opts)
|
||||
|
||||
-- Show floating error
|
||||
vim.keymap.set("n", "E", vim.diagnostic.open_float, opts)
|
||||
|
||||
-- Window navigation with Ctrl + hjkl
|
||||
vim.keymap.set('n', '<C-h>', '<C-w>h', opts)
|
||||
vim.keymap.set('n', '<C-j>', '<C-w>j', opts)
|
||||
vim.keymap.set('n', '<C-k>', '<C-w>k', opts)
|
||||
vim.keymap.set('n', '<C-l>', '<C-w>l', opts)
|
||||
|
||||
vim.keymap.set('t', '<Esc>', function()
|
||||
if vim.b.term_title and vim.b.term_title:match("ellij") then
|
||||
return "<Esc>"
|
||||
end
|
||||
return "<C-\\><C-n>"
|
||||
end, { expr = true, silent = true })
|
||||
|
||||
vim.keymap.set('t', '<C-Esc>', "<C-\\><C-n>", opts)
|
||||
|
||||
22
lua/plugins/aerial.lua
Normal file
22
lua/plugins/aerial.lua
Normal file
@@ -0,0 +1,22 @@
|
||||
return {
|
||||
'stevearc/aerial.nvim',
|
||||
opts = {
|
||||
backends = { "treesitter", "lsp", "markdown", "asciidoc", "man" },
|
||||
|
||||
layout = {
|
||||
min_width = 0.9
|
||||
},
|
||||
|
||||
float = {
|
||||
relative = "win",
|
||||
min_height = 0.9
|
||||
},
|
||||
},
|
||||
dependencies = {
|
||||
"nvim-treesitter/nvim-treesitter",
|
||||
"nvim-tree/nvim-web-devicons"
|
||||
},
|
||||
keys = {
|
||||
{ "\\", "<Cmd>AerialToggle float<CR>", desc = "Aerial toggle floating" }
|
||||
},
|
||||
}
|
||||
@@ -56,6 +56,20 @@ return {
|
||||
-- elsewhere in your config, without redefining it, due to `opts_extend`
|
||||
sources = {
|
||||
default = { 'lsp', 'path', 'snippets', 'buffer' },
|
||||
providers = {
|
||||
path = {
|
||||
module = 'blink.cmp.sources.path',
|
||||
score_offset = 3,
|
||||
fallbacks = { 'buffer' },
|
||||
opts = {
|
||||
trailing_slash = true,
|
||||
label_trailing_slash = true,
|
||||
get_cwd = function(context) return vim.fn.expand(('#%d:p:h'):format(context.bufnr)) end,
|
||||
show_hidden_files_by_default = true,
|
||||
ignore_root_slash = true,
|
||||
}
|
||||
}
|
||||
},
|
||||
},
|
||||
|
||||
-- (Default) Rust fuzzy matcher for typo resistance and significantly better performance
|
||||
|
||||
@@ -1,46 +0,0 @@
|
||||
return {
|
||||
'saghen/blink.pairs',
|
||||
version = '*', -- (recommended) only required with prebuilt binaries
|
||||
|
||||
-- download prebuilt binaries from github releases
|
||||
dependencies = 'saghen/blink.download',
|
||||
-- OR build from source, requires nightly:
|
||||
-- https://rust-lang.github.io/rustup/concepts/channels.html#working-with-nightly-rust
|
||||
-- build = 'cargo build --release',
|
||||
-- If you use nix, you can build from source using latest nightly rust with:
|
||||
-- build = 'nix run .#build-plugin',
|
||||
|
||||
--- @module 'blink.pairs'
|
||||
--- @type blink.pairs.Config
|
||||
opts = {
|
||||
mappings = {
|
||||
-- you can call require("blink.pairs.mappings").enable()
|
||||
-- and require("blink.pairs.mappings").disable()
|
||||
-- to enable/disable mappings at runtime
|
||||
enabled = true,
|
||||
-- or disable with `vim.g.pairs = false` (global) and `vim.b.pairs = false` (per-buffer)
|
||||
-- and/or with `vim.g.blink_pairs = false` and `vim.b.blink_pairs = false`
|
||||
disabled_filetypes = {},
|
||||
-- see the defaults:
|
||||
-- https://github.com/Saghen/blink.pairs/blob/main/lua/blink/pairs/config/mappings.lua#L14
|
||||
pairs = {},
|
||||
},
|
||||
highlights = {
|
||||
enabled = true,
|
||||
-- requires require('vim._extui').enable({}), otherwise has no effect
|
||||
groups = {
|
||||
'BlinkPairsOrange',
|
||||
'BlinkPairsPurple',
|
||||
'BlinkPairsBlue',
|
||||
},
|
||||
|
||||
-- highlights matching pairs under the cursor
|
||||
matchparen = {
|
||||
enabled = true,
|
||||
-- known issue where typing won't update matchparen highlight, disabled by default
|
||||
group = 'BlinkPairsMatchParen',
|
||||
},
|
||||
},
|
||||
debug = false,
|
||||
}
|
||||
}
|
||||
17
lua/plugins/cmdhistory.lua
Normal file
17
lua/plugins/cmdhistory.lua
Normal file
@@ -0,0 +1,17 @@
|
||||
return {
|
||||
"kimpure/cmdhistory.nvim",
|
||||
opts = {
|
||||
mute = {
|
||||
"q",
|
||||
"qa",
|
||||
"wq",
|
||||
"wqa",
|
||||
"wincmd h",
|
||||
"wincmd j",
|
||||
"wincmd k",
|
||||
"wincmd l",
|
||||
"w",
|
||||
"wa",
|
||||
},
|
||||
}
|
||||
}
|
||||
3
lua/plugins/copilot.lua
Normal file
3
lua/plugins/copilot.lua
Normal file
@@ -0,0 +1,3 @@
|
||||
return {
|
||||
'github/copilot.vim',
|
||||
}
|
||||
10
lua/plugins/diffview.lua
Normal file
10
lua/plugins/diffview.lua
Normal file
@@ -0,0 +1,10 @@
|
||||
return {
|
||||
"sindrets/diffview.nvim",
|
||||
dependencies = { "nvim-tree/nvim-web-devicons" },
|
||||
opts = {},
|
||||
keys = {
|
||||
{ "<leader>dvo", "<Cmd>DiffviewOpen<CR>", desc = "Open Diff view" },
|
||||
{ "<leader>dvc", "<Cmd>DiffviewClose<CR>", desc = "Close Diff view" },
|
||||
{ "<leader>dvf", "<Cmd>DiffviewFocusFiles<CR>", desc = "Focus file in Diff view" },
|
||||
},
|
||||
}
|
||||
@@ -4,5 +4,8 @@ return {
|
||||
dependencies = { "nvim-tree/nvim-web-devicons" },
|
||||
-- or if using mini.icons/mini.nvim
|
||||
-- dependencies = { "echasnovski/mini.icons" },
|
||||
opts = {}
|
||||
opts = {},
|
||||
keys = {
|
||||
{ "<leader>fg", "<Cmd>FzfLua live_grep<CR>", desc = "FZF Live Grep" },
|
||||
},
|
||||
}
|
||||
|
||||
10
lua/plugins/glance.lua
Normal file
10
lua/plugins/glance.lua
Normal file
@@ -0,0 +1,10 @@
|
||||
return {
|
||||
'dnlhc/glance.nvim',
|
||||
cmd = 'Glance',
|
||||
keys = {
|
||||
{ "gd", "<CMD>Glance definitions<CR>", desc = "Glance definitions" },
|
||||
{ "gr", "<CMD>Glance references<CR>", desc = "Glance references" },
|
||||
{ "gy", "<CMD>Glance type_definitions<CR>", desc = "Glance type definitions" },
|
||||
{ "gm", "<CMD>Glance implementations<CR>", desc = "Glance implementations" },
|
||||
},
|
||||
}
|
||||
12
lua/plugins/haskell-mod.lua
Normal file
12
lua/plugins/haskell-mod.lua
Normal file
@@ -0,0 +1,12 @@
|
||||
local prod = {
|
||||
"mincomk/haskell-mod.nvim",
|
||||
config = true
|
||||
}
|
||||
|
||||
local dev = {
|
||||
dir = "~/projects/haskell-mod.nvim/",
|
||||
name = "haskell-mod.nvim",
|
||||
config = true
|
||||
}
|
||||
|
||||
return prod
|
||||
@@ -3,7 +3,7 @@ return {
|
||||
keys = {
|
||||
-- lazy load on 한영전환
|
||||
{
|
||||
"<f12>",
|
||||
"<f9>",
|
||||
function()
|
||||
require("korean_ime").change_mode()
|
||||
end,
|
||||
@@ -14,7 +14,7 @@ return {
|
||||
config = function()
|
||||
require("korean_ime").setup()
|
||||
|
||||
vim.keymap.set("i", "<f9>", function()
|
||||
vim.keymap.set("i", "<f12>", function()
|
||||
require("korean_ime").convert_hanja()
|
||||
end, { noremap = true, silent = true, desc = "한자" })
|
||||
end,
|
||||
|
||||
11
lua/plugins/lazydev.lua
Normal file
11
lua/plugins/lazydev.lua
Normal file
@@ -0,0 +1,11 @@
|
||||
return {
|
||||
"folke/lazydev.nvim",
|
||||
ft = "lua", -- only load on lua files
|
||||
opts = {
|
||||
library = {
|
||||
-- See the configuration section for more details
|
||||
-- Load luvit types when the `vim.uv` word is found
|
||||
{ path = "${3rd}/luv/library", words = { "vim%.uv" } },
|
||||
},
|
||||
},
|
||||
}
|
||||
@@ -1,32 +1,31 @@
|
||||
return {
|
||||
'neovim/nvim-lspconfig',
|
||||
dependencies = { 'saghen/blink.cmp' },
|
||||
'neovim/nvim-lspconfig',
|
||||
dependencies = { 'saghen/blink.cmp' },
|
||||
|
||||
lazy = false,
|
||||
lazy = false,
|
||||
|
||||
-- example using `opts` for defining servers
|
||||
opts = {
|
||||
inlay_hints = { enabled = true },
|
||||
servers = {
|
||||
lua_ls = {}
|
||||
}
|
||||
},
|
||||
config = function(_, opts)
|
||||
local lspconfig = require('lspconfig')
|
||||
for server, config in pairs(opts.servers) do
|
||||
-- passing config.capabilities to blink.cmp merges with the capabilities in your
|
||||
-- `opts[server].capabilities, if you've defined it
|
||||
config.capabilities = require('blink.cmp').get_lsp_capabilities(config.capabilities)
|
||||
lspconfig[server].setup(config)
|
||||
end
|
||||
-- example using `opts` for defining servers
|
||||
opts = {
|
||||
inlay_hints = { enabled = true },
|
||||
servers = {
|
||||
lua_ls = {}
|
||||
}
|
||||
},
|
||||
config = function(_, opts)
|
||||
for server, config in pairs(opts.servers) do
|
||||
-- passing config.capabilities to blink.cmp merges with the capabilities in your
|
||||
-- `opts[server].capabilities, if you've defined it
|
||||
config.capabilities = require('blink.cmp').get_lsp_capabilities(config.capabilities)
|
||||
vim.lsp.config(server, config)
|
||||
end
|
||||
|
||||
end,
|
||||
local capabilities = require('blink.cmp').get_lsp_capabilities()
|
||||
|
||||
-- example calling setup directly for each LSP
|
||||
config = function()
|
||||
local capabilities = require('blink.cmp').get_lsp_capabilities()
|
||||
local lspconfig = require('lspconfig')
|
||||
vim.lsp.config("clangd", {
|
||||
capabilities = capabilities,
|
||||
cmd = { vim.fn.stdpath("config") .. "/shell/clangd-direnv.sh" }
|
||||
})
|
||||
|
||||
lspconfig['lua_ls'].setup({ capabilities = capabilities })
|
||||
end
|
||||
vim.lsp.enable("hls")
|
||||
end,
|
||||
}
|
||||
|
||||
@@ -2,6 +2,7 @@ return {
|
||||
"mason-org/mason-lspconfig.nvim",
|
||||
opts = {
|
||||
ensure_installed = { "lua_ls", "rust_analyzer", "ts_ls" },
|
||||
automatic_enable = { exclude = { "clangd" } }
|
||||
},
|
||||
lazy = false,
|
||||
dependencies = {
|
||||
|
||||
17
lua/plugins/mcp-hub.lua
Normal file
17
lua/plugins/mcp-hub.lua
Normal file
@@ -0,0 +1,17 @@
|
||||
return {
|
||||
"ravitemer/mcphub.nvim",
|
||||
dependencies = {
|
||||
"nvim-lua/plenary.nvim",
|
||||
},
|
||||
build = "pnpm install -g mcp-hub@latest", -- Installs `mcp-hub` node binary globally
|
||||
opts = {
|
||||
extensions = {
|
||||
copilotchat = {
|
||||
enabled = true,
|
||||
convert_tools_to_functions = true,
|
||||
convert_resources_to_functions = true,
|
||||
add_mcp_prefix = false,
|
||||
}
|
||||
}
|
||||
},
|
||||
}
|
||||
9
lua/plugins/neotest.lua
Normal file
9
lua/plugins/neotest.lua
Normal file
@@ -0,0 +1,9 @@
|
||||
return {
|
||||
"nvim-neotest/neotest",
|
||||
dependencies = {
|
||||
"nvim-neotest/nvim-nio",
|
||||
"nvim-lua/plenary.nvim",
|
||||
"antoinemadec/FixCursorHold.nvim",
|
||||
"nvim-treesitter/nvim-treesitter"
|
||||
}
|
||||
}
|
||||
5
lua/plugins/nvim-autopairs.lua
Normal file
5
lua/plugins/nvim-autopairs.lua
Normal file
@@ -0,0 +1,5 @@
|
||||
return {
|
||||
'windwp/nvim-autopairs',
|
||||
event = "InsertEnter",
|
||||
config = true
|
||||
}
|
||||
67
lua/plugins/nvim-tree.lua
Normal file
67
lua/plugins/nvim-tree.lua
Normal file
@@ -0,0 +1,67 @@
|
||||
return {
|
||||
"nvim-tree/nvim-tree.lua",
|
||||
dependencies = {
|
||||
{
|
||||
"JMarkin/nvim-tree.lua-float-preview",
|
||||
lazy = true,
|
||||
-- default
|
||||
opts = {
|
||||
-- Whether the float preview is enabled by default. When set to false, it has to be "toggled" on.
|
||||
toggled_on = true,
|
||||
-- wrap nvimtree commands
|
||||
wrap_nvimtree_commands = true,
|
||||
-- lines for scroll
|
||||
scroll_lines = 20,
|
||||
-- window config
|
||||
window = {
|
||||
style = "minimal",
|
||||
relative = "win",
|
||||
border = "rounded",
|
||||
wrap = false,
|
||||
},
|
||||
mapping = {
|
||||
-- scroll down float buffer
|
||||
down = { "<C-d>" },
|
||||
-- scroll up float buffer
|
||||
up = { "<C-e>", "<C-u>" },
|
||||
-- enable/disable float windows
|
||||
toggle = { "<C-x>" },
|
||||
},
|
||||
-- hooks if return false preview doesn't shown
|
||||
hooks = {
|
||||
pre_open = function(path)
|
||||
-- if file > 5 MB or not text -> not preview
|
||||
local size = require("float-preview.utils").get_size(path)
|
||||
if type(size) ~= "number" then
|
||||
return false
|
||||
end
|
||||
local is_text = require("float-preview.utils").is_text(path)
|
||||
return size < 5 and is_text
|
||||
end,
|
||||
post_open = function(bufnr)
|
||||
return true
|
||||
end,
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
opts = {
|
||||
view = {
|
||||
relativenumber = true,
|
||||
},
|
||||
renderer = {
|
||||
group_empty = true,
|
||||
},
|
||||
filters = {
|
||||
dotfiles = false,
|
||||
},
|
||||
actions = {
|
||||
open_file = {
|
||||
quit_on_open = true
|
||||
}
|
||||
}
|
||||
},
|
||||
keys = {
|
||||
{ ";", function() require("nvim-tree.api").tree.toggle({ focus = true }) end, desc = "Toggle nvim tree" }
|
||||
},
|
||||
}
|
||||
@@ -1,11 +0,0 @@
|
||||
return {
|
||||
"hedyhli/outline.nvim",
|
||||
lazy = true,
|
||||
cmd = { "Outline", "OutlineOpen" },
|
||||
keys = { -- Example mapping to toggle outline
|
||||
{ "<leader>o", "<cmd>Outline<CR>", desc = "Toggle outline" },
|
||||
},
|
||||
opts = {
|
||||
-- Your setup opts here
|
||||
},
|
||||
}
|
||||
15
lua/plugins/peek.lua
Normal file
15
lua/plugins/peek.lua
Normal file
@@ -0,0 +1,15 @@
|
||||
return {
|
||||
"toppair/peek.nvim",
|
||||
event = { "VeryLazy" },
|
||||
build = "deno task --quiet build:fast",
|
||||
config = function()
|
||||
require("peek").setup({
|
||||
app = "firefox",
|
||||
})
|
||||
vim.api.nvim_create_user_command("PeekOpen", require("peek").open, {})
|
||||
vim.api.nvim_create_user_command("PeekClose", require("peek").close, {})
|
||||
end,
|
||||
keys = {
|
||||
{ "<leader>md", "<cmd>PeekOpen<CR>", desc = "Open peek markdown" },
|
||||
},
|
||||
}
|
||||
69
lua/plugins/sidekick.lua
Normal file
69
lua/plugins/sidekick.lua
Normal file
@@ -0,0 +1,69 @@
|
||||
return {
|
||||
"folke/sidekick.nvim",
|
||||
opts = {
|
||||
nes = {
|
||||
enabled = false,
|
||||
},
|
||||
-- add any options here
|
||||
cli = {
|
||||
mux = {
|
||||
backend = "zellij",
|
||||
enabled = true,
|
||||
},
|
||||
},
|
||||
},
|
||||
keys = {
|
||||
{
|
||||
".",
|
||||
function() require("sidekick.cli").toggle("opencode") end,
|
||||
desc = "Sidekick Toggle",
|
||||
mode = { "n" },
|
||||
},
|
||||
{
|
||||
"<leader>aa",
|
||||
function() require("sidekick.cli").toggle() end,
|
||||
desc = "Sidekick Toggle CLI",
|
||||
},
|
||||
{
|
||||
"<leader>as",
|
||||
function() require("sidekick.cli").select() end,
|
||||
-- Or to select only installed tools:
|
||||
-- require("sidekick.cli").select({ filter = { installed = true } })
|
||||
desc = "Select CLI",
|
||||
},
|
||||
{
|
||||
"<leader>ad",
|
||||
function() require("sidekick.cli").close() end,
|
||||
desc = "Detach a CLI Session",
|
||||
},
|
||||
{
|
||||
"<leader>at",
|
||||
function() require("sidekick.cli").send({ msg = "{this}" }) end,
|
||||
mode = { "x", "n" },
|
||||
desc = "Send This",
|
||||
},
|
||||
{
|
||||
"<leader>af",
|
||||
function() require("sidekick.cli").send({ msg = "{file}" }) end,
|
||||
desc = "Send File",
|
||||
},
|
||||
{
|
||||
"<leader>av",
|
||||
function() require("sidekick.cli").send({ msg = "{selection}" }) end,
|
||||
mode = { "x" },
|
||||
desc = "Send Visual Selection",
|
||||
},
|
||||
{
|
||||
"<leader>ap",
|
||||
function() require("sidekick.cli").prompt() end,
|
||||
mode = { "n", "x" },
|
||||
desc = "Sidekick Select Prompt",
|
||||
},
|
||||
-- Example of a keybinding to open Claude directly
|
||||
{
|
||||
"<leader>ac",
|
||||
function() require("sidekick.cli").toggle({ name = "claude", focus = true }) end,
|
||||
desc = "Sidekick Toggle Claude",
|
||||
},
|
||||
},
|
||||
}
|
||||
7
lua/plugins/unception.lua
Normal file
7
lua/plugins/unception.lua
Normal file
@@ -0,0 +1,7 @@
|
||||
return {
|
||||
"samjwill/nvim-unception",
|
||||
init = function()
|
||||
-- Optional settings go here!
|
||||
vim.g.unception_open_buffer_in_new_tab = true
|
||||
end
|
||||
}
|
||||
@@ -1,44 +1,45 @@
|
||||
---@type LazySpec
|
||||
return {
|
||||
"mikavilpas/yazi.nvim",
|
||||
version = "*", -- use the latest stable version
|
||||
event = "VeryLazy",
|
||||
dependencies = {
|
||||
{ "nvim-lua/plenary.nvim", lazy = true },
|
||||
},
|
||||
keys = {
|
||||
-- 👇 in this section, choose your own keymappings!
|
||||
{
|
||||
"<leader>-",
|
||||
mode = { "n", "v" },
|
||||
"<cmd>Yazi<cr>",
|
||||
desc = "Open yazi at the current file",
|
||||
},
|
||||
{
|
||||
-- Open in the current working directory
|
||||
"<leader>cw",
|
||||
"<cmd>Yazi cwd<cr>",
|
||||
desc = "Open the file manager in nvim's working directory",
|
||||
},
|
||||
{
|
||||
";",
|
||||
"<cmd>Yazi toggle<cr>",
|
||||
desc = "Resume the last yazi session",
|
||||
},
|
||||
},
|
||||
---@type YaziConfig | {}
|
||||
opts = {
|
||||
-- if you want to open yazi instead of netrw, see below for more info
|
||||
open_for_directories = false,
|
||||
keymaps = {
|
||||
show_help = "<f1>",
|
||||
},
|
||||
},
|
||||
-- 👇 if you use `open_for_directories=true`, this is recommended
|
||||
init = function()
|
||||
-- mark netrw as loaded so it's not loaded at all.
|
||||
--
|
||||
-- More details: https://github.com/mikavilpas/yazi.nvim/issues/802
|
||||
vim.g.loaded_netrwPlugin = 1
|
||||
end,
|
||||
}
|
||||
return {}
|
||||
-- ---@type LazySpec
|
||||
-- return {
|
||||
-- "mikavilpas/yazi.nvim",
|
||||
-- version = "*", -- use the latest stable version
|
||||
-- event = "VeryLazy",
|
||||
-- dependencies = {
|
||||
-- { "nvim-lua/plenary.nvim", lazy = true },
|
||||
-- },
|
||||
-- keys = {
|
||||
-- -- 👇 in this section, choose your own keymappings!
|
||||
-- {
|
||||
-- "<leader>-",
|
||||
-- mode = { "n", "v" },
|
||||
-- "<cmd>Yazi<cr>",
|
||||
-- desc = "Open yazi at the current file",
|
||||
-- },
|
||||
-- {
|
||||
-- -- Open in the current working directory
|
||||
-- "<leader>cw",
|
||||
-- "<cmd>Yazi cwd<cr>",
|
||||
-- desc = "Open the file manager in nvim's working directory",
|
||||
-- },
|
||||
-- {
|
||||
-- ";",
|
||||
-- "<cmd>Yazi toggle<cr>",
|
||||
-- desc = "Resume the last yazi session",
|
||||
-- },
|
||||
-- },
|
||||
-- ---@type YaziConfig | {}
|
||||
-- opts = {
|
||||
-- -- if you want to open yazi instead of netrw, see below for more info
|
||||
-- open_for_directories = false,
|
||||
-- keymaps = {
|
||||
-- show_help = "<f1>",
|
||||
-- },
|
||||
-- },
|
||||
-- -- 👇 if you use `open_for_directories=true`, this is recommended
|
||||
-- init = function()
|
||||
-- -- mark netrw as loaded so it's not loaded at all.
|
||||
-- --
|
||||
-- -- More details: https://github.com/mikavilpas/yazi.nvim/issues/802
|
||||
-- vim.g.loaded_netrwPlugin = 1
|
||||
-- end,
|
||||
-- }
|
||||
|
||||
8
shell/clangd-direnv.sh
Executable file
8
shell/clangd-direnv.sh
Executable file
@@ -0,0 +1,8 @@
|
||||
#!/usr/bin/env bash
|
||||
|
||||
if command -v direnv >/dev/null 2>&1; then
|
||||
direnv exec . clangd "$@"
|
||||
else
|
||||
clangd "$@"
|
||||
fi
|
||||
|
||||
Reference in New Issue
Block a user