mass update

This commit is contained in:
Dario48 2025-10-08 21:24:37 +02:00
commit c613a6d0e3
21 changed files with 361 additions and 128 deletions

View file

@ -0,0 +1,12 @@
-- put this in your init.lua
vim.api.nvim_create_autocmd({ "BufEnter", "BufWinEnter" }, {
pattern = { "*.yuck" },
callback = function(event)
print(string.format("starting yuck;s for %s", vim.inspect(event)))
vim.lsp.start({
name = "YuckLs",
cmd = { "yuckls" }, -- if installed from aur
root_dir = vim.fn.getcwd(),
})
end,
})

View file

@ -2,6 +2,7 @@ vim.opt.tabstop = 4
vim.opt.softtabstop = 0
vim.opt.shiftwidth = 0
vim.opt.shell = "/bin/bash"
vim.opt.linebreak = true
vim.cmd("set wrap smoothscroll")
vim.opt.rnu = true

2
lua/config/lsp.lua Normal file
View file

@ -0,0 +1,2 @@
-- lsp that are not on mason/beta branch lsp
vim.lsp.enable("zls")

4
lua/plugins/boo.lua Normal file
View file

@ -0,0 +1,4 @@
return {
"LukasPietzschmann/boo.nvim",
opts = {},
}

View file

