Skip to content

Instantly share code, notes, and snippets.

@lironsade
Created April 10, 2020 11:58
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 lironsade/9f05003bb3bb89b890570e41a6d3cf93 to your computer and use it in GitHub Desktop.
Save lironsade/9f05003bb3bb89b890570e41a6d3cf93 to your computer and use it in GitHub Desktop.
"enter current millenium
set nocompatible
syntax on
filetype plugin indent on
" show existing tab with 4 spaces width
set tabstop=4
" when indenting with '>', use 4 spaces width
set shiftwidth=4
" On pressing tab, insert 4 spaces
set expandtab
"plugins
set rtp+=~/.vim/bundle/Vundle.vim
call vundle#begin()
" let Vundle manage Vundle, required
Plugin 'VundleVim/Vundle.vim'
Plugin 'vim-scripts/xoria256.vim'
Plugin 'rakr/vim-one'
Plugin 'joshdick/onedark.vim'
"Plugin 'davidhalter/jedi-vim'
"Plugin 'python-mode/python-mode'
"Plugin 'w0rp/ale'
"Plugin 'sevko/vim-nand2tetris-syntax'
Bundle 'mattn/webapi-vim'
Bundle 'mattn/gist-vim'
" All of your Plugins must be added before the following line
call vundle#end() " required
filetype plugin indent on " required
"colorscheme xoria256
"colorscheme one-dark
colorscheme onedark
set t_ut=
if &term == "screen"
set t_Co=256
endif
set number " show line numbers
"some sort of fuzzy finder
set path+=**
"Display all matching files when we tab complete
set wildmenu
" Rebind <Leader> key
let mapleader = ","
" Disable stupid backup and swap files - they trigger too many events
set nobackup
set nowritebackup
set noswapfile
"more natural split
set splitbelow
set splitright
"easier split navigation
nnoremap <C-J> <C-W><C-J>
nnoremap <C-K> <C-W><C-K>
nnoremap <C-L> <C-W><C-L>
nnoremap <C-H> <C-W><C-H>
"for gists
let g:gist_clip_command = 'xclip -selection clipboard'
let g:gist_detect_filetype = 1
"no folds
set nofoldenable
" nand2tetris JACK
autocmd BufNewFile,BufRead *.jack set syntax=jack
"""""""""""""""""""""""""""""""""""
""""""" PYTHON RELATED """"""""""""
"""""""""""""""""""""""""""""""""""
" python mode config to syntax python3 instead of python2
let g:pymode_python = 'python3'
" run python
autocmd FileType python nnoremap <F12> :!python3 %<cr>
"
""Use 24-bit (true-color) mode in Vim/Neovim when outside tmux.
"If you're using tmux version 2.2 or later, you can remove the outermost $TMUX check and use tmux's 24-bit color support
"(see < http://sunaku.github.io/tmux-24bit-color.html#usage > for more information.)
if (empty($TMUX))
if (has("nvim"))
"For Neovim 0.1.3 and 0.1.4 < https://github.com/neovim/neovim/pull/2198 >
let $NVIM_TUI_ENABLE_TRUE_COLOR=1
endif
"For Neovim > 0.1.5 and Vim > patch 7.4.1799 < https://github.com/vim/vim/commit/61be73bb0f965a895bfb064ea3e55476ac175162 >
"Based on Vim patch 7.4.1770 (`guicolors` option) < https://github.com/vim/vim/commit/8a633e3427b47286869aa4b96f2bfc1fe65b25cd >
" < https://github.com/neovim/neovim/wiki/Following-HEAD#20160511 >
if (has("termguicolors"))
set termguicolors
endif
endif
" autload ~/.vimrc
augroup myvimrc
au!
au BufWritePost .vimrc,_vimrc,vimrc,.gvimrc,_gvimrc,gvimrc so $MYVIMRC | if has('gui_running') | so $MYGVIMRC | endif
augroup END
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment