38 Commits

Author SHA1 Message Date
anth64 ca49391504 add json and c# indentation rules 2025-11-26 07:53:58 +01:00
anth64 caa148b6b0 fixendofline true 2025-11-25 20:11:51 +01:00
anth64 1a0b08d37d add csharp language server 2025-11-25 20:10:58 +01:00
anth64 6b5bb2ff3a use clangd over ccls 2025-08-07 22:38:31 -04:00
anth64 0001d8a14e added ccls 2025-08-07 20:41:59 -04:00
anth64 2a789eda7a add telescope fzf for native fuzzy find, very fast... 2025-05-28 18:45:18 +02:00
anth64 764dee5a9b add css language server 2025-05-09 12:23:45 +02:00
anth64 6e9d990167 added typescript language server 2025-05-09 12:17:25 +02:00
anth64 3de62d002d remove htmx language server 2025-05-08 09:12:32 +02:00
anth64 2d4e745910 added rules for javascript 2025-05-07 14:38:48 +02:00
anth64 ed22584915 added rules for html 2025-05-07 14:38:01 +02:00
anth64 764f2500f7 Don't force shell and add more lsps 2025-05-07 14:37:49 +02:00
anth64 2d1dd2bfec make command height default value to see status bar in command mode 2025-05-07 07:30:49 +02:00
anth64 1387429c47 added configuration for lua 2025-05-05 21:54:16 +02:00
anth64 9820d9a155 use after/ftplugin instead 2025-05-05 21:49:12 +02:00
anth64 464361b990 add lazydev for lua completion 2025-05-05 21:48:53 +02:00
anth64 94590db5c9 added auto formatting and .editorconfig 2025-05-04 18:19:13 +02:00
anth64 9e4735ee47 switched to blink for auto complete 2025-05-04 17:31:26 +02:00
anth64 5e6716e263 added cmp-buffer 2025-05-03 09:54:12 +02:00
anth64 b07f1aaf35 add jsonls 2025-05-01 12:04:29 +02:00
anth64 7a3800f2a0 added go and htmx langauge servers 2025-04-29 11:07:10 +02:00
anth64 655df38a9f make sure java follows standard guidelines for java formatting 2025-04-26 17:45:01 +02:00
anth64 d3f12ddb2d added format bind 2025-04-26 17:44:01 +02:00
anth64 98c1aba113 make moonfly transparent 2025-04-22 20:09:35 +02:00
anth64 c51e3b30e7 jdtls for both windows/linux and add diagnostic keybind 2025-04-16 22:57:29 +02:00
anth64 6c9250d1da Squashed commit of the following:
commit 7322bc0f73
Author: anth64 <anth64@protonmail.com>
Date:   Tue Apr 15 22:21:09 2025 +0200

    use lspconfig

commit 5577628a22
Author: anth64 <anth64@protonmail.com>
Date:   Tue Apr 15 20:08:14 2025 +0200

    reorderd lazy and config

commit 7f1a3b82da
Author: anth64 <anth64@protonmail.com>
Date:   Tue Apr 15 19:29:43 2025 +0200

    add colorschemes, default to moonfly

commit 466c8cf410
Author: anth64 <anth64@protonmail.com>
Date:   Tue Apr 15 18:51:56 2025 +0200

    make it work on windows as well

commit a9d9c2199d
Author: anth64 <anth64@protonmail.com>
Date:   Fri Apr 11 07:26:54 2025 +0200

    added jdtls and newline to end of files

commit 4db9e65e6f
Author: anth64 <anth64@protonmail.com>
Date:   Thu Apr 10 22:33:16 2025 +0200

    remove redundant remap of mapleader

commit bb0ad9af1b
Author: anth64 <anth64@protonmail.com>
Date:   Thu Apr 10 22:28:45 2025 +0200

    readd telescope and harpoon

commit 1a56e26e6b
Author: anth64 <anth64@protonmail.com>
Date:   Thu Apr 10 22:20:12 2025 +0200

    redid mapping, set and util, also readded nvim-cmp and cmp-nvim-lsp