@ -1,15 +1,15 @@
return {
"stevearc/conform.nvim",
dependencies = { "frostplexx/mason-bridge.nvim" },
event = { "BufWritePre" },
cmd = { "ConformInfo" },
init = function()
require "conform".setup(
{
format_on_save = function(bufnr)
require("conform").formatters_by_ft = require "mason-bridge".get_formatters()
return { timeout_ms = 200, lsp_fallback = true }, on_format
end,
formatters_by_ft = require("mason-bridge").get_formatters(), --[[ = {
require("conform").setup({
format_on_save = function(bufnr)
require("conform").formatters_by_ft = require("mason-bridge").get_formatters()
return { timeout_ms = 200, lsp_fallback = true }, on_format
end,
formatters_by_ft = require("mason-bridge").get_formatters(), --[[ = {
lua = { "stylua" },
javascript = { "prettier" },
html = { "prettier" },
@ -23,26 +23,26 @@ return {
json = { "jq" },
}, ]] --
-- This will provide type hinting with LuaLS
---@module "conform"
---@type conform.setupOpts
formatters = {
prettier = {
prepend_args = { "--use-tabs", "true" },
},
jq = {
prepend_args = { "--tab" },
},
["clang-format"] = {
prepend_args = function(self, ctx)
return { "-style=file:/home/Dario48/.config/.clang-format" }
end,
},
default_format_opts = {
lsp_format = "fallback",
},
-- This will provide type hinting with LuaLS
---@module "conform"
---@type conform.setupOpts
formatters = {
prettier = {
prepend_args = { "--use-tabs", "true" },
},
})
jq = {
prepend_args = { "--tab" },
},
["clang-format"] = {
prepend_args = function(self, ctx)
return { "-style=file:/home/Dario48/.config/.clang-format" }
end,
},
default_format_opts = {
lsp_format = "fallback",
},
},
})
-- If you want the formatexpr, here is the place to set it
vim.o.formatexpr = "v:lua.require'conform'.formatexpr()"
vim.g.arduino_recommended_style = 0

View file

@ -1,4 +1,4 @@
return {
url = "https://codeberg.org/Dario48/darioline.git",
config = true
url = "https://dario48.site/git/Dario48/darioline.git",
config = true,
}

40
lua/plugins/diagram.lua Normal file
View file

@ -0,0 +1,40 @@
return {
"3rd/diagram.nvim",
dependencies = {
{ "3rd/image.nvim" }, -- you'd probably want to configure image.nvim manually instead of doing this
},
opts = { -- you can just pass {}, defaults below
events = {
render_buffer = { "InsertLeave", "BufWinEnter", "TextChanged" },
clear_buffer = { "BufLeave" },
},
renderer_options = {
mermaid = {
background = nil, -- nil | "transparent" | "white" | "#hex"
theme = nil, -- nil | "default" | "dark" | "forest" | "neutral"
scale = 1, -- nil | 1 (default) | 2 | 3 | ...
width = nil, -- nil | 800 | 400 | ...
height = nil, -- nil | 600 | 300 | ...
cli_args = nil, -- nil | { "--no-sandbox" } | { "-p", "/path/to/puppeteer" } | ...
},
plantuml = {
charset = nil,
cli_args = nil, -- nil | { "-Djava.awt.headless=true" } | ...
},
d2 = {
theme_id = nil,
dark_theme_id = nil,
scale = nil,
layout = nil,
sketch = nil,
cli_args = nil, -- nil | { "--pad", "0" } | ...
},
gnuplot = {
size = nil, -- nil | "800,600" | ...
font = nil, -- nil | "Arial,12" | ...
theme = nil, -- nil | "light" | "dark" | custom theme string
cli_args = nil, -- nil | { "-p" } | { "-c", "config.plt" } | ...
},
},
},
}

11
lua/plugins/fuzzyfind.lua Normal file
View file

@ -0,0 +1,11 @@
return {
"nvim-telescope/telescope.nvim",
dependencies = { "nvim-lua/plenary.nvim" },
keys = {
{ "<leader>ff", require("telescope.builtin").find_files, desc = "Telescope find files" },
{ "<leader>fg", require("telescope.builtin").live_grep, desc = "Telescope live grep" },
{ "<leader>fb", require("telescope.builtin").buffers, desc = "Telescope buffers" },
{ "<leader>fh", require("telescope.builtin").help_tags, desc = "Telescope help tags" },
},
}

3
lua/plugins/kmonad.lua Normal file
View file

@ -0,0 +1,3 @@
return {
"kmonad/kmonad-vim",
}

View file

@ -2,62 +2,72 @@ return {
{
"williamboman/mason.nvim",
dependencies = { "williamboman/mason-lspconfig.nvim" },
keys = {
{ "<leader>m", ":Mason <CR>", desc = "open mason" },
},
config = true,
opts = {
PATH = "append",
},
},
{
"williamboman/mason-lspconfig.nvim",
dependencies = { "williamboman/mason.nvim" },
opts = {
-- Replace the language servers listed here
-- with the ones you want to install
ensure_installed = { "lua_ls", "clangd", "hyprls", "lua_ls" },
ensure_installed = { "lua_ls", "clangd", "hyprls" },
handlers = {
function(server_name)
require("lspconfig")[server_name].setup({
})
vim.lsp.enable(server_name)
end,
["lua_ls"] = function()
require 'lspconfig'.lua_ls.setup {
on_init = function(client)
local path = client.workspace_folders[1].name
if vim.loop.fs_stat(path .. '/.luarc.json') or vim.loop.fs_stat(path .. '/.luarc.jsonc') then
return
end
client.config.settings.Lua = vim.tbl_deep_extend('force', client.config.settings.Lua, {
vim.lsp.config("lua_ls", {
settings = {
Lua = {
runtime = {
-- Tell the language server which version of Lua you're using
-- (most likely LuaJIT in the case of Neovim)
version = 'LuaJIT'
version = "LuaJIT",
},
-- Make the server aware of Neovim runtime files
workspace = {
checkThirdParty = false,
library = {
vim.env.VIMRUNTIME
vim.env.VIMRUNTIME,
-- Depending on the usage, you might want to add additional paths here.
-- "${3rd}/luv/library"
-- "${3rd}/busted/library",
}
},
-- or pull in all of 'runtimepath'. NOTE: this is a lot slower
-- library = vim.api.nvim_get_runtime_file("", true)
}
})
end,
settings = {
Lua = {}
}
}
end
completion = {
callSnippet = "Replace",
},
doc = {
privateName = { "^_" },
},
hint = {
enable = true,
setType = false,
paramType = true,
paramName = "Disable",
semicolon = "Disable",
arrayIndex = "Disable",
},
},
},
},
})
vim.lsp.enable("lua_ls")
end,
},
},
},
{
"frostplexx/mason-bridge.nvim",
dependencies = { "williamboman/mason.nvim" },
config = true,
},
}

52
lua/plugins/minuet-ai.lua Normal file
View file

@ -0,0 +1,52 @@
return {
dependencies = { "nvim-lua/plenary.nvim" },
"milanglacier/minuet-ai.nvim",
config = function()
require("minuet").setup({
provider = "openai_fim_compatible",
n_completions = 1, -- recommend for local model for resource saving
context_window = 512,
provider_options = {
openai_fim_compatible = {
-- For Windows users, TERM may not be present in environment variables.
-- Consider using APPDATA instead.
api_key = "TERM",
name = "LLama.cpp",
end_point = "http://localhost:8012/v1/completions",
model = "PLACEHOLDER",
optional = {
max_tokens = 56,
top_p = 0.9,
},
template = {
prompt = function(context_before_cursor, context_after_cursor, _)
return "<|fim_prefix|>"
.. context_before_cursor
.. "<|fim_suffix|>"
.. context_after_cursor
.. "<|fim_middle|>"
end,
suffix = false,
},
},
},
virtualtext = {
auto_trigger_ft = {},
keymap = {
-- accept whole completion
accept = "<M-T>",
-- accept one line
accept_line = "<M-t>",
-- accept n lines (prompts for number)
-- e.g. "A-z 2 CR" will accept 2 lines
accept_n_lines = "<M-z>",
-- Cycle to prev completion item, or manually invoke completion
prev = "<M-h>",
-- Cycle to next completion item, or manually invoke completion
next = "<M-l>",
dismiss = "<M-e>",
},
},
})
end,
}

View file

@ -1,6 +1,6 @@
return {
"nvim-neorg/neorg",
lazy = true, -- Disable lazy loading as some `lazy.nvim` distributions set `lazy = true` by default
lazy = false, -- Disable lazy loading as some `lazy.nvim` distributions set `lazy = true` by default
dependencies = {
{
"juniorsundar/neorg-extras",
@ -8,6 +8,7 @@ return {
},
"nvim-telescope/telescope.nvim", -- Required for the Neorg-Roam features
"nvim-lua/plenary.nvim", -- Required as part of Telescope installation
"nvim-treesitter/nvim-treesitter",
},
opts = {
load = {
@ -15,23 +16,28 @@ return {
config = {
metadata_fold = true, -- If want @data property ... @end to fold
code_fold = true, -- If want @code ... @end to fold
}
},
},
["core.defaults"] = {},
["core.concealer"] = { config = { folds = false } },
["core.concealer"] = {},
["core.dirman"] = {
config = {
workspaces = {
school = "~/Documents/school",
notes = "~/Documents/notes",
uni = "~/Documents/uni",
},
default_workspace = "notes",
},
},
["core.completion"] = { config = { engine = "nvim-cmp" } },
["core.integrations.treesitter"] = {},
["core.clipboard.code-blocks"] = {},
["core.esupports.indent"] = {},
},
},
ft = "norg",
cmd = "Neorg",
config = true,
version = "*",
}

View file

@ -1,59 +1,79 @@
return {
"hrsh7th/nvim-cmp",
dependencies = {
"hrsh7th/cmp-nvim-lsp",
"hrsh7th/cmp-path",
"hrsh7th/cmp-cmdline",
"hrsh7th/cmp-nvim-lua",
"neovim/nvim-lspconfig",
"mtoohey31/cmp-fish",
"petertriho/cmp-git",
},
config = function()
local cmp = require("cmp")
{
"hrsh7th/nvim-cmp",
dependencies = {
"hrsh7th/cmp-nvim-lsp",
"hrsh7th/cmp-path",
"hrsh7th/cmp-cmdline",
"hrsh7th/cmp-nvim-lua",
"neovim/nvim-lspconfig",
"mtoohey31/cmp-fish",
"petertriho/cmp-git",
},
config = function()
local cmp = require("cmp")
cmp.setup({
sources = {
{ name = "nvim_lua" },
{
name = "nvim_lsp",
entry_filter = function(entry, ctx)
local kind = require("cmp.types").lsp.CompletionItemKind[entry:get_kind()]
cmp.setup({
sources = {
{
name = "lazydev",
group_index = 0, -- set group index to 0 to skip loading LuaLS completions
},
{ name = "nvim_lua" },
{
name = "nvim_lsp",
entry_filter = function(entry, ctx)
local kind = require("cmp.types").lsp.CompletionItemKind[entry:get_kind()]
if kind == "Text" then
return false
end
return true
if kind == "Text" then
return false
end
return true
end,
},
{ name = "neorg" },
{ name = "fish" },
},
snippet = {
expand = function(args)
-- You need Neovim v0.10 to use vim.snippet
vim.snippet.expand(args.body)
end,
},
{ name = "neorg" },
{ name = "fish" },
},
snippet = {
expand = function(args)
-- You need Neovim v0.10 to use vim.snippet
vim.snippet.expand(args.body)
end,
},
cmp.setup.filetype("gitcommit", {
sources = cmp.config.sources({
{ name = "git" },
}, {
{ name = "buffer" },
cmp.setup.filetype("gitcommit", {
sources = cmp.config.sources({
{ name = "git" },
}, {
{ name = "buffer" },
}),
}),
}),
require("cmp_git").setup(),
require("cmp_git").setup({}),
window = {
completion = cmp.config.window.bordered(),
documentation = cmp.config.window.bordered(),
},
mapping = cmp.mapping.preset.insert({
["<C-Space>"] = cmp.mapping.complete(),
["<S-NL>"] = cmp.mapping.scroll_docs(-4),
["<C-S-K>"] = cmp.mapping.scroll_docs(-4),
[" "] = cmp.mapping.confirm(),
}),
})
end,
window = {
completion = cmp.config.window.bordered(),
documentation = cmp.config.window.bordered(),
},
mapping = cmp.mapping.preset.insert({
["<C-Space>"] = cmp.mapping.complete(),
["<S-NL>"] = cmp.mapping.scroll_docs(-4),
["<C-S-K>"] = cmp.mapping.scroll_docs(-4),
[" "] = cmp.mapping.confirm(),
}),
})
end,
},
{
"folke/lazydev.nvim",
ft = "lua", -- only load on lua files
config = function()
local lazydev = require("lazydev")
require("lazydev").setup()
vim.lsp.enable("lua_ls")
vim.lsp.config("lua_ls", {
root_dir = function(bufnr, on_dir)
on_dir(lazydev.find_workspace(bufnr))
end,
})
end,
},
}

33
lua/plugins/sniprun.lua Normal file
View file

@ -0,0 +1,33 @@
return {
"michaelb/sniprun",
branch = "master",
build = "sh install.sh",
-- do 'sh install.sh 1' if you want to force compile locally
-- (instead of fetching a binary from the github release). Requires Rust >= 1.65
opts = {
repl_enable = { "Mathematica_original" },
interpreter_options = {
Lua_nvim = {
use_on_filetypes = { "lua" },
},
Mathematica_original = {
use_javagraphics_if_contains = { "Plot" }, -- a pattern that need <<JavaGraphics
},
},
display = {
"VirtualLine",
},
live_mode_toggle = "enable",
},
keys = {
{ "<leader>r", "<Plug>SnipRun", desc = "run snipper", silent = true },
{ "<leader>R", "<Plug>SnipLive", desc = "run snipper in REPL mode", silent = true },
{ "r", "<Plug>SnipRun", mode = "v", desc = "run snipper", silent = true },
},
lazy = false,
config = true,
}

View file

@ -2,38 +2,23 @@ return {
"nvim-treesitter/nvim-treesitter",
opts = {
-- A list of parser names, or "all" (the listed parsers MUST always be installed)
ensure_installed = { "c", "lua", "norg"},
ensure_installed = { "c", "lua", "vim", "vimdoc", "query" },
-- Install parsers synchronously (only applied to `ensure_installed`)
sync_install = true,
-- Automatically install missing parsers when entering buffer
-- Recommendation: set to false if you don't have `tree-sitter` CLI installed locally
auto_install = true,
auto_install = false,
-- List of parsers to ignore installing (or "all")
---- If you need to change the installation directory of the parsers (see -> Advanced Setup)
-- parser_install_dir = "/some/path/to/store/parsers", -- Remember to run vim.opt.runtimepath:append("/some/path/to/store/parsers")!
highlight = {
enable = true,
-- NOTE: these are the names of the parsers and not the filetype. (for example if you want to
-- disable highlighting for the `tex` filetype, you need to include `latex` in this list as this is
-- the name of the parser)
-- list of language that will be disabled
-- Or use a function for more flexibility, e.g. to disable slow treesitter highlight for large files
-- Setting this to true will run `:h syntax` and tree-sitter at the same time.
-- Set this to `true` if you depend on 'syntax' being enabled (like for indentation).
-- Using this option may slow down your editor, and you may see some duplicate highlights.
-- Instead of true it can also be a list of languages
additional_vim_regex_highlighting = false,
},
indent = {
enable = true,
disable = {"norg"}
},
highlight = { enable = true },
},
config = true,
config = function(_, opts)
require("nvim-treesitter.configs").setup(opts)
end,
version = "*",
}

18
lua/plugins/venn.lua Normal file
View file

@ -0,0 +1,18 @@
return {
"jbyuki/venn.nvim",
config = function()
vim.b.ve = "all"
end,
keys = {
{ "J", "<C-v>j:VBox<CR>", mode = "n", noremap = true },
{ "K", "<C-v>k:VBox<CR>", mode = "n", noremap = true },
{ "L", "<C-v>l:VBox<CR>", mode = "n", noremap = true },
{ "H", "<C-v>h:VBox<CR>", mode = "n", noremap = true },
-- draw a box by pressing "f" with visual selection,
{ "f", ":VBox<CR>", mode = "v", noremap = true },
},
lazy = true,
}

View file

@ -0,0 +1,17 @@
return {
"dhruvasagar/vim-table-mode",
config = function()
vim.g.table_mode_corner = "+"
end,
keys = {
{ "<LocalLeader>tm", "<cmd>TableModeToggle<cr>", desc = "toggla table mode" },
{ "<LocalLeader>tt", "<cmd>Tableize<cr>", desc = "transform CVS to table" },
{
"<LocalLeader>T",
function()
vim.api.nvim_command("Tableize/" .. vim.fn.input("what separator to use? "))
end,
desc = "transform CVS to table",
},
},
}