Skip to content

chasingRs/astronvim-config

 
 

Repository files navigation

AstroNvimV5 Config

Support neovim version

neovim >= 0.11, recommend 0.11.0

Features

this config supports development in TypeScript,Python,Go,Rust,markdown,C/Cpp,Flutter,etc.

  • Typescript: vtsls work with volar2
  • Python: basedpyright
  • Go: gopher.nvim -- support go zero framework
  • Markdown: iamcco/markdown-preview.nvim,
  • Rust: mrcjkb/rustaceanvim
  • Flutter: flutter-nvim/flutter-tools.nvim
  • C/C++:clangd+clang-format+clazy-standalone+neocmake+cmake-lint+cmake-format

🛠️ Installation

The system should support these commands

npm,rustc,go

Recommend install

See scripts/setup_arch_linux.sh and setup_mac.sh for required prerequisites

Note: for rust development

Note

rustup and mason's installation of rust-analzyer are different and may cause some bugs, manual installation is recommended.

rustup component add rust-analyzer

Make a backup of your current nvim and shared folder

mv ~/.config/nvim ~/.config/nvim.bak
mv ~/.local/share/nvim ~/.local/share/nvim.bak
mv ~/.local/state/nvim ~/.local/state/nvim.bak
mv ~/.cache/nvim ~/.cache/nvim.bak

Clone the repository

git clone https://github.com/CWndpkj/nvimConfigs.git ~/.config/nvim

Start Neovim

nvim

Tips

NVcheatsheet

<F2>

nvcheatsheet

Use Lazygit

<leader>tl

lazygit

Install unimatrix

<Leader>tm

Neovim requirements

npm install -g neovim
pip install pynvim

Markdown Image Paste

pip install pillow

Input Auto Switch

brew tap daipeihust/tap
brew install im-select
im-select

run im-select & copy result to im-select.lua

return {
  "chaozwn/im-select.nvim",
  lazy = false,
  opts = {
    default_main_select = "com.sogou.inputmethod.sogou.pinyin", -- update your input method
    set_previous_events = { "InsertEnter", "FocusLost" },
  },
}

Support for neovide

brew install neovide
neovide .

Support Lazydocker

trigger command: <leader>td

brew install lazydocker

General Mappings

Action Mapping Mode
Leader key Space n
Resize up Ctrl+Up n
Resize Down Ctrl+Down n
Resize Left Ctrl+Left n
Resize Right Ctrl+Right n
Up Window Ctrl+k n
Down Window Ctrl+j n
Left Window Ctrl+h n
Right Window Ctrl+l n
Force Write Ctrl+s n
Force Quit Ctrl+q n
New File Leader+n n
Close Buffer Leader+b+d n
Next Tab (real vim tab) Tab n
Previous Tab (real vim tab) Shift+Tab n
Comment Control+/ n
Horizontal Split / n
Vertical Split | n
Open task menu Leader+n n

Copilot Mappings

Action Mapping Mode
Open chat panel Leader+n+n n
Accept inline suggestion Ctrl+. n

Terminal Mappings

Action Mapping Mode
Toggle Terminal F7 n
Close Terminal Control+q n
Split Terminal Control+F7 n

Signature Help

vim.lsp.buf.hover() KK jump into signature help float window

Tip

Displays hover information about the symbol under the cursor in a floating window. Calling the function twice will jump into the floating window.

About

astronvim_config

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Lua 96.5%
  • Tree-sitter Query 2.8%
  • Shell 0.7%