commit 690e575c03
Author: anth64 <anth64@protonmail.com>
Date:   Wed Apr 9 23:23:51 2025 +0200

    make sure that colorscheme is not touched

commit 0ab0b593f2
Author: anth64 <anth64@protonmail.com>
Date:   Wed Apr 9 22:56:58 2025 +0200

    add lazy.nvim and lualine plugin

commit a8dd286e39
Author: anth64 <anth64@protonmail.com>
Date:   Wed Apr 9 07:59:00 2025 +0200

    initial configuration
2025-04-16 07:41:42 +02:00
anth64 b7e3d43782 make sure that it looks in the right dir on windows. 2025-04-15 13:37:52 +02:00
anth64 e7334a67d3 added yaml language server 2025-03-15 11:30:25 +01:00
anth64 40c7ea6cc3 more sensible defaults for basedpyright 2025-03-06 12:56:17 +01:00
anth64 98dc6f8d64 add basedpyright 2025-02-10 10:57:15 +01:00
anth64 aa18999cc2 add ccls 2024-12-19 19:40:03 +01:00
anth64 3f69af1125 display errors on hover 2024-12-19 19:39:49 +01:00
anth64 67a1cb3237 force unix file formats 2024-12-18 09:24:06 +01:00
anth64 f8af12905f force unix file format 2024-12-03 22:13:31 +01:00
anth64 eb50cc0a34 fixed issue where auto-complete was borked... 2024-12-03 21:57:52 +01:00
anth64 9feaa4d770 make sure home dir is set properly. 2024-12-03 20:58:01 +01:00
anth64 6538d1c611 add jdtls. 2024-12-03 20:48:51 +01:00
anth64 ac570f7599 CRLF -> LF 2024-12-03 20:36:44 +01:00
15 changed files with 229 additions and 180 deletions
+1
View File
@@ -3,3 +3,4 @@
[ripgrep](https://github.com/BurntSushi/ripgrep) is required for this to work. [ripgrep](https://github.com/BurntSushi/ripgrep) is required for this to work.
My configuration for Neovim. My configuration for Neovim.
+3
View File
@@ -0,0 +1,3 @@
vim.opt_local.expandtab = true
vim.opt_local.shiftwidth = 4
vim.opt_local.tabstop = 4
+3
View File
@@ -0,0 +1,3 @@
vim.opt_local.expandtab = true
vim.opt_local.shiftwidth = 2
vim.opt_local.tabstop = 2
+11
View File
@@ -0,0 +1,11 @@
vim.opt_local.expandtab = true
vim.opt_local.shiftwidth = 4
vim.opt_local.tabstop = 4
local home = os.getenv("HOME") or os.getenv("USERPROFILE")
local config = {
cmd = { home .. '/.local/share/java/jdtls/bin/jdtls' },
root_dir = vim.fs.dirname(vim.fs.find({ 'gradlew', '.git', 'mvnw' }, { upward = true })[1]),
}
require('jdtls').start_or_attach(config)
+3
View File
@@ -0,0 +1,3 @@
vim.opt_local.expandtab = true
vim.opt_local.shiftwidth = 2
vim.opt_local.tabstop = 2
+3
View File
@@ -0,0 +1,3 @@
vim.opt_local.expandtab = true
vim.opt_local.shiftwidth = 4
vim.opt_local.tabstop = 4
+3
View File
@@ -0,0 +1,3 @@
vim.opt_local.expandtab = true
vim.opt_local.shiftwidth = 2
vim.opt_local.tabstop = 2
+21 -3
View File
@@ -1,3 +1,21 @@
require("config.set") require("config.lazy")
require("config.remap") require("config.set")
require("config.lazy") require("config.remap")
vim.cmd("set completeopt+=noselect")
vim.lsp.enable({
'basedpyright',
'clangd',
'csharp_ls',
'cssls',
'eslint',
'gopls',
'html',
'jsonls',
'lua_ls',
'ts_ls',
'yamlls',
})
vim.o.winborder = 'rounded'
+33 -35
View File
@@ -1,35 +1,33 @@
-- Bootstrap lazy.nvim -- Bootstrap lazy.nvim
local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim" local lazypath = vim.fn.stdpath("data") .. "/lazy/lazy.nvim"
if not (vim.uv or vim.loop).fs_stat(lazypath) then if not (vim.uv or vim.loop).fs_stat(lazypath) then
local lazyrepo = "https://github.com/folke/lazy.nvim.git" local lazyrepo = "https://github.com/folke/lazy.nvim.git"
local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath }) local out = vim.fn.system({ "git", "clone", "--filter=blob:none", "--branch=stable", lazyrepo, lazypath })
if vim.v.shell_error ~= 0 then if vim.v.shell_error ~= 0 then
vim.api.nvim_echo({ vim.api.nvim_echo({
{ "Failed to clone lazy.nvim:\n", "ErrorMsg" }, { "Failed to clone lazy.nvim:\n", "ErrorMsg" },
{ out, "WarningMsg" }, { out, "WarningMsg" },
{ "\nPress any key to exit..." }, { "\nPress any key to exit..." },
}, true, {}) }, true, {})
vim.fn.getchar() vim.fn.getchar()
os.exit(1) os.exit(1)
end end
end end
vim.opt.rtp:prepend(lazypath) vim.opt.rtp:prepend(lazypath)
-- Make sure to setup `mapleader` and `maplocalleader` before -- Make sure to setup `mapleader` and `maplocalleader` before
-- loading lazy.nvim so that mappings are correct. -- loading lazy.nvim so that mappings are correct.
-- This is also a good place to setup other settings (vim.opt) -- This is also a good place to setup other settings (vim.opt)
vim.g.mapleader = " " vim.g.mapleader = " "
vim.g.maplocalleader = "\\" vim.g.maplocalleader = "\\"
-- Setup lazy.nvim -- Setup lazy.nvim
require("lazy").setup({ require("lazy").setup({
spec = { spec = {
-- import your plugins -- import your plugins
{ import = "plugins" }, { import = "plugins" },
}, },
-- Configure any other settings here. See the documentation for more details. -- Configure any other settings here. See the documentation for more details.
-- colorscheme that will be used when installing plugins. -- automatically check for plugin updates
install = { colorscheme = { "habamax" } }, checker = { enabled = true },
-- automatically check for plugin updates })
checker = { enabled = true },
})
+1 -2
View File
@@ -1,2 +1 @@
vim.g.mapleader = " " vim.keymap.set("n", "<leader>pv", vim.cmd.Ex)
vim.keymap.set("n", "<leader>pv", vim.cmd.Ex)
+34 -35
View File
@@ -1,35 +1,34 @@
vim.opt.cmdheight = 0 vim.opt.fileformat = "unix"
vim.opt.guicursor = "" vim.opt.fileformats = "unix"
vim.opt.mouse = "" vim.opt.fixendofline = true
vim.opt.guicursor = ""
vim.opt.nu = true vim.opt.mouse = ""
vim.opt.relativenumber = true
vim.opt.number = true
vim.opt.tabstop = 2 vim.opt.relativenumber = true
vim.opt.softtabstop = 2
vim.opt.shiftwidth = 2 vim.opt.smartindent = true
vim.opt.expandtab = true
vim.opt.swapfile = false
vim.opt.smartindent = true vim.opt.backup = false
local home = os.getenv("HOME") or os.getenv("USERPROFILE")
vim.opt.wrap = false vim.opt.undodir = home .. "/.vim/undodir"
vim.opt.undofile = true
vim.opt.swapfile = false
vim.opt.backup = false vim.opt.hlsearch = false
vim.opt.undodir = os.getenv("HOME") .. "/.vim/undodir" vim.opt.incsearch = true
vim.opt.undofile = true
vim.opt.termguicolors = true
vim.opt.hlsearch = false
vim.opt.incsearch = true vim.opt.scrolloff = 8
vim.opt.signcolumn = "yes"
vim.opt.termguicolors = true vim.opt.isfname:append("@-@")
vim.opt.scrolloff = 8
vim.opt.signcolumn = "yes" vim.opt.updatetime = 50
vim.opt.isfname:append("@-@")
vim.opt.colorcolumn = "80"
vim.opt.updatetime = 50 vim.g.c_syntax_for_h = 1
vim.opt.colorcolumn = "80" vim.cmd.colorscheme("moonfly")
vim.g.c_syntax_for_h = 1 vim.keymap.set('n', '<leader>d', vim.diagnostic.open_float, { noremap = true, silent = true })
vim.g.mapleader = " "
+13
View File
@@ -0,0 +1,13 @@
return {
'saghen/blink.cmp',
dependencies = { 'rafamadriz/friendly-snippets' },
version = '1.*',
opts = {
keymap = { preset = 'default' },
appearance = {
nerd_font_variant = 'mono'
},
signature = { enabled = true }
},
}
+37 -44
View File
@@ -1,44 +1,37 @@
return { return {
{"nvim-treesitter/nvim-treesitter", build = ":TSUpdate"}, {
{ "neovim/nvim-lspconfig",
"neovim/nvim-lspconfig", dependencies = {
config = function() "saghen/blink.cmp"
local lspconfig = require("lspconfig") },
lspconfig.lua_ls.setup{} config = function()
end, vim.api.nvim_create_autocmd('LspAttach', {
}, group = vim.api.nvim_create_augroup('my.lsp', {}),
{ callback = function(args)
"VonHeikemen/lsp-zero.nvim", local client = assert(vim.lsp.get_client_by_id(args.data.client_id))
dependencies = { if not client then return end
"neovim/nvim-lspconfig", if client:supports_method('textDocument/formatting') then
"hrsh7th/nvim-cmp", vim.api.nvim_create_autocmd('BufWritePre', {
"hrsh7th/cmp-nvim-lsp" group = vim.api.nvim_create_augroup('my.lsp', { clear = false }),
}, buffer = args.buf,
config = function() callback = function()
require("lsp-zero") vim.lsp.buf.format({ bufnr = args.buf, id = client.id, timeout_ms = 1000 })
vim.opt.signcolumn = 'yes' end,
local lspconfig_defaults = require('lspconfig').util.default_config })
lspconfig_defaults.capabilities = vim.tbl_deep_extend( end
'force', end,
lspconfig_defaults.capabilities, })
require('cmp_nvim_lsp').default_capabilities() end
) },
vim.api.nvim_create_autocmd('LspAttach', { {
desc = 'LSP actions', "folke/lazydev.nvim",
callback = function(event) ft = "lua",
local opts = {buffer = event.buf} opts = {
vim.keymap.set('n', 'K', '<cmd>lua vim.lsp.buf.hover()<cr>', opts) library = {
vim.keymap.set('n', 'gd', '<cmd>lua vim.lsp.buf.definition()<cr>', opts) { path = "${3rd}/luv/library", words = { "vim%.uv" } },
vim.keymap.set('n', 'gD', '<cmd>lua vim.lsp.buf.declaration()<cr>', opts) },
vim.keymap.set('n', 'gi', '<cmd>lua vim.lsp.buf.implementation()<cr>', opts) },
vim.keymap.set('n', 'go', '<cmd>lua vim.lsp.buf.type_definition()<cr>', opts) },
vim.keymap.set('n', 'gr', '<cmd>lua vim.lsp.buf.references()<cr>', opts) { "nvim-treesitter/nvim-treesitter", build = ":TSUpdate" },
vim.keymap.set('n', 'gs', '<cmd>lua vim.lsp.buf.signature_help()<cr>', opts) { "mfussenegger/nvim-jdtls" } -- jdtls bindings for neovim
vim.keymap.set('n', '<F2>', '<cmd>lua vim.lsp.buf.rename()<cr>', opts) }
vim.keymap.set({'n', 'x'}, '<F3>', '<cmd>lua vim.lsp.buf.format({async = true})<cr>', opts)
vim.keymap.set('n', '<F4>', '<cmd>lua vim.lsp.buf.code_action()<cr>', opts)
end,
})
end,
}
}
+44 -41
View File
@@ -1,41 +1,44 @@
return { return {
{ {
"theprimeagen/harpoon", "mbbill/undotree",
config = function() config = function()
local mark = require("harpoon.mark") vim.keymap.set("n", "<leader>u", vim.cmd.UndotreeToggle)
local ui = require("harpoon.ui") end,
},
vim.keymap.set("n", "<leader>a", mark.add_file) {
vim.keymap.set("n", "<C-e>", ui.toggle_quick_menu) "tpope/vim-fugitive",
config = function()
vim.keymap.set("n", "<C-h>", function() ui.nav_file(1) end) vim.keymap.set("n", "<leader>gs", vim.cmd.Git)
vim.keymap.set("n", "<C-t>", function() ui.nav_file(2) end) end,
vim.keymap.set("n", "<C-n>", function() ui.nav_file(3) end) },
vim.keymap.set("n", "<C-s>", function() ui.nav_file(4) end) {
end, "nvim-telescope/telescope.nvim",
}, dependencies = {
{ "nvim-lua/plenary.nvim",
"mbbill/undotree", { "nvim-telescope/telescope-fzf-native.nvim", build = "make" }
config = function() },
vim.keymap.set("n", "<leader>u", vim.cmd.UndotreeToggle) config = function()
end, local builtin = require('telescope.builtin')
}, vim.keymap.set('n', '<leader>pf', builtin.find_files, {})
{ vim.keymap.set('n', '<C-p>', builtin.git_files, {})
"tpope/vim-fugitive", vim.keymap.set('n', '<leader>ps', function()
config = function() builtin.grep_string({ search = vim.fn.input("Grep > ") });
vim.keymap.set("n", "<leader>gs", vim.cmd.Git) end)
end, end,
}, },
{ {
"nvim-telescope/telescope.nvim", "theprimeagen/harpoon",
dependencies = {"nvim-lua/plenary.nvim"}, config = function()
config = function() local mark = require("harpoon.mark")
local builtin = require('telescope.builtin') local ui = require("harpoon.ui")
vim.keymap.set('n', '<leader>pf', builtin.find_files, {})
vim.keymap.set('n', '<C-p>', builtin.git_files, {}) vim.keymap.set("n", "<leader>a", mark.add_file)
vim.keymap.set('n', '<leader>ps', function() vim.keymap.set("n", "<C-e>", ui.toggle_quick_menu)
builtin.grep_string({ search = vim.fn.input("Grep > ") });
end) vim.keymap.set("n", "<C-h>", function() ui.nav_file(1) end)
end, vim.keymap.set("n", "<C-t>", function() ui.nav_file(2) end)
} vim.keymap.set("n", "<C-n>", function() ui.nav_file(3) end)
} vim.keymap.set("n", "<C-s>", function() ui.nav_file(4) end)
end
}
}
+19 -20
View File
@@ -1,20 +1,19 @@
return { return {
{ {
"oxfist/night-owl.nvim", "nvim-lualine/lualine.nvim",
lazy = false, -- make sure we load this during startup if it is your main colorscheme dependencies = { "nvim-tree/nvim-web-devicons" },
priority = 1000, -- make sure to load this before all the other start plugins lazy = false,
config = function() config = function()
-- load the colorscheme here require("lualine").setup()
require("night-owl").setup() end,
vim.cmd.colorscheme("night-owl") },
end, {
}, "bluz71/vim-moonfly-colors",
{ lazy = false,
"nvim-lualine/lualine.nvim", config = function()
dependencies = { "nvim-tree/nvim-web-devicons" }, vim.g.moonflyTransparent = true
lazy = false, end,
config = function() },
require("lualine").setup() { "EdenEast/nightfox.nvim", lazy = false },
end, { "oxfist/night-owl.nvim", lazy = false },
} }
}