Compare commits
1
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
5d32fc8518 |
+25
-20
@@ -28,13 +28,12 @@ return {
|
||||
-- { import = "astrocommunity.pack.html-css" },
|
||||
-- { import = "astrocommunity.pack.angular" },
|
||||
|
||||
-- { import = "astrocommunity.pack.ansible" },
|
||||
-- { import = "astrocommunity.pack.terraform" },
|
||||
-- { import = "astrocommunity.pack.docker" },
|
||||
-- { import = "astrocommunity.pack.helm" },
|
||||
{ import = "astrocommunity.pack.ansible" },
|
||||
{ import = "astrocommunity.pack.terraform" },
|
||||
{ import = "astrocommunity.pack.docker" },
|
||||
{ import = "astrocommunity.pack.helm" },
|
||||
|
||||
-- { import = "astrocommunity.pack.rainbow-delimiter-indent-blankline" },
|
||||
{ import = "astrocommunity.indent.indent-rainbowline" },
|
||||
|
||||
-- Recipes
|
||||
|
||||
@@ -49,29 +48,19 @@ return {
|
||||
-- Completion
|
||||
{ import = "astrocommunity.completion.blink-cmp-git" },
|
||||
{ import = "astrocommunity.completion.blink-cmp-emoji" },
|
||||
-- { import = "astrocommunity.completion.cmp-nerdfont" },
|
||||
{ import = "astrocommunity.completion.cmp-nerdfont" },
|
||||
{ import = "astrocommunity.completion.copilot-lua-cmp" },
|
||||
-- { import = "astrocommunity.completion.cmp-spell" },
|
||||
-- { import = "astrocommunity.completion.copilot-lua-cmp" },
|
||||
|
||||
-- AI
|
||||
-- { import = "astrocommunity.ai.copilotchat-nvim" },
|
||||
-- { import = "astrocommunity.ai.minuet-ai-nvim" },
|
||||
{ import = "astrocommunity.ai.copilotchat-nvim" },
|
||||
-- { import = "astrocommunity.completion.minuet-ai-nvim" },
|
||||
|
||||
-- Telescope
|
||||
{ import = "astrocommunity.terminal-integration.toggleterm-manager-nvim" }, -- A Telescope extension to manage Toggleterm's terminals in NeoVim
|
||||
-- { import = "astrocommunity.file-explorer.telescope-file-browser-nvim" },
|
||||
|
||||
-- Individual plugins (misc)
|
||||
|
||||
-- { import = "astrocommunity.workflow.hardtime-nvim" }, -- Display hints to get rid of bad habits
|
||||
{ import = "astrocommunity.motion.marks-nvim" }, -- Display marks in the sign column
|
||||
{ import = "astrocommunity.diagnostics.trouble-nvim" },
|
||||
{ import = "astrocommunity.editing-support.nvim-devdocs" },
|
||||
{ import = "astrocommunity.git.diffview-nvim" },
|
||||
{ import = "astrocommunity.markdown-and-latex.render-markdown-nvim" },
|
||||
-- { import = "astrocommunity.markdown-and-latex.markview-nvim" }, -- Alternative to render-markdown-nvim
|
||||
|
||||
-- Individual plugins (colorschemes)
|
||||
-- Colorschemes
|
||||
{ import = "astrocommunity.colorscheme.vscode-nvim" },
|
||||
{ import = "astrocommunity.colorscheme.github-nvim-theme" },
|
||||
{ import = "astrocommunity.colorscheme.neosolarized-nvim" },
|
||||
@@ -82,6 +71,18 @@ return {
|
||||
{ import = "astrocommunity.colorscheme.tokyonight-nvim" },
|
||||
{ import = "astrocommunity.colorscheme.onedarkpro-nvim" },
|
||||
|
||||
-- Individual plugins (misc)
|
||||
|
||||
{ import = "astrocommunity.diagnostics.trouble-nvim" },
|
||||
{ import = "astrocommunity.motion.marks-nvim" }, -- Display marks in the sign column
|
||||
{ import = "astrocommunity.git.diffview-nvim" },
|
||||
{ import = "astrocommunity.markdown-and-latex.render-markdown-nvim" },
|
||||
-- { import = "astrocommunity.markdown-and-latex.markview-nvim" },
|
||||
{ import = "astrocommunity.programming-language-support.kulala-nvim" }, -- A minimal HTTP-client interface for Neovim
|
||||
{ import = "astrocommunity.indent.indent-rainbowline" },
|
||||
{ import = "astrocommunity.editing-support.nvim-devdocs" },
|
||||
-- { import = "astrocommunity.workflow.hardtime-nvim" }, -- Display hints to get rid of bad habits
|
||||
|
||||
-- Disabled
|
||||
|
||||
-- { import = "astrocommunity.bars-and-lines.smartcolumn-nvim" }, -- display a column when text width exceed defined limit
|
||||
@@ -100,4 +101,8 @@ return {
|
||||
-- end
|
||||
-- end,
|
||||
-- },
|
||||
|
||||
-- Now provided by core
|
||||
-- { import = "astrocommunity.bars-and-lines.vim-illuminate" }, -- highlight other uses of the word under cursor
|
||||
-- { import = "astrocommunity.editing-support.todo-comments-nvim" },
|
||||
}
|
||||
|
||||
+1
-1
@@ -24,8 +24,8 @@ require("lazy").setup({
|
||||
-- "gzip",
|
||||
-- "netrwPlugin",
|
||||
-- "tarPlugin",
|
||||
-- "zipPlugin",
|
||||
"tohtml",
|
||||
"zipPlugin",
|
||||
},
|
||||
},
|
||||
},
|
||||
|
||||
+44
-45
@@ -35,6 +35,45 @@ return {
|
||||
[".*/etc/foo/.*"] = "fooscript",
|
||||
},
|
||||
},
|
||||
-- Commands
|
||||
commands = {
|
||||
CleanYamlSpaces = {
|
||||
function()
|
||||
if vim.bo.filetype == 'yaml' or vim.bo.filetype == 'yml' then
|
||||
local cursor_pos = vim.api.nvim_win_get_cursor(0)
|
||||
vim.cmd([[%s/\s\+$//e]])
|
||||
vim.api.nvim_win_set_cursor(0, cursor_pos)
|
||||
print("Espaces en fin de ligne supprimés")
|
||||
else
|
||||
print("Cette commande ne fonctionne que sur les fichiers YAML")
|
||||
end
|
||||
end,
|
||||
desc = "Nettoie les espaces en fin de ligne dans les fichiers YAML",
|
||||
},
|
||||
},
|
||||
-- Autocmd
|
||||
autocmds = {
|
||||
yaml_trailing_spaces = {
|
||||
{
|
||||
event = { "BufRead", "BufNewFile" },
|
||||
pattern = { "*.yaml", "*.yml" },
|
||||
callback = function()
|
||||
vim.fn.matchadd("TrailingWhiteSpace", "\\s\\+$")
|
||||
end,
|
||||
desc = "Surligne les espaces en fin de ligne dans les fichiers YAML",
|
||||
},
|
||||
{
|
||||
event = "BufWritePre",
|
||||
pattern = { "*.yaml", "*.yml" },
|
||||
callback = function()
|
||||
local cursor_pos = vim.api.nvim_win_get_cursor(0)
|
||||
vim.cmd([[%s/\s\+$//e]])
|
||||
vim.api.nvim_win_set_cursor(0, cursor_pos)
|
||||
end,
|
||||
desc = "Nettoie les espaces en fin de ligne avant sauvegarde",
|
||||
},
|
||||
},
|
||||
},
|
||||
-- vim options can be configured here
|
||||
options = {
|
||||
opt = { -- vim.opt.<key>
|
||||
@@ -51,22 +90,6 @@ return {
|
||||
-- This can be found in the `lua/lazy_setup.lua` file
|
||||
},
|
||||
},
|
||||
-- Commands
|
||||
commands = {
|
||||
CleanYamlSpaces = {
|
||||
function()
|
||||
if vim.bo.filetype == "yaml" or vim.bo.filetype == "yml" then
|
||||
local cursor_pos = vim.api.nvim_win_get_cursor(0)
|
||||
vim.cmd [[%s/\s\+$//e]]
|
||||
vim.api.nvim_win_set_cursor(0, cursor_pos)
|
||||
print "Espaces en fin de ligne supprimés"
|
||||
else
|
||||
print "Cette commande ne fonctionne que sur les fichiers YAML"
|
||||
end
|
||||
end,
|
||||
desc = "Nettoie les espaces en fin de ligne dans les fichiers YAML",
|
||||
},
|
||||
},
|
||||
-- Mappings can be configured through AstroCore as well.
|
||||
-- NOTE: keycodes follow the casing in the vimdocs. For example, `<Leader>` must be capitalized
|
||||
mappings = {
|
||||
@@ -87,21 +110,18 @@ return {
|
||||
end,
|
||||
desc = "Close buffer from tabline",
|
||||
},
|
||||
["<Leader>bn"] = { function() require("astrocore.buffer").nav(vim.v.count1) end, desc = "Next buffer" },
|
||||
["<Leader>bp"] = { function() require("astrocore.buffer").nav(-vim.v.count1) end, desc = "Previous buffer" },
|
||||
["<Leader>bn"] = { function() require("astrocore.buffer").nav(vim.v.count1) end, desc = "Next buffer" },
|
||||
|
||||
-- tables with just a `desc` key will be registered with which-key if it's installed
|
||||
-- this is useful for naming menus
|
||||
["<Leader>b"] = { desc = "Buffers" },
|
||||
-- ["<Leader>b"] = { desc = "Buffers" },
|
||||
|
||||
-- setting a mapping to false will disable it
|
||||
-- ["<C-S>"] = false,
|
||||
|
||||
-- Visual selection of pasted text
|
||||
["gp"] = { "`[v`]", desc = "Visual selection of pasted text" },
|
||||
|
||||
-- Normal mode : Custom mappings
|
||||
["<F2>"] = { "<cmd>Neotree toggle<cr>", desc = "File Explorer" },
|
||||
["<F2>"] = { "<cmd>Neotree toggle<cr>", desc = "File Explorer" }, -- F26 corresponds to <Ctrl+F2> on my keyboard
|
||||
["<F3>"] = {
|
||||
function() require("astrocore").toggle_term_cmd { cmd = "lazygit", direction = "float" } end,
|
||||
desc = "Lazygit terminal",
|
||||
@@ -113,7 +133,7 @@ return {
|
||||
},
|
||||
-- Insert mode : Custom mappings
|
||||
i = {
|
||||
["<F2>"] = { "<cmd>Neotree toggle<cr>", desc = "File Explorer" },
|
||||
["<F2>"] = { "<cmd>Neotree toggle<cr>", desc = "File Explorer" }, -- F26 corresponds to <Ctrl+F2> on my keyboard
|
||||
["<F3>"] = {
|
||||
function() require("astrocore").toggle_term_cmd { cmd = "lazygit", direction = "float" } end,
|
||||
desc = "Lazygit terminal",
|
||||
@@ -135,7 +155,7 @@ return {
|
||||
-- Clear Ctrl+l so that we can use it to clear the terminal
|
||||
["<C-l>"] = false,
|
||||
["<C-h>"] = false,
|
||||
-- Clear Ctrl-J and Ctrl-K so that we can use them for apps running in the terminal (for example lazygit)
|
||||
-- Clear Ctrl-J and Ctrl-K so that we can use them to navigate the terminal (for lazygit)
|
||||
["<C-j>"] = false,
|
||||
["<C-k>"] = false,
|
||||
-- My terms
|
||||
@@ -149,26 +169,5 @@ return {
|
||||
}, -- F28 corresponds to <Ctrl+F4> on my keyboard
|
||||
},
|
||||
},
|
||||
-- Autocmd
|
||||
autocmds = {
|
||||
yaml_trailing_spaces = {
|
||||
{
|
||||
event = { "BufRead", "BufNewFile" },
|
||||
pattern = { "*.yaml", "*.yml" },
|
||||
callback = function() vim.fn.matchadd("TrailingWhiteSpace", "\\s\\+$") end,
|
||||
desc = "Surligne les espaces en fin de ligne dans les fichiers YAML",
|
||||
},
|
||||
{
|
||||
event = "BufWritePre",
|
||||
pattern = { "*.yaml", "*.yml" },
|
||||
callback = function()
|
||||
local cursor_pos = vim.api.nvim_win_get_cursor(0)
|
||||
vim.cmd [[%s/\s\+$//e]]
|
||||
vim.api.nvim_win_set_cursor(0, cursor_pos)
|
||||
end,
|
||||
desc = "Nettoie les espaces en fin de ligne avant sauvegarde",
|
||||
},
|
||||
},
|
||||
},
|
||||
},
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user