Skip to content

Instantly share code, notes, and snippets.

@shakna-israel
Last active March 21, 2018 07:12
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save shakna-israel/6f55cdffefc43eb4bd10a633bc1dc87a to your computer and use it in GitHub Desktop.
Save shakna-israel/6f55cdffefc43eb4bd10a633bc1dc87a to your computer and use it in GitHub Desktop.
A simple vim
set nocompatible " must be the first line
filetype on
filetype indent on
filetype plugin on
set nowrap
set laststatus=2
set statusline=%<%f\%h%m%r%=%-20.(line=%l\ \ col=%c%V\ \ totlin=%L%)\ \ \%h%m%r%=%-40(bytval=0x%B,%n%Y%)\%P
set ofu=syntaxcomplete#Complete
" Above is SSH compatibility fixes
" Use arrows to traverse line endings
set whichwrap+=<,>,[,]
" Start in Insert Mode
au BufRead,BufNewFile * start
" Map CTRL+S to save
nnoremap <c-s> :w<cr>
inoremap <c-s> <Esc>:w<cr>I
" Map CTRL+Q to save and quit
nnoremap <c-q> :wq<cr>
inoremap <c-q> <Esc>:wq<cr>
" Autoreload after 4s inactivity.
set autoread
au CursorHold,CursorHoldI * checktime
" Show line numbers
set number
" Make backspace always work in Insert mode
set backspace=indent,eol,start
@shakna-israel
Copy link
Author

Nano is currently unuseable across ssh on TinyCoreLinux. Some issues with readline.

However, with a few tweaks, vim can fit, and be fairly nice.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment