add readme and yaml spec
This commit is contained in:
15
docs/README.md
Normal file
15
docs/README.md
Normal file
@@ -0,0 +1,15 @@
|
|||||||
|
# New Spec
|
||||||
|
|
||||||
|
For new LSP, add in `lua/modules/language-specs.lua` at `lsp = <name>`.
|
||||||
|
Name should match the mason registry one at: `https://github.com/mason-org/mason-registry/tree/main/packages`
|
||||||
|
|
||||||
|
1. Run `nvim --headless +InstallAll +qa` (it invalidates cache automatically)
|
||||||
|
2. Run ` nvim --headless +FetchLspConfigs +qa` -> It will download the nvim-lspconfig variant in `lsp/`
|
||||||
|
|
||||||
|
You may need to run: `pkill prettierd` (as it is running in background)
|
||||||
|
|
||||||
|
# Other commands
|
||||||
|
|
||||||
|
```
|
||||||
|
nvim --headless +Sync +qa # For packages/plugins
|
||||||
|
```
|
||||||
23
docs/docs.md
23
docs/docs.md
@@ -1,13 +1,3 @@
|
|||||||
TODO:
|
|
||||||
- wrap up invero theme in separate repo and proper colors?
|
|
||||||
- check plugins logins
|
|
||||||
- cache / create final result
|
|
||||||
- simplify coding: ts, lsp, lint, format (check other repos)
|
|
||||||
- how to download parsers and plugins alternative
|
|
||||||
- telescope alternative
|
|
||||||
- keymaps
|
|
||||||
- wrap up everything
|
|
||||||
|
|
||||||
```lua
|
```lua
|
||||||
--[[
|
--[[
|
||||||
Neovim Lua config: ways to set things
|
Neovim Lua config: ways to set things
|
||||||
@@ -31,6 +21,7 @@ TODO:
|
|||||||
## check macos fileS: https://github.com/dsully/dotfiles/blob/main/.data/macos-defaults/globals.yaml
|
## check macos fileS: https://github.com/dsully/dotfiles/blob/main/.data/macos-defaults/globals.yaml
|
||||||
|
|
||||||
# Used pacakges:
|
# Used pacakges:
|
||||||
|
|
||||||
- rockspaces Metadata files describing how to build and install a Lua package.
|
- rockspaces Metadata files describing how to build and install a Lua package.
|
||||||
- luarocks Package manager for Lua modules. (optional)
|
- luarocks Package manager for Lua modules. (optional)
|
||||||
- tree-sitter Parser generator. Not needed except for using CLI. (optional)
|
- tree-sitter Parser generator. Not needed except for using CLI. (optional)
|
||||||
@@ -66,8 +57,8 @@ TODO:
|
|||||||
- ncurses ncurses-dev ncurses-libs ncurses-terminfo \
|
- ncurses ncurses-dev ncurses-libs ncurses-terminfo \
|
||||||
- check: https://github.com/glepnir/nvim/blob/main/Dockerfile
|
- check: https://github.com/glepnir/nvim/blob/main/Dockerfile
|
||||||
|
|
||||||
|
|
||||||
# Currently installed
|
# Currently installed
|
||||||
|
|
||||||
- plenary.nvim
|
- plenary.nvim
|
||||||
- lazy.nvim
|
- lazy.nvim
|
||||||
|
|
||||||
@@ -93,11 +84,12 @@ TODO:
|
|||||||
- plenary.nvim
|
- plenary.nvim
|
||||||
- harpoon # tags
|
- harpoon # tags
|
||||||
|
|
||||||
|
|
||||||
# Notes:
|
# Notes:
|
||||||
|
|
||||||
- in lsp change tsserver to vtsls
|
- in lsp change tsserver to vtsls
|
||||||
|
|
||||||
# New package definition
|
# New package definition
|
||||||
|
|
||||||
- Plugin and Package managers
|
- Plugin and Package managers
|
||||||
- folke/lazy.nvim
|
- folke/lazy.nvim
|
||||||
- mason-org/mason.nvim
|
- mason-org/mason.nvim
|
||||||
@@ -106,7 +98,6 @@ TODO:
|
|||||||
- nvim-treesitter-textobjects
|
- nvim-treesitter-textobjects
|
||||||
- LSP
|
- LSP
|
||||||
- neovim/nvim-lspconfig
|
- neovim/nvim-lspconfig
|
||||||
|
|
||||||
- nvim-ts-autotag tag elements (`</>`)
|
- nvim-ts-autotag tag elements (`</>`)
|
||||||
- windwp/nvim-autopairs auto pairs
|
- windwp/nvim-autopairs auto pairs
|
||||||
- blink.cmp autocompletion
|
- blink.cmp autocompletion
|
||||||
@@ -123,11 +114,13 @@ TODO:
|
|||||||
- mini.indentscope
|
- mini.indentscope
|
||||||
|
|
||||||
## Deps:
|
## Deps:
|
||||||
|
|
||||||
- SchemaStore.nvim
|
- SchemaStore.nvim
|
||||||
- mason-lspconfig.nvim
|
- mason-lspconfig.nvim
|
||||||
- mason.nvim
|
- mason.nvim
|
||||||
|
|
||||||
## Maybe:
|
## Maybe:
|
||||||
|
|
||||||
- folke/ts-comments.nvim better comments
|
- folke/ts-comments.nvim better comments
|
||||||
- grug-far.nvim find and replace
|
- grug-far.nvim find and replace
|
||||||
- markdown-preview.nvim side by side md (disabled in folke)
|
- markdown-preview.nvim side by side md (disabled in folke)
|
||||||
@@ -146,6 +139,7 @@ TODO:
|
|||||||
- undo tree (find a plugin)
|
- undo tree (find a plugin)
|
||||||
|
|
||||||
## AI help
|
## AI help
|
||||||
|
|
||||||
- jackMort/ChatGPT.nvim
|
- jackMort/ChatGPT.nvim
|
||||||
- MunifTanjim/nui.nvim (dep)
|
- MunifTanjim/nui.nvim (dep)
|
||||||
- nvim-lua/plenary.nvim (dep)
|
- nvim-lua/plenary.nvim (dep)
|
||||||
@@ -155,6 +149,7 @@ TODO:
|
|||||||
- milanglacier/minuet-ai.nvim (folke)
|
- milanglacier/minuet-ai.nvim (folke)
|
||||||
|
|
||||||
## Options
|
## Options
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
opt.backup = true
|
opt.backup = true
|
||||||
@@ -178,6 +173,7 @@ vim.keymap.set("n", "<C-c>", "ciw")
|
|||||||
```
|
```
|
||||||
|
|
||||||
folke cmd
|
folke cmd
|
||||||
|
|
||||||
```lua
|
```lua
|
||||||
-- show cursor line only in active window
|
-- show cursor line only in active window
|
||||||
vim.api.nvim_create_autocmd({ "InsertLeave", "WinEnter" }, {
|
vim.api.nvim_create_autocmd({ "InsertLeave", "WinEnter" }, {
|
||||||
@@ -210,6 +206,7 @@ vim.api.nvim_create_autocmd("BufWritePre", {
|
|||||||
```
|
```
|
||||||
|
|
||||||
Enable folding with TS:
|
Enable folding with TS:
|
||||||
|
|
||||||
```
|
```
|
||||||
vim.opt.foldmethod = "expr"
|
vim.opt.foldmethod = "expr"
|
||||||
vim.opt.foldexpr = "nvim_treesitter#foldexpr()"
|
vim.opt.foldexpr = "nvim_treesitter#foldexpr()"
|
||||||
|
|||||||
@@ -2,6 +2,12 @@ local M = {}
|
|||||||
|
|
||||||
function M.get()
|
function M.get()
|
||||||
return {
|
return {
|
||||||
|
{
|
||||||
|
ft = 'yaml',
|
||||||
|
ts = 'yaml',
|
||||||
|
lsp = 'yaml-language-server',
|
||||||
|
format = { 'prettierd', 'prettier' },
|
||||||
|
},
|
||||||
{ ts = { 'yaml', 'toml', 'sql', 'diff', 'dockerfile', 'gitcommit', 'gitignore' } },
|
{ ts = { 'yaml', 'toml', 'sql', 'diff', 'dockerfile', 'gitcommit', 'gitignore' } },
|
||||||
{ ts = { 'c', 'cpp', 'go', 'rust', 'python' } },
|
{ ts = { 'c', 'cpp', 'go', 'rust', 'python' } },
|
||||||
|
|
||||||
|
|||||||
@@ -73,7 +73,8 @@ vim.api.nvim_create_user_command('Sync', function()
|
|||||||
end, {})
|
end, {})
|
||||||
|
|
||||||
vim.api.nvim_create_user_command('FetchLspConfigs', function()
|
vim.api.nvim_create_user_command('FetchLspConfigs', function()
|
||||||
local base_url = 'https://raw.githubusercontent.com/neovim/nvim-lspconfig/master/lsp/'
|
-- local base_url = 'https://raw.githubusercontent.com/neovim/nvim-lspconfig/master/lsp/'
|
||||||
|
local base_url = 'https://raw.githubusercontent.com/neovim/nvim-lspconfig/refs/heads/master/lsp/'
|
||||||
|
|
||||||
local lm = require('plugins.language-manager')
|
local lm = require('plugins.language-manager')
|
||||||
lm.invalidate_cache()
|
lm.invalidate_cache()
|
||||||
|
|||||||
Reference in New Issue
Block a user