Update from obsidian -

Affected files:
notes/utils/Neovim.md
projects/quests.md
This commit is contained in:
Alexander Navarro 2023-10-28 13:09:04 -03:00
parent c0273b7ec0
commit 49730b5f3c
2 changed files with 51 additions and 4 deletions

View file

@ -1,23 +1,65 @@
## Formatters
## Config
### Formatters
Hay que añadirlos en `plugins/formatters.lua`, pueden ser instalados con mason.
## Linters
### Linters
Hay que añadirlos en `plugins/linters.lua`, pueden ser instalados con mason.
## LSP
### LSP
Hay que añadirlos en `plugins/lsp.lua`, son instalados automáticamente al ser agregados aquí con mason.
## Remember to use:
### Misc
- In visual mode, you can use `J` or `K` to move the selection
- With alt + hjkl I can resize the window, I can restore the size with `<C-w> =`
- `<Leader>r` tiene keymaps para search and replace
### LSP y code actions
- `<Leader>la` -> Code action by lsp
- `<Leader>lA` -> Node action by Treesitter
- `<Leader>lm` -> Toggle node join split (arrays, objects, etc)
- `<Leader>lr` -> rename symbol
- `<Leader>fd` -> See disagnostics in file
- `<Leader>fD` -> See disagnostics in workspace
- `gr` -> List reference of symbol in telescope
### Git
Puedo invocar comandos de git directamente desde neovim con `:Git ...`
### Harpoon
Fast navigation with `<Leader><Leader>[hjkl]`
### Buffers
Puedo hacer pin a ciertos buffers para no cerrarlos con `<Leader>bp` y cerrar todos los buffers no pineados con `<Leader>bP`
Puedo cerrar los otros buffers no activos con `<Leader>bO`
### Treesitter
#### Text objects
TODO: Research movemet with Treesitter
### Text objects
Los text objects se utilizan en la forma de ==acción - motion==, Ej: `vi{` es `selecciona dentro de los { }`
Acciones:
- v -> visual selection
- d -> delete
- c -> change
- gc -> comment
Text objects available:
- f -> function
- t -> html tag
### Surround plugin
@ -41,6 +83,10 @@ works for:
- Comments (`gc`)
- Visual selection
### Telescope
- [Browser plugins mappigns](https://github.com/nvim-telescope/telescope-file-browser.nvim#mappings)
## Plugins compatibility errors
Lazy.nvim tiene un `lazy-lock.json`, por lo que ante cualquier problema de compatibilidad, podemos volver a versión especificada aqui con `Lazy restore`. Es importante mantener este archivo en git y solo modificarlo cuando se esté seguro que no hay problemas de compatibilidad.