LazyNvim_anmited
"/home/yossef/notes/git/nvims/LazyNvim_anmited.md"
path: git/nvims/LazyNvim_anmited.md
- **fileName**: LazyNvim_anmited
- **Created on**: 2025-03-23 15:18:20
Neovim Keymap Configuration
Directory Structure Breakdown
lua/config/
: Contains core configurations like keymaps, options, and autocmds.lua/plugins/
: Contains individual plugin configs (e.g., telescope, lsp-zero, harpoon).init.lua
: Main entry file loading configurations and plugins.lazy-lock.json
: Lock file ensuring consistent plugin versions.
General Keybindings
<leader>e
: OpensLex
(file explorer)
This bindsvim.keymap.set('n', '<leader>e', ':Lex 30<CR>', { noremap = true, silent = true })
<leader>e
to open Lex with a width of 30 columns.
Custom Mappings
-
Y
: Copies from the cursor to the end of the line (likeD
andC
)vim.keymap.set('n', 'Y', 'y
-
Move between split windows
vim.keymap.set('n', '<C-h>', '<C-w>h', { noremap = true }) vim.keymap.set('n', '<C-l>', '<C-w>l', { noremap = true }) vim.keymap.set('n', '<C-j>', '<C-w>j', { noremap = true }) vim.keymap.set('n', '<C-k>', '<C-w>k', { noremap = true })
These mappings allow you to navigate between windows using
Ctrl + h/j/k/l
. -
Resize windows
vim.keymap.set('n', '<C-Up>', ':resize +2<CR>', { noremap = true }) vim.keymap.set('n', '<C-Down>', ':resize -2<CR>', { noremap = true }) vim.keymap.set('n', '<C-Left>', ':vertical resize -2<CR>', { noremap = true }) vim.keymap.set('n', '<C-Right>', ':vertical resize +2<CR>', { noremap = true })
These allow you to resize splits easily with
Ctrl + Arrow keys
.
Plugin Setup and Features
This setup uses Lazy.nvim for better performance and easy plugin management.
Core Plugins
-
telescope.nvim: Fuzzy finder for files, buffers, and more
vim.keymap.set('n', '<leader>ff', ':Telescope find_files<CR>', { noremap = true, silent = true }) vim.keymap.set('n', '<leader>fg', ':Telescope live_grep<CR>', { noremap = true, silent = true }) vim.keymap.set('n', '<leader>fb', ':Telescope buffers<CR>', { noremap = true, silent = true })
-
harpoon: Quick file navigation
local harpoon = require('harpoon') vim.keymap.set('n', '<leader>a', function() harpoon:list():add() end) vim.keymap.set('n', '<leader>h', function() harpoon.ui:toggle_quick_menu() end)
-
null-ls/none-ls: Formatting and linting
require('null-ls').setup({})
-
lsp-zero: Simplifies LSP setup (autocomplete, diagnostics, snippets)
local lsp = require('lsp-zero').preset({}) lsp.setup()
-
dashboard.nvim: Animated, aesthetic start screen
require('dashboard').setup({ theme = 'hyper' })
-
plenary.nvim: Utility library (dependency for telescope and harpoon)
Icons & Animations
For a more modern, animated feel:
- nvim-web-devicons: Adds filetype icons.
require('nvim-web-devicons').setup()
- nvim-notify: Beautiful pop-up notifications.
vim.notify = require('notify')
Performance Tips
-
Lazy-loading plugins: Ensure only essential plugins load on startup.
-
Profiling startup time: Use
:Lazy profile
to check slow plugins.continue:./astro_nvim.md
before:./nvim_lazy_second_style.md
, { noremap = true })
- Move between split windows
{{CODE_BLOCK_3}}
These mappings allow you to navigate between windows using `Ctrl + h/j/k/l`.
- Resize windows
{{CODE_BLOCK_4}}
These allow you to resize splits easily with `Ctrl + Arrow keys`.
## Plugin Setup and Features
This setup uses **Lazy.nvim** for better performance and easy plugin management.
### Core Plugins
- **telescope.nvim**: Fuzzy finder for files, buffers, and more
{{CODE_BLOCK_5}}
- **harpoon**: Quick file navigation
{{CODE_BLOCK_6}}
- **null-ls/none-ls**: Formatting and linting
{{CODE_BLOCK_7}}
- **lsp-zero**: Simplifies LSP setup (autocomplete, diagnostics, snippets)
{{CODE_BLOCK_8}}
- **dashboard.nvim**: Animated, aesthetic start screen
{{CODE_BLOCK_9}}
- **plenary.nvim**: Utility library (dependency for telescope and harpoon)
### Icons & Animations
For a more modern, animated feel:
- **nvim-web-devicons**: Adds filetype icons.
{{CODE_BLOCK_10}}
- **nvim-notify**: Beautiful pop-up notifications.
{{CODE_BLOCK_11}}
## Performance Tips
- **Lazy-loading plugins**: Ensure only essential plugins load on startup.
- **Profiling startup time**: Use `:Lazy profile` to check slow plugins.
**continue**:[[./astro_nvim.md]]
**before**:[[./nvim_lazy_second_style.md]]