Update nvim config to behave like a text editor

This commit is contained in:
Antoine Phan
2024-01-21 14:07:32 -05:00
parent 8565515455
commit 159066c9f1
2 changed files with 27 additions and 0 deletions

View File

@@ -5,6 +5,24 @@ set shiftwidth=2
set expandtab set expandtab
set noshowmode set noshowmode
" Normal mode remap
nnoremap <Up> gk
nnoremap <Down> gj
" Visual mode remap
xnoremap <Up> gk
xnoremap <Down> gj
" Insert mode remap
" https://vimdoc.sourceforge.net/htmldoc/insert.html#Insert
" Using CTRL-O for temporary move to Normal mode
inoremap <Up> <C-\><C-O>gk
inoremap <Down> <C-\><C-O>gj
inoremap <C-BS> <C-W>
" Line Break
set linebreak
call plug#begin() call plug#begin()
Plug 'tpope/vim-sensible' Plug 'tpope/vim-sensible'
Plug 'ap/vim-css-color' Plug 'ap/vim-css-color'

View File

@@ -0,0 +1,9 @@
#!/bin/bash
CONFIG=$HOME/.config
echo "instruction: ./update.sh <config_folder_name>"
config=$1
cp -r $CONFIG/$config/* ./.config/$config/
echo "Copied $CONFIG/$config to .config folder"