astronvim_config/README.md

115 lines
4.3 KiB
Markdown
Raw Permalink Normal View History

2022-10-02 06:56:31 +02:00
# My [AstroNvim](https://github.com/AstroNvim/AstroNvim) config
## README for the merlin server at FIT VUT can be found [here](https://github.com/jiriks74/astronvim_config/tree/merlin)
## How to install my config
2022-10-02 06:56:31 +02:00
- First you have to install AstroNvim
- Backup your previous nvim config
```bash
mv ~/.config/nvim ~/.config/nvimbackup
```
- Clone AstroNvim repository into ~/.config/nvim
```bash
git clone https://github.com/AstroNvim/AstroNvim ~/.config/nvim
nvim +PackerSync
```
2022-10-03 03:08:25 +02:00
- Clone my config into `~/.config/nvim/lua/user`
2022-10-03 04:02:54 +02:00
- For NeoVim >= 8.0
2022-10-02 06:56:31 +02:00
2022-10-03 04:02:54 +02:00
```bash
git clone https://github.com/jiriks74/astronvim_config ~/.config/nvim/lua/user
```
- For NeoVim < 8.0 use `neovim7.2` branch
2022-10-02 06:56:31 +02:00
```bash
git clone -b neovim7.2 https://github.com/jiriks74/astronvim_config ~/.config/nvim/lua/user
```
2022-10-25 21:38:59 +02:00
- Open nvim and run `:PackerSync`
2022-10-25 21:38:59 +02:00
```bash
nvim +PackerSync
2022-10-25 21:38:59 +02:00
```
## Useful info
- Folding with treesitter
- To get folding for your language, you need to run
`:TSInstall <language>` (eg. `TSInstall cpp` to get C++ folding)
- Install language servers
- Use `Space+p+I` keybind to open install menu.
- To install package under the cursor, press `i`
- To uninstall package under the cursor press `X`
- Debugging
- See `vimspector` under [`Extra plugin included`](#extra-plugins-included)
- LaTeX
- To use `vimtex` plugin, you need to have LaTeX installed
- [`texlive-most`](https://wiki.archlinux.org/title/TeX_Live#Installation) package on ArchLinux
- PlatformIO
- If you want to use PlatformIO, you need to have `pio` installed
- To create a project, run `:PIONewProject`
- To include a library, run `:PIOAddLibrary`
- For more commands, go to [`vim-pio`'s repository](https://github.com/jiriks74/vim-pio)
2022-10-02 06:56:31 +02:00
## Extra plugins included
- You have to create a file with `Launch` config - see the [plugin repository](https://github.com/puremourning/vimspector)
- [vim-pio](https://github.com/jiriks74/vim-pio)
- PlatformIO vim plugin
- This is a fork that I modified to work with clangd as this is what is the
easiest to setup in AstroNvim
- [vimtex](https://github.com/lervag/vimtex)
- A plugin for, you guessed it, LaTex
- I have not yet learned LaTex, so I haven't tried this plugin out.
- This plugin needs you to have LaTeX installed on your system. To see more go to the [vimtex repository](https://github.com/lervag/vimtex)
2022-10-02 06:56:31 +02:00
Hopefully I'll learn it and try out this plugin soon
2022-10-03 12:29:03 +02:00
- [markdown-preview.nvim](https://github.com/iamcco/markdown-preview.nvim)
2022-10-02 06:56:31 +02:00
- Plugin for live markdown preview in a web browser
- [copilot.vim](https://github.com/github/copilot.vim)
- Github's copilot plugin for Vim
- To use the plugin you have to login with this command
- `:Copilot setup`
2022-10-03 01:13:52 +02:00
- [Pocco81/auto-save.nvim](https://github.com/Pocco81/auto-save.nvim)
2022-10-03 01:09:37 +02:00
- Plugin for autosave
2022-10-02 06:56:31 +02:00
## Extra mappings
| Shortcut | Vim keybind | Description |
|----------|------------------|-------------------|
| Space+a | ["\<leader\>uD"] | Alpha Dashboard |
| CTRL+e | ["\<C-e\>"] | Copilot accept |
| CTRL+s | ["\<C-s\>"] | Toggle autosave |
2022-10-02 06:56:31 +02:00
### Mappings for markdown preview
2022-10-02 06:56:31 +02:00
| Shortcut | Vim keybind | Description |
|-----------|------------------|-------------------------|
| Space+m+p | ["\<leader\>mp"] | Markdown preview |
| Space+m+s | ["\<leader\>ms"] | Markdown preview stop |
| Space+m+t | ["\<leader\>mt"] | Markdown preview toggle |
### Mappings for `vimtex`
## TODO
2022-12-15 00:23:27 +01:00
- [ ] Nvim-DAP
- Modified the default AstroNvim config
- [ ] [Mappings for `vimtex`](#mappings-for-vimtex)
- [ ] Better section for `vim-pio`
- [ ] Add section for setting up debugging
- [ ] Add mappings for `treesitter` install?
- [ ] Add requirements section
- So you don't have to go through [Extra plugins included](#extra-plugins-included) to know what to install
- [ ] Better [`README.md`](https://github.com/jiriks74/astronvim_config/blob/neovim7.2/README.md)
for [`neovim7.2`](https://github.com/jiriks74/astronvim_config/tree/neovim7.2) branch
- [ ] Add section redirecting to [`neovim72`](https://github.com/jiriks74/astronvim_config/tree/neovim7.2)
2022-12-15 00:23:27 +01:00
branch's [`README.md`](https://github.com/jiriks74/astronvim_config/blob/neovim7.2/README.md) if user has Neovim < 8.0
- [ ] Setting up simple wiki?
- [ ] Add section for ["weirongxu/plantuml-previewer.vim"](https://github.com/weirongxu/plantuml-previewer.vim)