From f893dc559d8b17075d8ae64c427cf565a23c01a0 Mon Sep 17 00:00:00 2001 From: PlexSheep Date: Fri, 10 Feb 2023 09:51:10 +0100 Subject: [PATCH] nvim autoclose with pure vimscript + TODOs --- README.md | 6 ++++++ home/.config/nvim/init.vim | 9 +++++++++ home/.config/nvim/noplug.vim | 9 +++++++++ home/.vimrc | 10 +++++++++- 4 files changed, 33 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 8850f26..6513df1 100644 --- a/README.md +++ b/README.md @@ -13,3 +13,9 @@ target user, some stuff will need to run as root. - curl - lsd (workstations) - nodejs (nvim language server) + +# TODO +[ ] list nvim plugins and auto install +[ ] add options for help, only local installs, complete installs and so on +[ ] add vim shortcut to resize splits +[ ] take a look at autoclosing plugins for nvim diff --git a/home/.config/nvim/init.vim b/home/.config/nvim/init.vim index 5704b9c..568d8d7 100644 --- a/home/.config/nvim/init.vim +++ b/home/.config/nvim/init.vim @@ -59,6 +59,15 @@ nnoremap yy "+yy " open terminal with F12 nnoremap :terminal +" automatically set closed braces aswell when making opened ones. +" inoremap " "" +inoremap ' '' +inoremap ( () +inoremap [ [] +inoremap { {} +inoremap { {}O +inoremap {; {};O + " vsplit with , then " map " :vsplit diff --git a/home/.config/nvim/noplug.vim b/home/.config/nvim/noplug.vim index 8859a8c..96b03f9 100644 --- a/home/.config/nvim/noplug.vim +++ b/home/.config/nvim/noplug.vim @@ -59,6 +59,15 @@ nnoremap yy "+yy " open terminal with F12 nnoremap :terminal +" automatically set closed braces aswell when making opened ones. +" inoremap " "" +inoremap ' '' +inoremap ( () +inoremap [ [] +inoremap { {} +inoremap { {}O +inoremap {; {};O + " vsplit with , then " map " :vsplit diff --git a/home/.vimrc b/home/.vimrc index 39a8df1..6342b16 100644 --- a/home/.vimrc +++ b/home/.vimrc @@ -24,7 +24,6 @@ set timeout timeoutlen=400 " Avoid showing message extra message when using completion" set shortmess+=c - " set timeout to wait for shortcuts with a prefix noremap oo o noremap OO O @@ -52,6 +51,15 @@ nnoremap yy "+yy " open terminal with F12 nnoremap :terminal +" automatically set closed braces aswell when making opened ones. +" inoremap " "" +inoremap ' '' +inoremap ( () +inoremap [ [] +inoremap { {} +inoremap { {}O +inoremap {; {};O + " vsplit with , then " map " :vsplit