This commit is contained in:
2025-08-28 23:17:34 +02:00
parent fe3886fbdf
commit 20a49c3f58
31 changed files with 440 additions and 117 deletions

View File

@@ -101,6 +101,7 @@ require 'custom.autocommands'
require 'kickstart.core.keymaps'
require 'custom.keymaps'
-- [[ Colorscheme ]]
vim.cmd [[colorscheme moonfly]]
-- The line beneath this is called `modeline`. See `:help modeline`

View File

@@ -10,49 +10,24 @@
--
-- NOTE: Here is where you install your plugins.
require('lazy').setup({
-- spec = {
-- -- add LazyVim and import its plugins
-- { 'LazyVim/LazyVim' },
-- },
spec = {
-- NOTE: Plugins can be added with a link (or for a github repo: 'owner/repo' link).
'NMAC427/guess-indent.nvim', -- Detect tabstop and shiftwidth automatically
-- 'NMAC427/guess-indent.nvim', -- Detect tabstop and shiftwidth automatically
require 'kickstart.plugins.mini',
require 'kickstart.plugins.snacks', -- for use with neo-tree
require 'kickstart.plugins.noice',
require 'kickstart.plugins.treesitter',
require 'kickstart.plugins.telescope',
require 'kickstart.plugins.neo-tree',
require 'kickstart.plugins.lsp',
require 'kickstart.plugins.autopairs',
require 'kickstart.plugins.autoformat',
require 'kickstart.plugins.autocompletion',
require 'kickstart.plugins.gitsigns',
require 'kickstart.plugins.todo-comments',
-- require 'kickstart.plugins.debug',
-- require 'kickstart.plugins.indent_line', -- use alternative mini module
-- require 'kickstart.plugins.lint',
require 'kickstart.plugins.header',
require 'kickstart.plugins.which-key',
require 'kickstart.plugins.quarto',
require 'kickstart.plugins.obsidian',
require 'kickstart.plugins.markdown',
require 'kickstart.plugins.latex',
-- NOTE: Plugins can be added with a require command
-- require 'kickstart.plugins.mini',
-- Colorschemes
require 'kickstart.plugins.colorschemes',
-- NOTE: The import below can automatically add your own plugins, configuration, etc from `lua/custom/plugins/*.lua`
-- NOTE: The import below can automatically add your own plugins, configuration, etc from `lua/kickstart/plugins/*.lua`
-- This is the easiest way to modularize your config.
--
-- Uncomment the following line and add your plugins to `lua/custom/plugins/*.lua` to get going.
-- { import = 'custom.plugins' },
{ import = 'kickstart.plugins' },
-- In order to disable a plugin, add a spec with enabled=false
--
-- For additional information with loading, sourcing and examples see `:help lazy.nvim-🔌-plugin-spec`
-- Or use telescope!
-- In normal mode type `<space>sh` then write `lazy.nvim-plugin`
-- you can continue same window with `<space>sr` which resumes last telescope search
},
}, {
ui = {
-- If you are using a Nerd Font: set icons to an empty table which will use the

View File

@@ -90,5 +90,12 @@ vim.opt.softtabstop = 2 -- nombre d'espaces quand tu tapes <Tab>
-- indentation auto intelligente
vim.opt.smartindent = true
-- The order of your `lazy.nvim` imports is incorrect:
-- • `lazyvim.plugins` should be first
-- • followed by any `lazyvim.plugins.extras`
-- • and finally your own `plugins`
-- If you think you know what you're doing, you can disable this check with:
vim.g.lazyvim_check_order = false
-- The line beneath this is called `modeline`. See `:help modeline`
-- vim: ts=2 sts=2 sw=2 et

View File

@@ -1,4 +1,10 @@
-- Autocompletion
-- autocompletion
--
-- blink.cmp is a completion plugin with support for LSPs, cmdline, signature help, and snippets.
-- It uses an optional custom fuzzy matcher for typo resistance.
--
-- https://github.com/saghen/blink.cmp
--
return {
{
@@ -32,12 +38,12 @@ return {
-- `friendly-snippets` contains a variety of premade snippets.
-- See the README about individual language/framework/plugin snippets:
-- https://github.com/rafamadriz/friendly-snippets
-- {
-- 'rafamadriz/friendly-snippets',
-- config = function()
-- require('luasnip.loaders.from_vscode').lazy_load()
-- end,
-- },
{
'rafamadriz/friendly-snippets',
config = function()
require('luasnip.loaders.from_vscode').lazy_load()
end,
},
},
opts = {},
},

View File

@@ -1,5 +1,9 @@
-- autoformat
--
-- Lightweight yet powerful formatter plugin for Neovim
--
-- https://github.com/stevearc/conform.nvim
--
return {
{ -- Autoformat

View File

@@ -1,10 +1,14 @@
-- autopairs
--
-- A super powerful autopair plugin for Neovim that supports multiple characters.
--
-- https://github.com/windwp/nvim-autopairs
--
return {
{
'windwp/nvim-autopairs',
event = 'InsertEnter',
opts = {},
}
},
}

View File

@@ -0,0 +1,47 @@
-- chezmoi
--
-- chezmoi.nvim is a plugin designed to assist in editing and
-- applying chezmoi-managed files within neovim.
-- A notable distinction from the command line tool chezmoi is that
-- chezmoi.nvim utilizes built-in neovim functions for file editing,
-- allowing us to edit and watch multiple files simultaneously.
--
-- https://github.com/xvzc/chezmoi.nvim
--
return {
{
'xvzc/chezmoi.nvim',
cmd = { 'ChezmoiEdit' },
keys = {
{
'<leader>sc',
pick_chezmoi,
desc = 'search [c]hezmoi',
},
},
opts = {
edit = {
watch = false,
force = false,
},
notification = {
on_open = true,
on_apply = true,
on_watch = false,
},
telescope = {
select = { '<CR>' },
},
},
init = function()
-- run chezmoi edit on file enter
vim.api.nvim_create_autocmd({ 'BufRead', 'BufNewFile' }, {
pattern = { os.getenv 'HOME' .. '/.local/share/chezmoi/*' },
callback = function()
vim.schedule(require('chezmoi.commands.__edit').watch)
end,
})
end,
},
}

View File

@@ -1,5 +1,11 @@
-- Themes
-- colorschemes
--
-- These are loaded with LazyVim
--
-- https://github.com/bluz71/vim-moonfly-colors
-- https://github.com/folke/tokyonight.nvim
-- https://github.com/yorumicolors/yorumi.nvim
-- https://github.com/navarasu/onedark.nvim
--
return {
@@ -59,4 +65,3 @@ return {
end,
},
}

View File

@@ -1,14 +1,25 @@
-- debug.lua
-- debug
--
-- Shows how to use the DAP plugin to debug your code.
--
-- Primarily focused on configuring the debugger for Go, but can
-- be extended to other languages as well. That's why it's called
-- kickstart.nvim and not kitchen-sink.nvim ;)
--
-- nvim-dap is a Debug Adapter Protocol client implementation for Neovim. nvim-dap
-- allows you to:
-- • Launch an application to debug
-- • Attach to running applications and debug them
-- • Set breakpoints and step through code
-- • Inspect the state of the application
--
-- https://github.com/mfussenegger/nvim-dap
--
return {
-- NOTE: Yes, you can install new plugins here!
'mfussenegger/nvim-dap',
enabled = false,
-- NOTE: And you can specify dependencies as well
dependencies = {
-- Creates a beautiful debugger UI

View File

@@ -0,0 +1,93 @@
-- edgy
--
-- A Neovim plugin to easily create and manage predefined
-- window layouts, bringing a new edge to your workflow.
--
-- https://github.com/folke/edgy.nvim
--
return {
{
'folke/edgy.nvim',
enabled = false,
event = 'VeryLazy',
init = function()
vim.opt.laststatus = 3
vim.opt.splitkeep = 'screen'
end,
opts = {
bottom = {
-- toggleterm / lazyterm at the bottom with a height of 40% of the screen
{
ft = 'toggleterm',
size = { height = 0.4 },
-- exclude floating windows
filter = function(buf, win)
return vim.api.nvim_win_get_config(win).relative == ''
end,
},
{
ft = 'lazyterm',
title = 'LazyTerm',
size = { height = 0.4 },
filter = function(buf)
return not vim.b[buf].lazyterm_cmd
end,
},
'Trouble',
{ ft = 'qf', title = 'QuickFix' },
{
ft = 'help',
size = { height = 20 },
-- only show help buffers
filter = function(buf)
return vim.bo[buf].buftype == 'help'
end,
},
{ ft = 'spectre_panel', size = { height = 0.4 } },
},
left = {
-- Neo-tree filesystem always takes half the screen height
{
title = 'Neo-Tree',
ft = 'neo-tree',
filter = function(buf)
return vim.b[buf].neo_tree_source == 'filesystem'
end,
size = { height = 0.5 },
},
{
title = 'Neo-Tree Git',
ft = 'neo-tree',
filter = function(buf)
return vim.b[buf].neo_tree_source == 'git_status'
end,
pinned = true,
collapsed = true, -- show window as closed/collapsed on start
open = 'Neotree position=right git_status',
},
{
title = 'Neo-Tree Buffers',
ft = 'neo-tree',
filter = function(buf)
return vim.b[buf].neo_tree_source == 'buffers'
end,
pinned = true,
collapsed = true, -- show window as closed/collapsed on start
open = 'Neotree position=top buffers',
},
{
title = function()
local buf_name = vim.api.nvim_buf_get_name(0) or '[No Name]'
return vim.fn.fnamemodify(buf_name, ':t')
end,
ft = 'Outline',
pinned = true,
open = 'SymbolsOutlineOpen',
},
-- any other neo-tree windows
'neo-tree',
},
},
},
}

View File

@@ -1,8 +1,11 @@
-- gitsigns
-- https://github.com/lewis6991/gitsigns.nvim
--
-- Adds git related signs to the gutter, as well as utilities for managing changes
-- NOTE: gitsigns is already included in init.lua but contains only the base
-- config. This will add also the recommended keymaps.
--
-- https://github.com/lewis6991/gitsigns.nvim
--
return {
{

View File

@@ -0,0 +1,14 @@
-- guess-indent
--
-- Blazing fast indentation style detection for Neovim written in Lua.
-- The goal of this plugin is to automatically detect the indentation style
-- used in a buffer and updating the buffer options accordingly.
--
-- https://github.com/NMAC427/guess-indent.nvim
--
return {
{
'NMAC427/guess-indent.nvim',
},
}

View File

@@ -1,5 +1,10 @@
-- header
--
-- Fast, minimal Neovim plugin to automatically add or
-- update copyright and license headers in any programming language.
--
-- https://github.com/attilarepka/header.nvim
--
return {
{

View File

@@ -1,9 +1,14 @@
-- Indent Blankline
-- indent blankline
--
-- This plugin adds indentation guides to Neovim. It uses Neovim's virtual text feature and no conceal.
--
-- https://github.com/lukas-reineke/indent-blankline.nvim
--
return {
{ -- Add indentation guides even on blank lines
'lukas-reineke/indent-blankline.nvim',
enabled = false,
-- Enable `lukas-reineke/indent-blankline.nvim`
-- See `:help ibl`
main = 'ibl',

View File

@@ -1,5 +1,8 @@
-- latex
--
-- VimTeX is a modern Vim and Neovim filetype and syntax plugin for LaTeX files.
--
-- https://github.com/lervag/vimtex
--
vim.g.maplocalleader = ' ' -- we define a leader available only from tex files

View File

@@ -1,7 +1,18 @@
-- lint
--
-- An asynchronous linter plugin for Neovim (>= 0.9.5)
-- complementary to the built-in Language Server Protocol support.
-- nvim-lint complements the built-in language server client for languages
-- where there are no language servers, or where standalone linters provide better results.
--
-- https://github.com/mfussenegger/nvim-lint
--
return {
{ -- Linting
'mfussenegger/nvim-lint',
enabled = false,
event = { 'BufReadPre', 'BufNewFile' },
config = function()
local lint = require 'lint'

View File

@@ -1,4 +1,11 @@
-- LSP plugins
-- lsp
--
-- nvim-lspconfig is a "data only" repo, providing basic,
-- default Nvim LSP client configurations for various LSP servers
-- View all configs or :help lspconfig-all from Nvim.
--
-- https://github.com/neovim/nvim-lspconfig
--
return {
{

View File

@@ -1,5 +1,9 @@
-- Markdown
-- markdown
--
-- Plugin to improve viewing Markdown files in Neovim.
--
-- https://github.com/MeanderingProgrammer/render-markdown.nvim
--
return {
{

View File

@@ -1,5 +1,11 @@
-- mini
--
-- ibrary of 40+ independent Lua modules improving overall
-- Neovim (version 0.9 and higher) experience with minimal effort.
-- They all share same configuration approaches and general design principles.
--
-- https://github.com/echasnovski/mini.nvim
--
return {
{ -- Collection of various small independent plugins/modules
@@ -37,9 +43,10 @@ return {
end
local starter = require 'mini.starter'
local logo = require 'kickstart.plugins.logos'
local logo = require 'custom.plugins.logos'
starter.setup {
evaluate_single = true,
event = 'VimEnter',
header = table.concat(logo.neovim1, '\n'),
items = {
{ action = 'Neotree reveal=true position=float dir=~/.config/nvim/', name = ' Configuration', section = 'General' },
@@ -53,6 +60,32 @@ return {
require('mini.starter').gen_hook.adding_bullet '󰐊 ',
require('mini.starter').gen_hook.aligning('center', 'center'),
},
config = function()
-- close Lazy and re-open when starter is ready
if vim.o.filetype == 'lazy' then
vim.cmd.close()
vim.api.nvim_create_autocmd('User', {
pattern = 'MiniStarterOpened',
callback = function()
require('lazy').show()
end,
})
end
vim.api.nvim_create_autocmd('User', {
pattern = 'LazyVimStarted',
callback = function(ev)
local stats = require('lazy').stats()
local ms = (math.floor(stats.startuptime * 100 + 0.5) / 100)
local pad_footer = string.rep(' ', 8)
starter.config.footer = pad_footer .. '⚡ Neovim loaded ' .. stats.count .. ' plugins in ' .. ms .. 'ms'
-- INFO: based on @echasnovski's recommendation (thanks a lot!!!)
if vim.bo[ev.buf].filetype == 'ministarter' then
pcall(starter.refresh)
end
end,
})
end,
}
-- Simple way to visualize and work with indent scope
@@ -84,12 +117,38 @@ return {
-- Animate common Neovim actions
local animate = require 'mini.animate'
animate.setup {}
animate.setup {
optional = true,
opts = {
cursor = {
enable = false,
},
},
}
-- Buffer removing (unshow, delete, wipeout), which saves window layout
local bufremove = require 'mini.bufremove'
bufremove.setup {}
local icons = require 'mini.icons'
icons.setup {
opts = {
file = {
['.chezmoiignore'] = { glyph = '', hl = 'MiniIconsGrey' },
['.chezmoiremove'] = { glyph = '', hl = 'MiniIconsGrey' },
['.chezmoiroot'] = { glyph = '', hl = 'MiniIconsGrey' },
['.chezmoiversion'] = { glyph = '', hl = 'MiniIconsGrey' },
['bash.tmpl'] = { glyph = '', hl = 'MiniIconsGrey' },
['json.tmpl'] = { glyph = '', hl = 'MiniIconsGrey' },
['ps1.tmpl'] = { glyph = '󰨊', hl = 'MiniIconsGrey' },
['sh.tmpl'] = { glyph = '', hl = 'MiniIconsGrey' },
['toml.tmpl'] = { glyph = '', hl = 'MiniIconsGrey' },
['yaml.tmpl'] = { glyph = '', hl = 'MiniIconsGrey' },
['zsh.tmpl'] = { glyph = '', hl = 'MiniIconsGrey' },
},
},
}
-- ... and there is more!
-- Check out: https://github.com/echasnovski/mini.nvim
end,

View File

@@ -1,5 +1,9 @@
-- Neo-tree is a Neovim plugin to browse the file system
-- neo-tree
--
-- Neo-tree is a Neovim plugin to browse the file system.
--
-- https://github.com/nvim-neo-tree/neo-tree.nvim
--
local neotree_helper = require 'custom.plugins.neotree-helper'

View File

@@ -1,31 +1,35 @@
-- Noice (Nice, Noise, Notice)
-- noice (Nice, Noise, Notice)
--
-- Highly experimental plugin that completely replaces the UI for messages, cmdline and the popupmenu.
--
-- https://github.com/folke/noice.nvim
--
return {
{ -- Noice
"folke/noice.nvim",
event = "VeryLazy",
'folke/noice.nvim',
event = 'VeryLazy',
opts = {
-- add any options here
},
dependencies = {
-- if you lazy-load any plugin below, make sure to add proper `module="..."` entries
"MunifTanjim/nui.nvim",
'MunifTanjim/nui.nvim',
-- OPTIONAL:
-- `nvim-notify` is only needed, if you want to use the notification view.
-- If not available, we use `mini` as the fallback
"rcarriga/nvim-notify",
'rcarriga/nvim-notify',
},
config = function()
local noice = require('noice')
local noice = require 'noice'
noice.setup({
noice.setup {
lsp = {
-- override markdown rendering so that **cmp** and other plugins use **Treesitter**
override = {
["vim.lsp.util.convert_input_to_markdown_lines"] = true,
["vim.lsp.util.stylize_markdown"] = true,
["cmp.entry.get_documentation"] = true, -- requires hrsh7th/nvim-cmp
['vim.lsp.util.convert_input_to_markdown_lines'] = true,
['vim.lsp.util.stylize_markdown'] = true,
['cmp.entry.get_documentation'] = true, -- requires hrsh7th/nvim-cmp
},
},
-- you can enable a preset for easier configuration
@@ -36,7 +40,8 @@ return {
inc_rename = false, -- enables an input dialog for inc-rename.nvim
lsp_doc_border = false, -- add a border to hover docs and signature help
},
})
end,
}
end,
},
}

View File

@@ -1,4 +1,8 @@
-- obsidian
--
-- A community fork of the Neovim plugin for writing and
-- navigating Obsidian vaults, written in Lua, created by epwalsh.
--
-- https://github.com/obsidian-nvim/obsidian.nvim
--

View File

@@ -1,14 +1,13 @@
-- Quarto and other tools to use with
-- quarto
--
-- Quarto and other tools to use with.
-- Quarto-nvim provides tools for working on Quarto manuscripts in Neovim. You can get started with Quarto here.
--
-- quarto: https://github.com/quarto-dev/quarto-nvim
-- vim-slime: https://github.com/jpalardy/vim-slime
-- molten: https://github.com/benlubas/molten-nvim
--
--local wh_status, wh = pcall(require, 'custom.plugins.window-helper')
--if not wh_status then
-- return
--end
return {
{
'quarto-dev/quarto-nvim',

View File

@@ -0,0 +1,12 @@
-- smear-cursor
--
-- Neovim plugin to animate the cursor with a smear effect in all terminals.
-- Inspired by Neovide's animated cursor.
--
-- https://github.com/sphamba/smear-cursor.nvim
--
return {
'sphamba/smear-cursor.nvim',
opts = {},
}

View File

@@ -1,6 +1,9 @@
-- snacks
--
-- A collection of small QoL plugins for Neovim.
--
-- https://github.com/folke/snacks.nvim
--
return {
{

View File

@@ -1,5 +1,9 @@
-- telescope
--
-- Gaze deeply into unknown regions using the power of the moon.
--
-- https://github.com/nvim-telescope/telescope.nvim
--
return {
{ -- Fuzzy Finder (files, lsp, etc)
@@ -107,4 +111,3 @@ return {
end,
},
}

View File

@@ -1,5 +1,10 @@
-- Todo Comments
-- todo-comments
--
-- todo-comments is a lua plugin for Neovim >= 0.8.0 to highlight
-- and search for todo comments like TODO, HACK, BUG in your code base.
--
-- https://github.com/folke/todo-comments.nvim
--
return {
-- Highlight todo, notes, etc in comments
@@ -7,10 +12,11 @@ return {
'folke/todo-comments.nvim',
event = 'VimEnter',
dependencies = {
'nvim-lua/plenary.nvim'
'nvim-lua/plenary.nvim',
},
opts = {
signs = false
}
signs = false,
},
},
}

View File

@@ -1,5 +1,11 @@
-- nvim-treesitter
--
-- The goal of nvim-treesitter is both to provide a simple and
-- easy way to use the interface for tree-sitter in Neovim and
-- to provide some basic functionality such as highlighting based on it.
--
-- https://github.com/nvim-treesitter/nvim-treesitter
--
return {
{ -- Highlight, edit, and navigate code
@@ -28,4 +34,3 @@ return {
-- - Treesitter + textobjects: https://github.com/nvim-treesitter/nvim-treesitter-textobjects
},
}

View File

@@ -1,66 +1,79 @@
-- Nvim-web-devicons
-- nvim-web-devicons
--
-- Provides Nerd Font 1 icons (glyphs) for use by Neovim plugins:
-- • Icons by:
-- - Extension
-- - Full name
-- • Colours
-- • Light and dark variants
-- • API to modify/add icons
--
-- A lua fork of vim-devicons.
--
-- https://github.com/nvim-tree/nvim-web-devicons
--
return {
{
"nvim-tree/nvim-web-devicons",
'nvim-tree/nvim-web-devicons',
config = function()
require'nvim-web-devicons'.setup {
require('nvim-web-devicons').setup {
-- your personal icons can go here (to override)
-- you can specify color or cterm_color instead of specifying both of them
-- DevIcon will be appended to `name`
override = {
zsh = {
icon = "",
color = "#428850",
cterm_color = "65",
name = "Zsh"
}
};
icon = '',
color = '#428850',
cterm_color = '65',
name = 'Zsh',
},
},
-- globally enable different highlight colors per icon (default to true)
-- if set to false all icons will have the default icon's color
color_icons = true;
color_icons = true,
-- globally enable default icons (default to false)
-- will get overriden by `get_icons` option
default = true;
default = true,
-- globally enable "strict" selection of icons - icon will be looked up in
-- different tables, first by filename, and if not found by extension; this
-- prevents cases when file doesn't have any extension but still gets some icon
-- because its name happened to match some extension (default to false)
strict = true;
strict = true,
-- set the light or dark variant manually, instead of relying on `background`
-- (default to nil)
variant = "light|dark";
variant = 'light|dark',
-- same as `override` but specifically for overrides by filename
-- takes effect when `strict` is true
override_by_filename = {
[".gitignore"] = {
icon = "",
color = "#f1502f",
name = "Gitignore"
}
};
['.gitignore'] = {
icon = '',
color = '#f1502f',
name = 'Gitignore',
},
},
-- same as `override` but specifically for overrides by extension
-- takes effect when `strict` is true
override_by_extension = {
["log"] = {
icon = "",
color = "#81e043",
name = "Log"
}
};
['log'] = {
icon = '',
color = '#81e043',
name = 'Log',
},
},
-- same as `override` but specifically for operating system
-- takes effect when `strict` is true
override_by_operating_system = {
["apple"] = {
icon = "",
color = "#A2AAAD",
cterm_color = "248",
name = "Apple",
['apple'] = {
icon = '',
color = '#A2AAAD',
cterm_color = '248',
name = 'Apple',
},
},
};
}
end,
opts = {}
opts = {},
},
}

View File

@@ -1,5 +1,10 @@
-- which-key
--
-- WhichKey helps you remember your Neovim keymaps,
-- by showing available keybindings in a popup as you type.
--
-- https://github.com/folke/which-key.nvim
--
return {
{ -- Useful plugin to show you pending keybinds.