Code Monkey home page Code Monkey logo

lvim's Introduction

Bloated LunarVim

Do not use as is, use it as a source of inspiration.

I've customized my ZSH/Tmux/Wezterm too much, so it might not work properly 😅

Screenshot 2024-06-04 at 18 26 59
Table of Contents (🔎 Click to expand/collapse)

Theme

Themes are automatically changed based on time of the day:

Theme Time of the day
rose-pine [1am, 9am)
tokyonight [9am, 5pm)
catppuccin [5pm, 9pm)
kanagawa [9pm, 11:59pm), [0am, 1am]

You can change this in plugins.lua and theme.lua or just disable it and install your own theme

lvim.colorscheme = "catppuccin"
lvim.builtin.time_based_themes = false
lvim.plugins = {
  {
    "catppuccin/nvim",
    as = "catppuccin",
    config = function()
      require("catppuccin").setup()
    end,
  }
}

Customization

Customization (🔎 Click to expand/collapse)
  • I'm using neovim 0.11 head
  • Do not use as is, too much bloated! Also do not use on a potato PC!!
  • i have a auto command to disable syntax,etc when you open files larger than 1MB
  • if you don't want to use harpoon, disable it
    • lvim.builtin.harpoon = { active = false }
  • if you want to try out GitHub copilot, change the following
    • lvim.builtin.sell_your_soul_to_devil = { active = true, prada = false }
    • in case you want to use cmp-copilot, set prada=true after copilot installation
  • I use a custom lualine disable it if you don't like it
    • lvim.builtin.fancy_statusline = { active = false }
  • You can use the diffview plugin instead of normal gitsigns diff
    • lvim.builtin.fancy_diff = { active = true }
  • if you want to use debugging, change the following line to true, also install codelldb:
    • lvim.builtin.dap.active = true
  • sometimes instead of saving you jump trough jumplist 😢 just disable nvim-lastplace
    • lvim.builtin.lastplace = { active = false }
  • sometimes cmp-tabnine doesn't play nice, you can disable it :)
    • lvim.builtin.tabnine = { active = false }
  • if you don't need testing, just disable it (use ultest or neotest)
    • lvim.builtin.test_runner = { active = false, runner = "ultest" }
  • if you don't want cheat.sh integration, disable it
    • lvim.builtin.cheat = { active = false }
  • if you don't want the SQL integration, disable it
    • lvim.builtin.sql_integration = { active = false }
  • if you don't like smooth scrolling, disable it
    • lvim.builtin.smooth_scroll= ""
  • if you want an obvious focused window, and you don't get seizures from it
    • lvim.builtin.nonumber_unfocus = true
  • choose between hop and leap or flash as your favorite motion provider
    • lvim.builtin.motion_provider = "hop"
  • choose between filename->incline and treesitter->winbar or navic as your winbar provider
    • lvim.builtin.winbar_provider = "treesitter"
  • if you don't need CSV support, disable it
    • lvim.builtin.csv_support = false
  • if you want to use the cool make and run system, enable it
    • lvim.builtin.task_runner = "async_tasks"
  • you can choose between nvimtree and neo-tree as your file tree viewer
    • lvim.builtin.tree_provider = "neo-tree"
  • you can use noice.nvim if you want
    • lvim.builtin.noice = { active = true }
  • If you wanna see the issues, change default_diagnostic_config.virtual_text inside builtin.lua
  • I'm using skim for latex stuff, change it to zathura if you are on linux

Install

Prerequisites (🔎 Click to expand/collapse)

Prerequisites

  brew install neovim --nightly
curl --proto '=https' --tlsv1.2 -sSf "https://sh.rustup.rs" | sh
cargo install ripgrep fd-find
  • NodeJS >= v16.13.0 most language servers need this
brew install node
bash <(curl -s "https://raw.githubusercontent.com/lunarvim/lunarvim/master/utils/installer/install.sh")
mv ~/.config/lvim ~/.config/lvim_backup
git clone https://github.com/abzcoding/lvim.git ~/.config/lvim
lvim +LvimUpdate +LvimCacheReset +q
lvim # run :Lazy sync

Java

Please run the following to have a better debugging and testing support for java

mkdir -p ~/workspace
git clone [email protected]:microsoft/java-debug.git ~/.config/lvim/.java-debug
cd ~/.config/lvim/.java-debug/
./mvnw clean install
git clone [email protected]:microsoft/vscode-java-test.git ~/.config/lvim/.vscode-java-test
cd ~/.config/lvim/.vscode-java-test
npm install
npm run build-plugin

Recommended Fonts

On macOS with Homebrew, choose one of the Nerd Fonts, for example, here are some popular fonts:

brew tap homebrew/cask-fonts
brew search nerd-font
brew install --cask font-fira-code-nerd-font
brew install --cask font-victor-mono-nerd-font
brew install --cask font-iosevka-nerd-font-mono
brew install --cask font-hack-nerd-font
Other Stuff (🔎 Click to expand/collapse)

Language-Server Protocol (LSP)

To leverage LSP auto-completions and other functionalities, after you open a file in Neovim, run :MasonInstall <server> to use mason installation feature. Use Tab to list available servers.

Upgrade

cd ~/.config/lvim
git pull
lvim # run :Lazy sync

Recommended Linters

