diff --git a/bin/extract b/bin/extract new file mode 100755 index 0000000..fe46b67 --- /dev/null +++ b/bin/extract @@ -0,0 +1,18 @@ +#!/bin/sh +case "$1" in + *.tar.bz2) tar xjf $1 ;; + *.tar.gz) tar xzf $1 ;; + *.bz2) bunzip2 $1 ;; + *.rar) unrar x $1 ;; + *.gz) gunzip $1 ;; + *.tar) tar xf $1 ;; + *.tbz2) tar xjf $1 ;; + *.tgz) tar xzf $1 ;; + *.zip) unzip $1 ;; + *.Z) uncompress $1 ;; + *.7z) 7z x $1 ;; + *.deb) ar x $1 ;; + *.tar.xz) tar xf $1 ;; + *.tar.zst) unzstd $1 ;; + *) echo "'$1' is not a valid file" ;; +esac diff --git a/config/nvim/init.vim b/config/nvim/init.vim index 43d1d7a..61ac581 100644 --- a/config/nvim/init.vim +++ b/config/nvim/init.vim @@ -1,7 +1,8 @@ -call plug#begin('~/.vim/plugged') +call plug#begin("~/.vim/plugged") Plug 'Smirnov-O/nten16.vim' Plug 'sheerun/vim-polyglot' Plug 'jiangmiao/auto-pairs' + Plug 'scrooloose/nerdtree' call plug#end() "== General @@ -24,8 +25,7 @@ set expandtab set autoindent " Status line -set laststatus=0 -set ruler +set ruler laststatus=0 " Maximux item in popup set pumheight=9 @@ -82,15 +82,21 @@ command! Black :silent !black % command! AutoPep8 :silent !autopep8 % --in-place command! GoFmt :silent !gofmt -w % +"== NERDTree +let g:NERDTreeWinPos = "right" +let g:NERDTreeMinimalUI = 1 "== Mapping let mapleader=";" inoremap ii +" NerdTree +nnoremap e :NERDTreeToggle + " Alternative keys nnoremap :w nnoremap :tabnew -nnoremap :nohl +nnoremap :noh " Window nnoremap :wincmd h @@ -107,20 +113,20 @@ nnoremap spk :wincmd L " Tab nnoremap tn :tabnew nnoremap tc :tabclose -nnoremap :tabn 1 -nnoremap :tabn 2 -nnoremap :tabn 3 -nnoremap :tabn 4 -nnoremap :tabn 5 -nnoremap :tabn 6 -nnoremap :tabn 7 -nnoremap :tabn 8 -nnoremap :tabn 9 +noremap :tabn 1 +noremap :tabn 2 +noremap :tabn 3 +noremap :tabn 4 +noremap :tabn 5 +noremap :tabn 6 +noremap :tabn 7 +noremap :tabn 8 +noremap :tabn 9 " Buffer nnoremap j :bnext nnoremap k :bprev -nnoremap h :bdele +nnoremap c :bdele " Work with system clipboard noremap c "*yy diff --git a/vscode/settings.json b/vscode/settings.json index 1805bcf..5e77ec4 100644 --- a/vscode/settings.json +++ b/vscode/settings.json @@ -28,6 +28,8 @@ "vim.useSystemClipboard": true, "vim.normalModeKeyBindings": [{"before": ["f"], "after" : ["leader","leader","s"]}], + "cSpell.userWords": ["getenv"], + "emmet.includeLanguages": { "javascript": "javascriptreact" },