update some stuff idk
This commit is contained in:
parent
d7ab0ae8de
commit
ee50eb197a
4 changed files with 100 additions and 30 deletions
|
@ -1,7 +1,7 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
mkdir -p ${HOME}/screenshot
|
mkdir -p ${HOME}/screenshot
|
||||||
TARGET="${HOME}/screenshot/grab-$(date +'%Y%m%d%H%M%S').png"
|
TARGET="${HOME}/screenshot/grab-$(date +'%Y%m%d%H%M%S').png"
|
||||||
maim -s -n -p 1 -f png -m 10 -u | tee $TARGET | xclip -selection clipboard -t image/png
|
maim -s -n -o -p 1 -f png -m 10 -u | tee $TARGET | xclip -selection clipboard -t image/png
|
||||||
|
|
||||||
[ -s ${TARGET} ] || rm ${TARGET}
|
[ -s ${TARGET} ] || rm ${TARGET}
|
||||||
|
|
||||||
|
|
|
@ -18,8 +18,8 @@ let maplocalleader=" "
|
||||||
set autoread " automatically reload changed files
|
set autoread " automatically reload changed files
|
||||||
set wildmenu " handy auto complete menu
|
set wildmenu " handy auto complete menu
|
||||||
|
|
||||||
set list
|
"set list
|
||||||
set listchars=tab:·\ ,trail:▂,extends:»,precedes:«
|
"set listchars=tab:·\ ,trail:▂,extends:»,precedes:«
|
||||||
set infercase " completion recognizes capitalization
|
set infercase " completion recognizes capitalization
|
||||||
set smartcase
|
set smartcase
|
||||||
set ignorecase
|
set ignorecase
|
||||||
|
@ -52,7 +52,7 @@ Plug 'dylanaraps/wal.vim'
|
||||||
Plug 'cakebaker/scss-syntax.vim'
|
Plug 'cakebaker/scss-syntax.vim'
|
||||||
Plug 'calviken/vim-gdscript3'
|
Plug 'calviken/vim-gdscript3'
|
||||||
Plug 'ianks/vim-tsx'
|
Plug 'ianks/vim-tsx'
|
||||||
Plug 'leafgarland/typescript-vim'
|
Plug 'leafgarland/typescript-vim', {'for': 'typescript'}
|
||||||
Plug 'lepture/vim-jinja'
|
Plug 'lepture/vim-jinja'
|
||||||
Plug 'posva/vim-vue'
|
Plug 'posva/vim-vue'
|
||||||
|
|
||||||
|
@ -62,6 +62,7 @@ Plug 'tpope/vim-abolish'
|
||||||
Plug 'tpope/vim-surround'
|
Plug 'tpope/vim-surround'
|
||||||
Plug 'tpope/vim-dispatch'
|
Plug 'tpope/vim-dispatch'
|
||||||
Plug 'tpope/vim-vinegar'
|
Plug 'tpope/vim-vinegar'
|
||||||
|
Plug 'tpope/vim-sleuth'
|
||||||
Plug 'tpope/vim-commentary', "{{{
|
Plug 'tpope/vim-commentary', "{{{
|
||||||
nmap <leader>c <Plug>Commentary
|
nmap <leader>c <Plug>Commentary
|
||||||
xmap <leader>c <Plug>Commentary
|
xmap <leader>c <Plug>Commentary
|
||||||
|
@ -74,16 +75,16 @@ Plug 'tpope/vim-fugitive', "{{{
|
||||||
map \gs :Gstatus<CR>
|
map \gs :Gstatus<CR>
|
||||||
"}}}
|
"}}}
|
||||||
Plug 'carlitux/deoplete-ternjs', {'do': 'npm install -g tern'}
|
Plug 'carlitux/deoplete-ternjs', {'do': 'npm install -g tern'}
|
||||||
Plug 'w0rp/ale', "{{{
|
"Plug 'w0rp/ale', "{{{
|
||||||
let g:ale_linters = {
|
" let g:ale_linters = {
|
||||||
\ 'c': ['clang'],
|
" \ 'c': ['clang'],
|
||||||
\ 'cpp': ['clangx'],
|
" \ 'cpp': ['clangx'],
|
||||||
\ 'php': ['phpcs'],
|
" \ 'php': ['phpcs'],
|
||||||
\ 'javascript': ['eslint'],
|
" \ 'javascript': ['eslint'],
|
||||||
\}
|
" \}
|
||||||
let g:ale_python_pylint_options = '--load-plugins pylint_django'
|
" let g:ale_python_pylint_options = '--load-plugins pylint_django'
|
||||||
let g:ale_sign_error = '⬤'
|
" let g:ale_sign_error = '⬤'
|
||||||
"}}}
|
""}}}
|
||||||
Plug 'vim-airline/vim-airline-themes'
|
Plug 'vim-airline/vim-airline-themes'
|
||||||
Plug 'vim-airline/vim-airline', "{{{
|
Plug 'vim-airline/vim-airline', "{{{
|
||||||
let g:airline_symbols = {}
|
let g:airline_symbols = {}
|
||||||
|
@ -98,23 +99,74 @@ Plug 'mattn/gist-vim'
|
||||||
Plug 'easymotion/vim-easymotion', "{{{
|
Plug 'easymotion/vim-easymotion', "{{{
|
||||||
map <Leader><Leader> <Plug>(easymotion-prefix)
|
map <Leader><Leader> <Plug>(easymotion-prefix)
|
||||||
"}}}
|
"}}}
|
||||||
if has('nvim')
|
Plug 'mhartington/nvim-typescript', {'do': './install.sh'}
|
||||||
Plug 'Shougo/deoplete.nvim', {'do': ':UpdateRemotePlugins'}
|
|
||||||
else
|
" if has('nvim')
|
||||||
Plug 'Shougo/deoplete.nvim'
|
" Plug 'Shougo/deoplete.nvim', {'do': ':UpdateRemotePlugins'}
|
||||||
Plug 'roxma/nvim-yarp'
|
" else
|
||||||
Plug 'roxma/vim-hug-neovim-rpc'
|
" Plug 'Shougo/deoplete.nvim'
|
||||||
endif
|
" Plug 'roxma/nvim-yarp'
|
||||||
let g:deoplete#enable_at_startup = 1
|
" Plug 'roxma/vim-hug-neovim-rpc'
|
||||||
let g:deoplete#enable_smart_case = 1
|
" endif
|
||||||
let g:deoplete#sources#syntax#min_keyword_length = 2
|
" let g:deoplete#enable_at_startup = 1
|
||||||
Plug 'Shougo/neosnippet-snippets'
|
" let g:deoplete#enable_smart_case = 1
|
||||||
Plug 'Shougo/neosnippet.vim', "{{{
|
" let g:deoplete#sources#syntax#min_keyword_length = 2
|
||||||
let g:neosnippet#snippets_directory = '~/.vim/bundle/'.expand(fnamemodify($MYVIMRC, ':p:h').'/snippets/')
|
" Plug 'Shougo/denite.nvim'
|
||||||
let g:neosnippet#enable_snipmate_compatibility = 1
|
"Plug 'Shougo/neosnippet-snippets'
|
||||||
"}}}
|
"Plug 'Shougo/neosnippet.vim', "{{{
|
||||||
|
" let g:neosnippet#snippets_directory = '~/.vim/bundle/'.expand(fnamemodify($MYVIMRC, ':p:h').'/snippets/')
|
||||||
|
" let g:neosnippet#enable_snipmate_compatibility = 1
|
||||||
|
""}}}
|
||||||
Plug 'junegunn/fzf', {'dir': '~/.fzf', 'do': './install --all'}
|
Plug 'junegunn/fzf', {'dir': '~/.fzf', 'do': './install --all'}
|
||||||
Plug 'junegunn/fzf.vim', "{{{
|
Plug 'junegunn/fzf.vim', "{{{
|
||||||
|
function! s:buflist()
|
||||||
|
redir => ls
|
||||||
|
silent ls
|
||||||
|
redir END
|
||||||
|
return split(ls,'\n')
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
function! s:bufopen(e)
|
||||||
|
execute 'buffer' matchstr(a:e, '^[ 0-9]*')
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
nnoremap <silent> <Leader><Enter> :call fzf#run({
|
||||||
|
\ 'source': reverse(<sid>buflist()),
|
||||||
|
\ 'sink': function('<sid>bufopen'),
|
||||||
|
\ 'options': '+m',
|
||||||
|
\ 'down': len(<sid>buflist()) + 2
|
||||||
|
\})<CR>
|
||||||
|
|
||||||
|
|
||||||
|
function! s:FuzzyFiles()
|
||||||
|
let gitparent=system('git rev-parse --show-toplevel')[:-2]
|
||||||
|
let rootdir='.'
|
||||||
|
|
||||||
|
if empty(matchstr(gitparent, '^fatal:.*'))
|
||||||
|
silent call fzf#run({
|
||||||
|
\ 'dir': gitparent,
|
||||||
|
\ 'source': '(git ls-tree -r --name-only HEAD | rg --files)',
|
||||||
|
\ 'sink': 'e',
|
||||||
|
\})
|
||||||
|
else
|
||||||
|
silent call fzf#run({
|
||||||
|
\ 'dir': '.',
|
||||||
|
\ 'source': 'rg --files',
|
||||||
|
\ 'sink': 'e',
|
||||||
|
\})
|
||||||
|
endif
|
||||||
|
endfunction
|
||||||
|
|
||||||
|
command! -bang -nargs=* Rg
|
||||||
|
\ call fzf#vim#grep(
|
||||||
|
\ 'rg --column --line-number --no-heading --color=always '.shellescape(<q-args>), 1,
|
||||||
|
\ <bang>0 ? fzf#vim#with_preview('up:60%')
|
||||||
|
\ : fzf#vim#with_preview('right:50%:hidden', '?'),
|
||||||
|
\ <bang>0)
|
||||||
|
|
||||||
|
nnoremap <silent> ; :call <sid>FuzzyFiles()<CR>
|
||||||
|
nnoremap <leader>/ :Rg<CR>
|
||||||
|
|
||||||
"}}}
|
"}}}
|
||||||
call plug#end()
|
call plug#end()
|
||||||
|
|
||||||
|
@ -138,7 +190,7 @@ nnoremap zn ]s " next misspelling
|
||||||
nnoremap zp [s " prev misspelling
|
nnoremap zp [s " prev misspelling
|
||||||
nnoremap zf <Esc>1z= " replace misspelling with first suggestion
|
nnoremap zf <Esc>1z= " replace misspelling with first suggestion
|
||||||
nnoremap z! :set local spell!<CR> " toggle spellcheck
|
nnoremap z! :set local spell!<CR> " toggle spellcheck
|
||||||
nnoremap <leader>ve :e $MYVIMRC<CR> " quick open this file
|
nnoremap <leader>ve :e $MYVIMRC<CR> " quick open this (literally this) file
|
||||||
if executable('rg')
|
if executable('rg')
|
||||||
set grepprg='rg\ --vimgrep' " use ripgrep if available
|
set grepprg='rg\ --vimgrep' " use ripgrep if available
|
||||||
endif
|
endif
|
||||||
|
@ -166,6 +218,13 @@ function! NetrwMapping()
|
||||||
noremap <buffer> \e :bd<CR>
|
noremap <buffer> \e :bd<CR>
|
||||||
endfunction
|
endfunction
|
||||||
|
|
||||||
|
" close if final buffer is netrw or the quickfix
|
||||||
|
augroup finalcountdown
|
||||||
|
au!
|
||||||
|
autocmd WinEnter * if winnr('$') == 1 && getbufvar(winbufnr(winnr()), "&filetype") == "netrw" || &buftype == 'quickfix' |q|endif
|
||||||
|
nmap - :Lexplore<cr>
|
||||||
|
augroup END
|
||||||
|
|
||||||
" read .vimlocal if available
|
" read .vimlocal if available
|
||||||
if filereadable(expand('~/.vimlocal'))
|
if filereadable(expand('~/.vimlocal'))
|
||||||
source ~/.vimlocal
|
source ~/.vimlocal
|
||||||
|
|
1
xinitrc
1
xinitrc
|
@ -1,2 +1,3 @@
|
||||||
|
cd $
|
||||||
setxkbmap -option caps:swapescape &
|
setxkbmap -option caps:swapescape &
|
||||||
exec i3
|
exec i3
|
||||||
|
|
10
zshrc
10
zshrc
|
@ -32,3 +32,13 @@ done
|
||||||
[ -f ~/.fzf.zsh ] && source ~/.fzf.zsh
|
[ -f ~/.fzf.zsh ] && source ~/.fzf.zsh
|
||||||
[ -f ~/.zshrc.local ] && source ~/.zshrc.local
|
[ -f ~/.zshrc.local ] && source ~/.zshrc.local
|
||||||
[ -f ~/.aliases ] && source ~/.aliases
|
[ -f ~/.aliases ] && source ~/.aliases
|
||||||
|
|
||||||
|
# tabtab source for serverless package
|
||||||
|
# uninstall by removing these lines or running `tabtab uninstall serverless`
|
||||||
|
[[ -f /home/mark/code/ereloom.io/node_modules/tabtab/.completions/serverless.zsh ]] && . /home/mark/code/ereloom.io/node_modules/tabtab/.completions/serverless.zsh
|
||||||
|
# tabtab source for sls package
|
||||||
|
# uninstall by removing these lines or running `tabtab uninstall sls`
|
||||||
|
[[ -f /home/mark/code/ereloom.io/node_modules/tabtab/.completions/sls.zsh ]] && . /home/mark/code/ereloom.io/node_modules/tabtab/.completions/sls.zsh
|
||||||
|
# tabtab source for slss package
|
||||||
|
# uninstall by removing these lines or running `tabtab uninstall slss`
|
||||||
|
[[ -f /home/mark/code/ereloom.io/node_modules/tabtab/.completions/slss.zsh ]] && . /home/mark/code/ereloom.io/node_modules/tabtab/.completions/slss.zsh
|
Loading…
Add table
Add a link
Reference in a new issue