You can use mason to install these:

cargo install selene  # if you want to use selene instead of luacheck
brew install hadolint  # if you want to lint dockerfiles
pip install vim-vint  # for vim linting
# install llvm and clang_format for clang stuff
npm install -g @fsouza/prettierd # if you want to use prettierd
pip install yapf flake8 black  # for python stuff
# if you want to use the markdown thingy
brew install vale markdownlint-cli
cp -r ~/.config/lvim/.vale ~/.config/vale
# fix the address inside .vale.ini
cp ~/.config/lvim/vale_config.ini ~/.vale.ini
# if you want the latex stuff
# brew install --cask mactex-no-gui # for mac
# or install zathura and chktex on linux

In case you want a better tex support in mac, check this out

if you want the custom gostructhelper, first get the pkg:

cd /tmp
git clone https://github.com/vanhtuan0409/gostructhelper.git
cd gostructhelper/cmds/gostructhelper
go build -o /usr/local/bin/gostructhelper && chmod 0755 /usr/local/bin/gostructhelper

Collaborative Editing

The default is to serve localhost only, on port 8080. For a more advanced (remote server) overview see Deploy a server

Server side

  • :InstantStartServer [host] [port] : Start the server using
    • :InstantStartSingle [host] [port] : This only shares the current buffer.
    • :InstantStartSession [host] [port] :This shares all opened (and newly opened) buffers with the other clients

Client side

  • let g:instant_username="sth" : Set your preferred username.
    • :InstantJoinSingle [host] [port] : Use this command if another client already initiated a single share.
    • :InstantJoinSession [host] [port] : Use this command if another client already initiated a session share

Screenshot

Screenshots (🔎 Click to expand/collapse) Screenshot 2024-06-04 at 18 30 21

BufferLine

Screenshot 2024-06-04 at 18 30 53

StatusLine

Screenshot 2024-06-04 at 18 32 55

Dashboard

Screenshot 2024-06-04 at 18 33 48 Screenshot 2024-06-04 at 18 33 56

lsp_signature

lsp_signature_2 lsp_signature

Tabnine

tabnine

Lang Server

completion Screen Shot 2021-10-18 at 5 43 22 PM

diagnostics using gl Screen_Shot_2021-07-31_at_7 54 52_PM

code_actions using ga Screen Shot 2021-10-18 at 6 25 58 PM

code_lens and inlay_hints when supported by lang server Screen Shot 2021-10-18 at 6 26 47 PM

references in qf Screen Shot 2021-10-18 at 6 31 03 PM

treesitter backed folding Screen Shot 2021-10-18 at 6 05 29 PM

peek using gp

Screen Shot 2021-10-18 at 6 33 06 PM

rename using <leader>lr

Screen Shot 2021-11-04 at 3 54 15 PM

Builtin Terminal

Screen Shot 2021-10-18 at 6 07 13 PM

Test

Screen Shot 2021-10-18 at 6 13 22 PM

ETC

k8s help

Screen Shot 2021-10-18 at 6 23 21 PM

lazy git integration

Screen Shot 2021-10-18 at 6 27 45 PM

zen mode

Screen Shot 2021-10-18 at 6 30 00 PM

Cheat.sh integration

use <leader>? Screen Shot 2021-10-18 at 6 02 31 PM

Screen Shot 2021-10-18 at 6 01 34 PM

Symbols Outline

Screen Shot 2021-10-18 at 6 03 57 PM

Plugins Included

Plugins (🔎 Click to expand/collapse)

Optional Plugins

Structure

Structure (🔎 Click to expand/collapse)

Custom Key-mappings

Note that,

  • Leader key set as Space
Key-mappings (🔎 Click to expand/collapse) Modes: 𝐍=normal 𝐕=visual 𝐒=select 𝐈=insert 𝐂=command

UI

Key Mode Action Plugin or Mapping
Space+e 𝐍 Open file tree NvimTree
Space+o 𝐍 Open symbols Symbols-outline
Space+f 𝐍 Open file finder Telescope
Space+h 𝐍 Remove highlight nohlsearch<
Space+/ 𝐍 Toggle comment Comment.nvim
Space+? 𝐍 Open cheats cheat.sh
Space+I 𝐍 Inlay Hints require('vim.lsp._inlay_hint').refresh()
Space+' 𝐍 Open marks which-key marks
Space+z 𝐍 Zen mode zen-mode.nvim
Space+P 𝐍 Projects project.nvim
Ctrl+</kbd> 𝐈 𝐍 Open terminal toggleterm.nvim
Alt+0 𝐈 𝐍 Vertical terminal toggleterm.nvim
Ctrl+s 𝐈 Show signature help vim.lsp.buf.signature_help()
Alt+s 𝐈 Snippet selection Telescope luasnip extension
Space+C or Ctrl+P 𝐍 Command Palette legendary.nvim

Motion

Key Mode Action Plugin or Mapping
f 𝐍 find next character HopChar1CurrentLineAC or leap_f or Flash.CharActions
F 𝐍 find previous character HopChar1CurrentLineBC or leap_F or Flash.CharActions
s 𝐍 find character HopChar2MW or leap_s or require("flash").jump()
S 𝐍 find word HopWordMW or leap_S or 2char jump
Alt+a 𝐈 select all ggVG
Alt+a 𝐍 increment number C-A
Alt+x 𝐍 decrement number C-X

LSP

Key Mode Action
Tab / Shift-Tab 𝐈 Navigate completion-menu
Enter 𝐈 Select completion or expand snippet
Upor Down 𝐈 Movement in completion pop-up
]+d 𝐍 Next diagnostic
[+d 𝐍 Previous diagnostic
Space+l+j or Space+l+k 𝐍 Next/previous LSP diagnostic
Space+l+r 𝐍 replace current word in project
Ctrl+e 𝐈 Close pop-up
Tab / Shift-Tab 𝐈 𝐒 Navigate snippet placeholders
Space+l 𝐍 keybindings for lsp
g+a 𝐍 code actions
g+A 𝐍 codelens actions
g+d 𝐍 goto definition
g+t 𝐍 goto type definition
g+D 𝐍 goto declaration
g+I 𝐍 goto implementation
g+p 𝐍 peek implementation
g+r 𝐍 goto references
g+s 𝐍 show signature help

Plugin: AsyncTasks

Key Mode Action
Space+m+f 𝐍 Build File
Space+m+p 𝐍 Build Project
Space+m+e 𝐍 Edit Tasks
Space+m+l 𝐍 List Tasks
Space+r+f 𝐍 Run File
Space+r+p 𝐍 Run Project

Plugin: Gitsigns

Key Mode Action
Space+g+j or Space+g+k 𝐍 Next/previous Git hunk
Space+g+p 𝐍 Preview hunk
Space+g+l 𝐍 Blame line
Space+g+s 𝐍 𝐕 Stage hunk
Space+g+u 𝐍 Undo stage hunk
Space+g+d 𝐍 Diff to head
Space+g+h 𝐍 Buffer git history
Space+g+R 𝐍 𝐕 Reset hunk

Plugin: LazyGit

Key Mode Action
Space+g+g 𝐍 Open lazy git UI

Plugin: Telescope

Key Mode Action
Space+f 𝐍 File search
Space+P 𝐍 Project search
Space+s+s 𝐍 Grep search
Space+s+f 𝐍 Telescope find_files
Space+s+e 𝐍 Telescope file_browser
Space+F+l 𝐍 Reopen last search
Space+b+f 𝐍 Buffers
Space+s+c 𝐍 Colorschemes
Space+s+C 𝐍 Command history
Space+s+h 𝐍 Find help
Space+s+k 𝐍 Keymap search
Space+s+M 𝐍 Man Pages search
Space+s+r 𝐍 Register search
Space+s+t 𝐕 Grep string under cursor
Space+s+t 𝐍 Grep raw
Space+F+b 𝐍 Builtin search
Space+F+f 𝐍 Current buffer search
Space+F+g 𝐍 Git files search
Space+F+i 𝐍 Installed plugins
Space+F+p 𝐍 Project search
Space+F+i 𝐍 Installed plugins
in Telescope window
CR 𝐈 𝐍 Multi/Single Open
Ctrl+c 𝐈 𝐍 Exit telescope
Ctrl+v 𝐈 𝐍 Open in a vertical split
Ctrl+s 𝐈 𝐍 Open in a split
Ctrl+t 𝐈 𝐍 Open in a tab
Ctrl+b 𝐈 Go back in Command Palette
Tab 𝐈 𝐍 Toggle Selection + Next
Shift+Tab 𝐈 𝐍 Toggle Selection + Prev

Plugin: Harpoon

Key Mode Action
Space+Space 𝐍 Show harpoon shortlist
Space+a 𝐍 Add file to shortlist
Space+1 𝐍 Jump to first file on shortlist
Space+2 𝐍 Jump to second file on shortlist
Space+3 𝐍 Jump to third file on shortlist
Space+4 𝐍 Jump to forth file on shortlist

Plugin: Neogen

Key Mode Action
Space+n+c 𝐍 Class documentation
Space+n+f 𝐍 Function documentation
Space+n+t 𝐍 Type documentation
Space+n+F 𝐍 File documentation

Plugin: Persistence

Key Mode Action
Space+q+d 𝐍 Delete Session
Space+q+l 𝐍 Load Session
Space+q+s 𝐍 Save Session

Plugin: Bufferline

Key Mode Action
Shift+x 𝐍 Close buffer
Space+b+f 𝐍 Find buffer
Space+b+b 𝐍 Toggle buffer groups
Space+b+p 𝐍 Toggle pin
Space+b+s 𝐍 Pick buffer
Space+b+1 𝐍 Goto buffer 1
Space+b+h 𝐍 Close all to left
Space+b+l 𝐍 Close all to right
Space+b+D 𝐍 Sort by directory
Space+b+L 𝐍 Sort by language

Plugin: Trouble

Key Mode Action
Space+T+d 𝐍 Diagnostics
Space+T+f 𝐍 Definitions
Space+T+r 𝐍 References
Space+T+t 𝐍 Todo
Space+T+w 𝐍 Workspace diagnostics

Plugin: Ultest

Key Mode Action
Space+t+f 𝐍 Run all tests in a file
Space+t+n 𝐍 Only run nearest test
Space+t+s 𝐍 Open test summary

Plugin: Neotest

Key Mode Action
Space+t+a 𝐍 Run all tests
Space+t+f 𝐍 Run tests in a file
Space+t+r 𝐍 Only run nearest test
Space+t+s 𝐍 Open test summary
Space+t+o 𝐍 Open test output
Space+t+w 𝐍 Watch test
Space+t+x 𝐍 Stop test
Space+t+n 𝐍 Jump to next failed test
Space+t+p 𝐍 Jump to previous failed test
Space+t+c 𝐍 Cancel test

Plugin: Spectre

Key Mode Action
Space+R+p 𝐍 Replace word in project
Space+R+w 𝐍 Replace visually selected word
Space+R+f 𝐍 Replace word in current buffer

Plugin: SSR

Key Mode Action
Space+r 𝐕 Structural replace confirm using <leader><cr>
Space+R+s 𝐍 Structural replace confirm using <leader><cr>

Plugin: Copilot

Key Mode Action
Ctrl+h 𝐈 copilot#Accept("<CR>")
Ctrl+e 𝐈 Close cmp menu
Ctrl+] 𝐈 <Plug>(copilot-dismiss)
Alt+] 𝐈 <Plug>(copilot-next)
Alt+[ 𝐈 <Plug>(copilot-previous)
Alt+</kbd> 𝐈 "<Cmd>vertical Copilot panel<CR>"

Plugin: Lsp_Lines

Key Mode Action
Space+v 𝐍 Toggle showing lsp_lines

Plugin: Overseer

Key Mode Action
Space+r+f 𝐍 Run
Space+r+p 𝐍 Run with cmd
Space+r+t 𝐍 Toggle output
Space+m+n 𝐍 New Task
Space+m+l 𝐍 Load Task Bundle
Space+m+s 𝐍 Save Task Bundle
Space+m+q 𝐍 Quick Action
Space+m+f 𝐍 Task Action

Plugin: NeoTree

Key Mode Action
Space+e 𝐍 Toggle tree
> and < 𝐍 Next and prev source inside tree
Enter 𝐍 Open
s 𝐍 Open in vertical split
S 𝐍 Open in horizontal spit
H 𝐍 Toggle hidden files
a 𝐍 Add files/dirs
A 𝐍 Add new dir
r 𝐍 Rename
h 𝐍 Go Updir
l 𝐍 Open
P 𝐍 Toggle preview
/ 𝐍 Fuzzy finder

Plugin: Mind

Key Mode Action
Space+M+M 𝐍 Open Main Tree
Space+M+m 𝐍 Open Local Tree
Enter 𝐍 open data
Tab 𝐍 toggle node
Shift+Tab 𝐍 toggle parent
/ 𝐍 select path
$ 𝐍 change icons menu
c 𝐍 create new node
q 𝐍 quit

Troubleshooting

  1. Check your neovim version. Are you on the newest nightly version?
  2. make sure to run :Lazy sync
  3. Reset your Lunarvim cache using :LvimCacheReset

lvim's People

Contributors

abzcoding avatar alechp avatar crisidev avatar itsdawei avatar jopemachine avatar luong-komorebi avatar luxus avatar thinkryan avatar uzaaft avatar venson avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

lvim's Issues

Error in tss.lua file

After pressing the keys "$" and "{" to use template strings on my javascript project, the following error appears:
image
I'm using lunarvim rolling and neovim dev branch

Rust_Tools.nvim and Rust-analyzer

Hi abzcoding,

Have you figured out to get rust-analyzer and rust_tools functioning correctly in lunarvim?

I've gone sideways trying to figure out how to get the [shift-k] hover definition of functions and inlay hints working from these two addons to facilitate learning Rust, but no matter what i've tried it's not getting anywhere. I tried pulling your lvim config to see if it worked in that, but alas no dice.

user snippets seems not working

I'd like to add some customized html snippets to the config.
nvim version:

NVIM v0.7.0
Build type: Release
LuaJIT 2.1.0-beta3
Compiled by brew@Monterey

With latest lunarvim and lvim

  1. Modified the .config/lvim/snippets/package.json
{
  "name": "nvim-snippets",
  "author": "abzcoding",
  "engines": {
    "vscode": "^1.11.0"
  },
  "contributes": {
    "snippets": [
      {
        "language": "lua",
        "path": "./lua.json"
      },
      {
        "language": [
          "typescript",
          "typescriptreact"
        ],
        "path": "./typescript.json"
      },
      {
        "language": "typescriptreact",
        "path": "./react-ts.json"
      },
      {
        "language": "html",
        "path": "./vue-html.json"
      }
    ]
  }
}
  1. Create the vue-html.json
{
	"vue htm": {
		"scope": "html",
		"prefix": "vuehtml",
		"body": [
			"<!DOCTYPE html>",
			"<html lang=\"en\">",
			"",
			"<head>",
			"    <meta charset=\"UTF-8\">",
			"    <meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\">",
			"    <meta http-equiv=\"X-UA-Compatible\" content=\"ie=edge\">",
			"    <title>Document</title>",
			"</head>",
			"",
			"<body>",
			"    <div id=\"app\">",
			"",
			"    </div>",
			"    <script src=\"vue.js\"></script>",
			"    <script>",
			"        new Vue({",
			"            el: '#app',",
			"            data: {",
			"                $1",
			"            }",
			"        })",
			"    </script>",
			"</body>",
			"",
			"</html>",
		],
		"description": "my vue template in html"
	}
}
  1. do not work at all, please help

"]m"之类的快捷键在C代码中无法正常使用

"]m"跳转到下一个method的开始, 在C文件里面, 它识别的是下一个"{",比如:

int main()  
{    //一开始光标在这里
    int flag= 0;
    if(flag)
    {    //实际跳转到这里
        return sum(flag);
    } 
    return 0;
}

int sum(int num)
{     //期望跳转到这里
    return num+10;
}

Some issues with async.lua and eslint_d

I'm wondering if such a noob-like question is allowed but I really like your config @abzcoding and wondering if you can help me with this error I got.

Error executing vim.schedule lua callback: ...ck/packer/start/plenary.nvim/lua/plenary/async/async.lua:14: The coroutine failed
 with this message: ...e/pack/packer/start/null-ls.nvim/lua/null-ls/helpers.lua:152: command eslint_d is not executable (make s
ure it's installed and on your $PATH)

I've been looking anywhere to find where the path to the problem at, but can't figure out exactly where.
Thanks

Ftplugin configurations won't work

After upgrading to the latest version, it seems that configurations in ./after/ftplugin aren't working anymore.
For example, I have a file ./after/ftplugin/yaml.vim with the following content:

setlocal tabstop=2
setlocal shiftwidth=2
setlocal expandtab

But it doesn't seem to be recognized. In a .yaml or .yml file, tabs won't get expanded unless I explicitly set :set expandtab

Lazyloading tabnine

Hi,

Have you figured out how to lazyload tabnine so that it does not add about 700 ms(on my machine) to the startup time?

I tried, but unsuccessfully.

Persistence error in function 'stop'

This error below appears when i type the keymappings for persistence, like 'space q d' (quit without saving session). Any idea on how to solve it?

image

persistence error

I can't use persistence when I quit

what's wrong with it

E5108: Error executing lua ...ack/packer/opt/persistence.nvim/lua/persistence/init.lua:39: Vim(autocmd):E216: No such group or event:
Persistence
stack traceback:
        [C]: in function 'cmd'
        ...ack/packer/opt/persistence.nvim/lua/persistence/init.lua:39: in function 'stop'
        [string ":lua"]:1: in main chunk

adding themeOption and making timebasedThemes as fallback

hi abz,
I tried to add a if statement for the themes, I struggle with understanding the Lua code ;D
can we have a lvim.builtin.timebasedTheme = true
it would be a good solution for #59
I like the timebased themes but sometimes I work outside and I need a bright theme

[Bug] Scroll in Lazygit inside toggleterm window

Hi !

First thank you for your nice config 🚀
When i open Lazygit from neovim (toggleterm) when i try to scroll down with j the cursor does move only after i release it. This does not happen when i scroll up with k.

I do not encounter this bug in regular Lazygit (not inside toggleterm)

Quick video with bug demo

Screen.Recording.2022-03-27.at.16.42.39.mov

nvim-cmp problem

Nvim-cmp has changed recently.And it has a problem now.Please fix this🙏🙏🙏

[nvim-cmp] documentation is deprecated.
[nvim-cmp] Please use window.documentation= "native" instead.

Invalid Config

Experiencing the following error message with NVIM v0.6.0-dev+627-gb5b025f6a and LuaJIT 2.1.0-beta3.
This is an issue on my local machine with just your code, not my own repository. Attempted to grep and find the files that are mentioned, but no results. Any idea what might cause this error?

‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾‾
12:02:48 [WARN ] lvim: 'Invalid configuration: vim/shared.lua:247: invalid "behavior": table: 0x7fdb01d3d758' file="init.lua", line=
80
Highlight group 'Normal' has no background highlight.

Please provide an RGB hex value or highlight group with a background value for 'background_colour' option

Defaulting to #000000
Press ENTER or type command to continue

stuck on PackerSync

Hi,
Sometimes PackerSync stuck while syncing the plugins. I remember that you posted a fix on the lunar vim repo but I didn't find it again
Screenshot 2022-07-02 at 11 10 35

Html snippets issue

Recently i was editing a html file, and trying to use html snippets, but, i've got some issues using them. When typing for example h1 and just after, pressing enter, works fine, but, when i type h2 inside h1 and then press enter, this issue occurs:

image

image

I don't know if this is a snippets plugin problem, or a configuration file problem.

pcre2 fails to install with packer.nvim

I've been trying to figure out why pcre2 fails every single time i update with PackerSync. Have you encountered this issue before?

✗ Failed to install pcre2
Cloning into 'lua-pcre2'...
Note: switching to 'ae3fdf9155db6981ff9a60339739303c0661dab7'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by switching back to a branch.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -c with the switch command. Example:

  git switch -c <new-branch-name>

Or undo this operation with:

  git switch -

Turn off this advice by setting config variable advice.detachedHead to false
Submodule 'deps/lauxhlib' (https://github.com/mah0x211/lauxhlib.git) registered for path 'deps/lauxhlib'
Cloning into '/private/var/folders/p0/ky08kpq12hb7nz12bwk6tlhm0000gp/T/luarocks_pcre2-0.2.0-1-X9kWtb/lua-pcre2/deps/lauxhlib'...
Error: Could not find header file for LIBPCRE2
  No file pcre2.h in /usr/include
  No file pcre2.h in /include
You may have to install LIBPCRE2 in your system and/or pass LIBPCRE2_DIR or LIBPCRE2_INCDIR to the luarocks command.
Example: luarocks install pcre2 LIBPCRE2_DIR=/usr/local

 Press 'q' to quit
 Press '<CR>' to show more info
 Press 'd' to show the diff
 Press 'r' to revert an update
 Press 'R' to retry failed operations

Ich brauche Hilfe

ich habe gesehen du gibst jetzt Unterstützung in allen sprachen.

Nein, es ist nur ein Spass. Danke für die grossartige Arbeit mit deiner Konfiguration

Theme problem

  1. updated to the the Fix #25
  2. finished the :PackerCompile
  3. finished :PackerSync and everything already up to date
  4. finished :LvimCacheReset
  5. restart lvim and got the following message:
    20:25:14 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="init.lua", line= 105

~/.cache/nvim/log:

WARN  2022-03-29T01:36:21.251 3071  deadly_signal:161: got signal 15 (SIGTERM)
WARN  2022-03-28T20:14:38.702 20067 deadly_signal:161: got signal 1 (SIGHUP)

~/.cache/nvim/lvim.log:

00:25:48 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
00:25:53 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
00:27:44 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
00:28:03 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
00:28:28 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
00:28:48 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
00:36:37 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
00:36:57 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
00:37:08 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
00:38:53 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
00:41:30 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
00:44:29 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
01:35:22 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
01:35:34 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
01:36:06 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
20:12:20 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
20:12:34 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
20:13:04 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
20:13:59 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
20:14:14 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
20:18:20 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105
20:23:58 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="lua/lvim/config/init.lua", line=105

~/.cache/nvim/lsp.log

[START][2022-03-28 00:24:10] LSP logging initiated
[START][2022-03-28 00:24:17] LSP logging initiated
[START][2022-03-28 00:25:48] LSP logging initiated
[START][2022-03-28 00:25:53] LSP logging initiated
[START][2022-03-28 00:27:44] LSP logging initiated
[START][2022-03-28 00:28:03] LSP logging initiated
[START][2022-03-28 00:28:28] LSP logging initiated
[START][2022-03-28 00:28:48] LSP logging initiated
[WARN][2022-03-28 00:34:17] .../lua/vim/lsp.lua:751	"server_request: no handler found for"	"workspace/semanticTokens/refresh"
[WARN][2022-03-28 00:34:17] .../lua/vim/lsp.lua:751	"server_request: no handler found for"	"workspace/semanticTokens/refresh"
[WARN][2022-03-28 00:34:17] .../lua/vim/lsp.lua:751	"server_request: no handler found for"	"workspace/semanticTokens/refresh"
[WARN][2022-03-28 00:34:17] .../lua/vim/lsp.lua:751	"server_request: no handler found for"	"workspace/semanticTokens/refresh"
[START][2022-03-28 00:36:37] LSP logging initiated
[START][2022-03-28 00:36:57] LSP logging initiated
[START][2022-03-28 00:37:08] LSP logging initiated
[START][2022-03-28 00:38:53] LSP logging initiated
[WARN][2022-03-28 00:39:07] .../lua/vim/lsp.lua:751	"server_request: no handler found for"	"workspace/semanticTokens/refresh"
[WARN][2022-03-28 00:39:07] .../lua/vim/lsp.lua:751	"server_request: no handler found for"	"workspace/semanticTokens/refresh"
[WARN][2022-03-28 00:39:07] .../lua/vim/lsp.lua:751	"server_request: no handler found for"	"workspace/semanticTokens/refresh"
[WARN][2022-03-28 00:39:07] .../lua/vim/lsp.lua:751	"server_request: no handler found for"	"workspace/semanticTokens/refresh"
[START][2022-03-28 00:41:30] LSP logging initiated
[START][2022-03-28 00:44:29] LSP logging initiated
[WARN][2022-03-28 00:46:10] .../lua/vim/lsp.lua:751	"server_request: no handler found for"	"workspace/semanticTokens/refresh"
[WARN][2022-03-28 00:46:10] .../lua/vim/lsp.lua:751	"server_request: no handler found for"	"workspace/semanticTokens/refresh"
[WARN][2022-03-28 00:46:10] .../lua/vim/lsp.lua:751	"server_request: no handler found for"	"workspace/semanticTokens/refresh"
[WARN][2022-03-28 00:46:10] .../lua/vim/lsp.lua:751	"server_request: no handler found for"	"workspace/semanticTokens/refresh"
[START][2022-03-29 01:35:22] LSP logging initiated
[START][2022-03-29 01:35:34] LSP logging initiated
[START][2022-03-29 01:36:06] LSP logging initiated
[START][2022-03-28 20:12:20] LSP logging initiated
[START][2022-03-28 20:12:34] LSP logging initiated
[START][2022-03-28 20:13:59] LSP logging initiated
[START][2022-03-28 20:14:14] LSP logging initiated
[START][2022-03-28 20:13:04] LSP logging initiated
[START][2022-03-28 20:18:20] LSP logging initiated
[START][2022-03-28 20:23:58] LSP logging initiated
[START][2022-03-28 20:25:14] LSP logging initiated

Icons missing

Hey @abzcoding

It seems that in my setup some icons are missing. The link to recommended fonts in the README.md ends up in a nirvana :) Could you help me to figure out what I am missing here? I've installed nerdfonts and firacode already.
Screenshot 2022-01-11 at 10 13 14

LSP and code navigation is very slow when working with C source codes with many lines

When I try to edit a C source file, if it is made of thousands of lines, then code navigation and LSP autocomplete is extremely slow.

What I noticed is that, if I do this to the buffer:

:set filetype=txt
:set syntax=c

then the LSP remains active with autocomplete, diagnostics etc. plus basic syntax highlight, but everything is much faster.

Probably this is due to some plugin or autocommand which supposedly get activated when I open a C file, with subsequent clangd LSP server launch.

Question is, how could I exactly identify the components slowing down everything, eventually disabling them, without having every time to repeat the two commands described above?

Some notes:

  • Disabling the LSP clangd, still leads to code editing slowness.
  • TSBufDisable highlight & indent seems to improve speed.
  • IndentBlanklineDisable also improve speed.

LvimInfo error

While trying to isolate why Packer rollbacks to a snapshot, 10 - 20 seconds after using PackerSync, i noticed the follow error when running LvimInfo.

Not sure if its more related to Lunarvim, if so i'll close here and repost.

E5108: Error executing lua vim/shared.lua:0: t: expected table, got nil
stack traceback:
[C]: in function 'error'
vim/shared.lua: in function 'validate'
vim/shared.lua: in function <vim/shared.lua:0>
vim/shared.lua: in function 'tbl_filter'
...elliot/.local/share/lunarvim/lvim/lua/lvim/core/info.lua:105: in function 'make_override_info'
...elliot/.local/share/lunarvim/lvim/lua/lvim/core/info.lua:153: in function 'toggle_popup'
[string ":lua"]:1: in main chunk

Seems my primary issue is related to the previous ones posted by Venson.

Using version:
NVIM v0.7.0-dev+1292-ge9b53f3fb
Build type: Release
LuaJIT 2.1.0-beta3

and already pulled your latest commits.

null-ts with typescript and vue files

Hey,

After updating to the latest version I am again facing issues with null-ls for *.ts and *.vue files. Do you have any idea how to resolve this?

Language servers I am using:

  • volar
  • tsserver

Screenshot 2022-05-19 at 10 49 05

Screenshot 2022-05-19 at 10 52 37

How did you make gitsigns "Stage Hunk" keymap for visual mode

Sorry if this sounds stupid 😂
but how did you make gitsigns "Stage Hunk" keymap (<leader>gs) available in visual mode?

I've searched for stage, gitsigns and which-key but couldn't find anything. I've looked at this keybinding.lua file but couldn't find anything about this as well.

I've tried using this in my own config.lua

lvim.builtin.which_key.mappings["g"]["s"] = {
    "<cmd>lua require 'gitsigns'.stage_hunk()<cr>", "Stage Hunk", mode="v"
}

this works in visual mode, but unfortunately this makes the keymap in normal mode disappear, and which-key doesn't support specifying multiple mode at the moment I think? (issue)

Thanks in advance!

use the right formatter

Hello Sir,

I am facing some troubles with formatters. Eg, I am working in a typescript project that has an eslint configuration in .eslintrc. However, when I am formatting the file, it seems that the language servier (tsserver in my case) will be used for formatting which applies different formatting rules compared when to running eslint --fix manually - the later takes the correct configuration.

Do you have any advice on how to fix this behavior?

Screenshot 2022-06-17 at 01 36 29

Ts and js file keybind maping error

When opening js or ts file, I received the following Error:

Error executing vim.schedule lua callback: /Users/huangwenxuan/.config/lvim/lua/user/tss.lua:17: attempt to call field 'map' (a nil value)
stack traceback:
        /Users/huangwenxuan/.config/lvim/lua/user/tss.lua:17: in function 'buf_map'
        /Users/huangwenxuan/.config/lvim/lua/user/tss.lua:127: in function '____on_attach_result_3'
        .../site/pack/packer/opt/typescript.nvim/lua/typescript.lua:2827: in function '_on_attach'
        ...ck/packer/start/nvim-lspconfig/lua/lspconfig/configs.lua:271: in function '_setup_buffer'
        ...ck/packer/start/nvim-lspconfig/lua/lspconfig/configs.lua:181: in function ''
        vim/_editor.lua: in function <vim/_editor.lua:0>

After commenting out M.buf_map lines , no error any more

  local function on_attach(client, bufnr)
  require("lvim.lsp").common_on_attach(client, bufnr)
  api.nvim_buf_create_user_command(bufnr, "CssToJs", css_to_js, { range = true })
--  M.buf_map(bufnr, "n", "gs", ":TypescriptRemoveUnused<CR>")
--  M.buf_map(bufnr, "n", "gS", ":TypescriptOrganizeImports<CR>")
--  M.buf_map(bufnr, "n", "go", ":TypescriptAddMissingImports<CR>")
--  M.buf_map(bufnr, "n", "gA", ":TypescriptFixAll<CR>")
--  M.buf_map(bufnr, "n", "gI", ":TypescriptRenameFile<CR>")
--  M.buf_map(bufnr, "i", "${", change_template_string_quotes, { nowait = true })
  api.nvim_buf_create_user_command(bufnr, "CssToJs", css_to_js, { range = true })
--  M.buf_map(bufnr, "n", "gx", ":set opfunc=v:lua.css_to_js<CR>g@")
--  M.buf_map(bufnr, "n", "gxx", ":CssToJs<CR>")
--  M.buf_map(bufnr, "v", "gx", ":CssToJs<CR>")
end

Error Copilot Setup

Error when try :Copilot setup

Error detected while processing function copilot#Command[19]..5[13]..<SNR>41_JsonBody:
line    3:
E474: Attempt to decode a blank string
E474: Failed to parse 

tsserver config overwrites lsp_highlight_document and add_lsp_buffer_keybindings.

I faced this issue where on .ts files the hover key does not work and displays man.vim: no manual entry for .... I found out that it came from add_lsp_buffer_keybindings. I did try to put it on the tsserver.lua file

local opts = {
  on_attach = function(client, _)
    ts_utils.setup_client(client)
    lsp_highlight_document(client)
    add_lsp_buffer_keybindings(client)
  end,
}

This in turn returns a new error saying that which_key attempts to concatenate a table value.

null-ls error after pulling the latest changes

Hi,

Thanks again for providing this awesome configuration!

After pulling the latest changes from this repository, I am running into an error in all *.ts and *.vue files.
Screenshot 2022-05-12 at 11 46 12

Any idea on how to resolve this?

NvimTree errors out with new renderer options

First of all, thanks for this repo, it is a great source of inspiration for my own neovim setup!

After cf0a5df, NvimTree is erroring out when starting vim with

unknown option: respect_buf_cwd | unknown option: renderer.highlight_git | unknown option: renderer.icons.show | unknown option: renderer.icons.glyphs | unknown option: renderer.root_folder_modifier

Disclaimer: I am not using this repo directly, but I am using it as an inspiration, so it could be probably my fault, but I am out of idea.

I have checked Lvim and the options are defined: https://github.com/LunarVim/LunarVim/blob/rolling/lua/lvim/core/nvimtree.lua#L67

I have already reset the cache, it did not help.

Do you have any idea?

user/builtin.lua:33: attempt to index field 'options' (a nil value)

I have just pulled your newest changes. Now I get the error: user/builtin.lua:33: attempt to index field 'options' (a nil value). It seems that optionsin lvim.builtin.bufferline.options.diagnostics_indicator does not exist anymore at the time of loading. I have reset the cache and also synced packer without success.
Is there sth else I would need to do to make it work again?
Thanks!

theme problem

After the recent lunarvim and your lvim update, I got the following error messages.
This still happens even with reinstall.

Error detected while processing /home/venson/.config/lvim/after/plugin/highlights.vim:
line   39:
E5108: Error executing lua /home/venson/.config/lvim/lua/user/theme.lua:333: attempt to index field 'fancy_teles
cope' (a nil value)
stack traceback:
        /home/venson/.config/lvim/lua/user/theme.lua:333: in function 'telescope_theme'
        [string ":lua"]:1: in main chunk
11:04:27 [WARN ] lvim: "Invalid configuration: vim/_meta.lua:170: E474: Invalid argument" file="init.lua", line=
105

I trie to comment out the fancy_telescope part in ~/.config/lvim/lua/user/theme.lua, which solve the error message, but the warn message remains.

Null-ls error

When opening lvim, this error message shows up, any idea on how to solve it?

image

jdtls null-ls/lsp error

Having a problem with jdtls. Using archLinux, zsh, neovim nighly, lvim rolling and your config (all up2date). jdt.ls is attached and working but some lsp/null-ls features arent working. CheckHealth is fine. I did :LspInstall jdtls. No reference-checks/doc-signatures/auto-imports and so on. However some lsp features are working.

I get "full" jdtls functionality using ChristianChiarulli nvim(from scratch) config.

When open a java file i get this lsp error: .../vim/lsp/rpc.lua:420 "rpc" "java" "stderr" "Error: Unable to access jarfile \n"

:LspInfo
image

lsp.log
image

lvim -v
image

I dont know how to debug that error further.

[Bug] `which-key` module is not correctly loaded in `keybindings.lua`

If I add this line at the start of keybindings.lua:

local whk_status, whk = pcall(require, "which-key")
if not whk_status then
  print("Error loading which-key: " .. whk_status)
  return
end

then the following error is reported, after a LvimCacheReset command:

11:33:40 [WARN ] lvim: "Invalid configuration: ...nfigurations\\Neovim\\config\\lvim/lua/user/keybindings.lua:5: attempt to concatenate local 'whk_status' (a boolean value)" file="init.lua", line=112

If I restart Neovim again, everything gets loaded with no warnings (probably cache affected that).

How could the which-key module be correctly loaded (through the pcall) in keybindings.lua after a cache reset?

Disable inlayhints for Typescript

Hi @abzcoding ,

Thanks for providing this great and comprehensive configuration for LunarVim! When I try to open a .ts file, I get an exception:

Vim:method typescript/inlayHints is not supported by any of the servers registered for the current buffer

How am I supposed to deactivate inlayHints for a specific language server? Thank You!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.