Merge branch 'master' of github.com:andrejusk/dotfiles

This commit is contained in:
Andrejus
2020-11-09 18:27:02 +00:00
14 changed files with 441 additions and 250 deletions

View File

@@ -1,4 +1,4 @@
from ubuntu:bionic as install FROM ubuntu:bionic as install
# Install sudo and make, git since built-in is skipped # Install sudo and make, git since built-in is skipped
RUN echo 'debconf debconf/frontend select Noninteractive' | debconf-set-selections RUN echo 'debconf debconf/frontend select Noninteractive' | debconf-set-selections

View File

@@ -2,8 +2,8 @@
Collection of experimental dotfiles and supporting install scripts. Collection of experimental dotfiles and supporting install scripts.
Tested on and compatible with: Tested on and compatible with:
* Ubuntu 18.04
* Ubuntu 20.04 - Ubuntu 20.04
## Install ## Install
@@ -13,17 +13,19 @@ Tested on and compatible with:
Shell: 🐟 fish (+ fisher) Shell: 🐟 fish (+ fisher)
Editor: nvim (+ vim-plug) Editor: neovim (+ vim-plug)
Tools: Tools:
* aws
* docker (+ docker-compose) - aws, gcloud, firebase
* firebase - docker (+ docker-compose)
* terraform - kubectl
* screenfetch - terraform
- screenfetch
Languages: Languages:
* java
* js (nvm, node yarn, nvm) - java
* python (+ poetry, pyenv) - js (nvm, node, yarn)
* ruby - python (pyenv, poetry)
- ruby

View File

@@ -1,12 +1,12 @@
# ---------------------------------------------------------------------------- # if status --is-interactive
# Cross-shell (only import if environment has been setup) # Cross-shell setup
# ---------------------------------------------------------------------------- # if begin; test -e ~/.bash_profile; and type -q bax; end
if begin; test -e ~/.bash_profile; and type -q bass; end bax "source ~/.bash_profile"
bass source ~/.bash_profile
end end
# ---------------------------------------------------------------------------- #
# Fish specific # Fish specific
# ---------------------------------------------------------------------------- #
set fish_greeting set fish_greeting
if type -q base16-seti
base16-seti base16-seti
end
end

View File

@@ -1,5 +1,8 @@
fishpkg/fish-prompt-mono fishpkg/fish-prompt-mono
acomagu/fish-async-prompt
matchai/fish-mock
edc/bass
tomyun/base16-fish tomyun/base16-fish
gazorby/fish-abbreviation-tips
oh-my-fish/plugin-license
matchai/fish-mock
jorgebucaran/fish-bax
jethrokuan/z
joseluisq/gitnow

View File

@@ -1,23 +1,31 @@
" ============================================================================ " " ============================================================================ "
" === EDITING OPTIONS === " " === EDITING OPTIONS === "
" ============================================================================ " " ============================================================================ "
"
" Leader key <SPACE>
let g:mapleader=' '
" Use posix-compliant shell
set shell=sh
" Enable syntax highlighting
syntax enable
filetype on
filetype plugin on
" Hides buffers instead of closing them
set hidden
" do not wrap long lines by default
set nowrap
" default encoding " default encoding
set encoding=utf-8 set encoding=utf-8
set fileencoding=utf-8 set fileencoding=utf-8
set fileformat=unix set fileformat=unix
filetype on
filetype plugin on
syntax on
" Leader key <SPACE>
let g:mapleader=' '
" Yank and paste with the system clipboard " Yank and paste with the system clipboard
set clipboard= set clipboard=unnamedplus
" Hides buffers instead of closing them
set hidden
" et = expandtab (spaces instead of tabs) " et = expandtab (spaces instead of tabs)
" ts = tabstop (the number of spaces that a tab equates to) " ts = tabstop (the number of spaces that a tab equates to)
@@ -25,25 +33,36 @@ set hidden
" -- or de-indenting -- a line) " -- or de-indenting -- a line)
" sts = softtabstop (the number of spaces to use when expanding tabs) " sts = softtabstop (the number of spaces to use when expanding tabs)
set et sts=4 sw=4 ts=4 set et sts=4 sw=4 ts=4
set showtabline=4
set foldenable set foldenable
set foldmethod=indent set foldmethod=indent
set foldlevel=99 set foldlevel=99
set conceallevel=1 set conceallevel=0
set number set scrolloff=10
set relativenumber
" do not wrap long lines by default
set nowrap
" two lines for command line
set cmdheight=2
" Having longer updatetime (default is 4000 ms = 4 s) leads to noticeable " Having longer updatetime (default is 4000 ms = 4 s) leads to noticeable
" delays and poor user experience. " delays and poor user experience.
set updatetime=300 set updatetime=100
set timeoutlen=300
" Don't pass messages to |ins-completion-menu|.
set shortmess=atT
" Always show the signcolumn, otherwise it would shift the text each time
" diagnostics appear/become resolved.
if has("patch-8.1.1564")
" Recently vim can merge signcolumn and number column into one
set signcolumn=number
else
set signcolumn=yes
endif
" coc.nvim recommendations
set nobackup
set nowritebackup
" Don't pass messages to |ins-completion-menu|. " Don't pass messages to |ins-completion-menu|.
set shortmess+=c set shortmess+=c
@@ -61,8 +80,14 @@ endif
" === UI === " " === UI === "
" ============================================================================ " " ============================================================================ "
" Support italics
hi Comment cterm=italic
" Enable true color support " Enable true color support
if (has("termguicolors"))
set termguicolors set termguicolors
hi LineNr ctermbg=NONE guibg=NONE
endif
" Set preview window to appear at bottom and right " Set preview window to appear at bottom and right
set splitbelow set splitbelow
@@ -74,33 +99,25 @@ set noshowmode
" Set floating window to be slightly transparent " Set floating window to be slightly transparent
set winbl=10 set winbl=10
" ============================================================================ " " Enable ruler
" === MISC. === " set ruler
" ============================================================================ " set number
set relativenumber
" Automaticaly close nvim if NERDTree is only thing left open " Pop-up menu
autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isTabTree()) | q | endif set pumheight=10
" === Search === " " two lines for command line
" ignore case when searching set cmdheight=2
set ignorecase
" no visual bell
set visualbell t_vb=
" if the search string has an upper case letter in it, the search will be case sensitive " if the search string has an upper case letter in it, the search will be case sensitive
set smartcase set smartcase
" Enable spellcheck for markdown files " Redraw on resize
autocmd BufRead,BufNewFile *.md setlocal spell autocmd VimResized * redraw!
" Set backups " Redraw on writing buffer
if has('persistent_undo') autocmd BufWritePost * redraw!
set undofile
set undolevels=3000
set undoreload=10000
endif
set backupdir=$XDG_DATA_HOME/nvim/backup " Don't put backups in current dir
set backup
set noswapfile
" Some servers have issues with backup files, see #649.
" set nobackup
" set nowritebackup

View File

@@ -1,8 +1,35 @@
{ {
"coc.preferences.formatOnSaveFiletypes": [
"css",
"dockerfile",
"html",
"javascript",
"javascriptreact",
"json",
"make",
"markdown",
"perl",
"python",
"sh",
"svg",
"toml",
"typescript",
"typescriptreact",
"vim",
"xml",
"yaml"
],
"coc.preferences.extensionUpdateCheck": "daily",
"list.source.files.args": ["--hidden", "--files"],
"suggest.echodocSupport": true, "suggest.echodocSupport": true,
"python.pythonPath": "python3",
"python.jediEnabled": false, "python.jediEnabled": false,
"python.linting.pylintEnabled": false,
"python.linting.flake8Enabled": true, "python.linting.flake8Enabled": true,
"python.linting.pylintEnabled": false,
"languageserver": { "languageserver": {
"terraform": { "terraform": {
"command": "terraform-ls", "command": "terraform-ls",
@@ -11,5 +38,76 @@
"initializationOptions": {}, "initializationOptions": {},
"settings": {} "settings": {}
} }
},
"explorer.width": 30,
"explorer.file.root.template": "[icon] [git] [hidden & 1][root]",
"explorer.icon.enableNerdfont": true,
"explorer.previewAction.onHover": false,
"explorer.icon.enableVimDevicons": false,
"explorer.file.showHiddenFiles": true,
"explorer.file.autoReveal": true,
"explorer.keyMappings.global": {
"i": false,
"gk": "expandablePrev",
"gj": "expandableNext",
"*": "toggleSelection",
"<tab>": "actionMenu",
"h": "collapse",
"l": ["expandable?", "expand", "open"],
"J": ["toggleSelection", "nodeNext"],
"K": ["toggleSelection", "nodePrev"],
"gl": "expandRecursive",
"gh": "collapseRecursive",
"o": ["expanded?", "collapse", "expand"],
"<cr>": ["expandable?", "cd", "open"],
"e": "open",
"s": "open:split",
"v": "open:vsplit",
"t": "open:tab",
"<bs>": "gotoParent",
"gp": "preview:labeling",
"y": "copyFilepath",
"Y": "copyFilename",
"c": "copyFile",
"x": "cutFile",
"p": "pasteFile",
"d": "delete",
"D": "deleteForever",
"a": "addFile",
"A": "addDirectory",
"r": "rename",
".": "toggleHidden",
"R": "refresh",
"?": "help",
"q": "quit",
"<esc>": "esc",
"X": "systemExecute",
"gd": "listDrive",
"f": "search",
"F": "searchRecursive",
"gf": "gotoSource:file",
"gb": "gotoSource:buffer",
"[[": "sourcePrev",
"]]": "sourceNext",
"[d": "diagnosticPrev",
"]d": "diagnosticNext",
"[c": "gitPrev",
"]c": "gitNext",
"<<": "gitStage",
">>": "gitUnstage"
} }
} }

View File

@@ -1,4 +1,4 @@
" No arrow keys " Disable arrow keys
noremap <Up> <NOP> noremap <Up> <NOP>
noremap <Down> <NOP> noremap <Down> <NOP>
noremap <Left> <NOP> noremap <Left> <NOP>
@@ -9,6 +9,25 @@ inoremap <Left> <NOP>
inoremap <Right> <NOP> inoremap <Right> <NOP>
" Disable manual and ex mode
nnoremap <F1> <nop>
nnoremap Q <nop>
" Quick escape
inoremap jk <Esc>
inoremap kj <Esc>
" Quick save
nnoremap <C-s> :w<CR>
" Better tabbing
vnoremap < <gv
vnoremap > >gv
" Quick window switching " Quick window switching
" Ctrl-[hjkl] " Ctrl-[hjkl]
nnoremap <silent> <C-h> <C-w>h nnoremap <silent> <C-h> <C-w>h
@@ -17,6 +36,20 @@ nnoremap <silent> <C-k> <C-w>k
nnoremap <silent> <C-l> <C-w>l nnoremap <silent> <C-l> <C-w>l
" Quick window resizing
" Alt-[hjkl]
nnoremap <silent> <M-j> :resize -2<CR>
nnoremap <silent> <M-k> :resize +2<CR>
nnoremap <silent> <M-h> :vertical resize -2<CR>
nnoremap <silent> <M-l> :vertical resize +2<CR>
" Quicker omni complete nav
" Ctrl-[jk]
inoremap <expr> <c-j> ("\<C-n>")
inoremap <expr> <c-k> ("\<C-p>")
" Distraction free typing " Distraction free typing
" <l>l - Toggle Goyo and Limelight " <l>l - Toggle Goyo and Limelight
nnoremap <silent> <leader>l :Goyo<cr> nnoremap <silent> <leader>l :Goyo<cr>
@@ -39,11 +72,11 @@ nnoremap <silent> <leader>f :Rg<cr>
nnoremap <silent> <leader>; :Buffers<cr> nnoremap <silent> <leader>; :Buffers<cr>
" NERDTree " coc.nvim explorer
" <l>e - Toggle NERDTree on/off " <l>e - Toggle explorer on/off
" <l>E - Open current file location in NERDTree " <l>E - Open current file location
nnoremap <silent> <leader>e :NERDTreeToggle<cr> nmap <silent> <leader>e :CocCommand explorer<cr>
nnoremap <silent> <leader>E :NERDTreeFind<cr> nmap <silent> <leader>E :CocCommand explorer --reveal expand('<sfile>')<cr>
" coc.nvim " coc.nvim
@@ -54,15 +87,16 @@ nnoremap <silent> <leader>E :NERDTreeFind<cr>
" <l>j - Jump to implementation of current symbol " <l>j - Jump to implementation of current symbol
" <l>s - Fuzzy search current project symbols " <l>s - Fuzzy search current project symbols
" <l>n - Symbol renaming " <l>n - Symbol renaming
" <l>y - Format selected code " <l>k - Symbol renaming
nnoremap <silent> <C-n> <Plug>(coc-diagnostic-prev) nmap <silent> <C-n> <Plug>(coc-diagnostic-prev)
nnoremap <silent> <C-p> <Plug>(coc-diagnostic-next) nmap <silent> <C-p> <Plug>(coc-diagnostic-next)
nnoremap <silent> <leader>d <Plug>(coc-definition) " broken d
nnoremap <silent> <leader>r <Plug>(coc-references) nmap <silent> <leader>d <Plug>(coc-definition)
nnoremap <silent> <leader>j <Plug>(coc-implementation) nmap <silent> <leader>r <Plug>(coc-references)
nnoremap <silent> <leader>s :<C-u>CocList -I -N --top symbols<cr> " broken j
nnoremap <silent> <leader>n <Plug>(coc-rename) nmap <silent> <leader>j <Plug>(coc-implementation)
nnoremap <silent> <leader>y <Plug>(coc-format-selected) nmap <silent> <leader>s :<C-u>CocList -I -N --top symbols<cr>
nmap <silent> <leader>n <Plug>(coc-rename)
" Search shorcuts " Search shorcuts
@@ -72,14 +106,6 @@ nnoremap <leader>h :%s///<left><left>
nnoremap <silent> <leader>/ :nohlsearch<cr> nnoremap <silent> <leader>/ :nohlsearch<cr>
" Easy-motion shortcut
" <l>w - move to word bi-directionally
" <l>W{char} - move to {char}
nnoremap <silent> <leader>w <Plug>(easymotion-bd-w)
nnoremap <silent> <leader>W <Plug>(easymotion-bd-f)
" use <tab> for trigger completion and navigate to next complete item " use <tab> for trigger completion and navigate to next complete item
inoremap <silent><expr> <TAB> inoremap <silent><expr> <TAB>
\ pumvisible() ? "\<C-n>" : \ pumvisible() ? "\<C-n>" :
@@ -122,5 +148,3 @@ augroup mygroup
" Update signature help on jump placeholder. " Update signature help on jump placeholder.
autocmd User CocJumpPlaceholder call CocActionAsync('showSignatureHelp') autocmd User CocJumpPlaceholder call CocActionAsync('showSignatureHelp')
augroup end augroup end

View File

@@ -2,28 +2,21 @@
set background=dark set background=dark
colorscheme base16-seti colorscheme base16-seti
" Coc.nvim
" Close preview window when completion is done. " Close preview window when completion is done.
autocmd! CompleteDone * if pumvisible() == 0 | pclose | endif autocmd! CompleteDone * if pumvisible() == 0 | pclose | endif
" Disable deprecated python2 provider " Disable deprecated python2 provider
let g:loaded_python_provider = 0 let g:loaded_python_provider = 0
" Call method on window enter " " Call method on window enter
augroup WindowManagement " augroup WindowManagement
autocmd! " autocmd!
autocmd WinEnter * call Handle_Win_Enter() " autocmd WinEnter * call Handle_Win_Enter()
augroup END " augroup END
" Change highlight group of preview window when open " " Change highlight group of preview window when open
function! Handle_Win_Enter() " function! Handle_Win_Enter()
if &previewwindow " if &previewwindow
setlocal winhighlight=Normal:MarkdownError " setlocal winhighlight=Normal:MarkdownError
endif " endif
endfunction " endfunction
" Reload icons after init source
if exists('g:loaded_webdevicons')
call webdevicons#refresh()
endif

View File

@@ -9,74 +9,53 @@ Plug 'chriskempson/base16-vim'
" dev icons " dev icons
Plug 'ryanoasis/vim-devicons' Plug 'ryanoasis/vim-devicons'
" {{{ " {{{
let g:webdevicons_enable_nerdtree = 1
let g:webdevicons_conceal_nerdtree_brackets = 1
let g:webdevicons_enable_airline_tabline = 1 let g:webdevicons_enable_airline_tabline = 1
let g:webdevicons_enable_airline_statusline = 1 let g:webdevicons_enable_airline_statusline = 1
let g:webdevicons_enable_startify = 1 let g:webdevicons_enable_startify = 1
" }}} " }}}
" explorer sidebar
Plug 'scrooloose/nerdtree'
Plug 'tiagofumo/vim-nerdtree-syntax-highlight'
" {{{
" Show hidden files/directories
let g:NERDTreeShowHidden = 1
" Remove bookmarks and help text from NERDTree
let g:NERDTreeMinimalUI = 1
let g:NERDTreeMinimalMenu = 1
" Remove icons for expandable/expanded directories
let g:NERDTreeDirArrowExpandable = ''
let g:NERDTreeDirArrowCollapsible = ''
" Hide certain files and directories from NERDTree
let g:NERDTreeIgnore = ['\.git$[[dir]]']
" }}}
" status line " status line
Plug 'vim-airline/vim-airline' Plug 'vim-airline/vim-airline'
Plug 'vim-airline/vim-airline-themes'
" {{{ " {{{
" Theme
let g:airline_theme = 'base16_seti'
" Enable extensions " Enable extensions
let g:airline_extensions = ['branch', 'coc', 'hunks'] let g:airline_extensions = ['branch', 'coc', 'hunks']
" Do not draw separators for empty sections (only for the active window) > " Do not draw separators for empty sections (only for the active window) >
let g:airline_skip_empty_sections = 1 let g:airline_skip_empty_sections = 1
" Smartly uniquify buffers names with similar filename, suppressing common parts of paths.
let g:airline#extensions#tabline#formatter = 'unique_tail_improved'
" Custom setup that removes filetype/whitespace from default vim airline bar " Custom setup that removes filetype/whitespace from default vim airline bar
" let g:airline#extensions#default#layout = [['a', 'b', 'c'], ['x', 'z', 'warning', 'error']] let g:airline#extensions#default#layout = [['a', 'b', 'c'], ['x', 'z', 'warning', 'error']]
" Customize vim airline per filetype " Customize vim airline per filetype
" 'nerdtree' - Hide nerdtree status line
" 'list' - Only show file type plus current line number out of total " 'list' - Only show file type plus current line number out of total
let g:airline_filetype_overrides = { let g:airline_filetype_overrides = {
\ 'coc-explorer': [ 'CoC Explorer', '' ], \ 'coc-explorer': [ ' Explore', '' ],
\ 'fugitive': ['fugitive', '%{airline#util#wrap(airline#extensions#branch#get_head(),80)}'], \ 'fugitive': ['fugitive', '%{airline#util#wrap(airline#extensions#branch#get_head(),80)}'],
\ 'help': [ 'Help', '%f' ], \ 'help': [ 'Help', '%f' ],
\ 'startify': [ 'startify', '' ], \ 'startify': [ 'startify', '' ],
\ 'vim-plug': [ 'Plugins', '' ], \ 'vim-plug': [ 'Plugins', '' ],
\ 'nerdtree': [ get(g:, 'NERDTreeStatusline', ''), '' ],
\ 'list': [ '%y', '%l/%L'], \ 'list': [ '%y', '%l/%L'],
\ } \ }
" Enable powerline fonts " Enable powerline fonts
let g:airline_powerline_fonts = 1 let g:airline_powerline_fonts = 1
let g:airline_left_sep = ''
let g:airline_right_sep = ''
let g:airline_right_alt_sep = ''
" Enable caching of syntax highlighting groups " Enable caching of syntax highlighting groups
let g:airline_highlighting_cache = 1 let g:airline_highlighting_cache = 1
" }}}
" Print function signatures in echo area " Enable tabline
Plug 'Shougo/echodoc.vim' let g:airline#extensions#tabline#enabled = 1
" {{{ let g:airline#extensions#tabline#left_sep = ' '
" Enable echodoc on startup let g:airline#extensions#tabline#left_alt_sep = '|'
let g:echodoc#enable_at_startup = 1 let g:airline#extensions#tabline#formatter = 'unique_tail_improved'
" }}} " }}}
" start screen " start screen
@@ -90,20 +69,46 @@ Plug 'junegunn/limelight.vim'
Plug 'kkoomen/vim-doge' Plug 'kkoomen/vim-doge'
" auto-close plugins " auto-close plugins
Plug 'rstacruz/vim-closer'
Plug 'tpope/vim-endwise' Plug 'tpope/vim-endwise'
" better motion " easier commentary
Plug 'easymotion/vim-easymotion'
Plug 'tpope/vim-surround'
Plug 'svermeulen/vim-subversive'
Plug 'godlygeek/tabular'
Plug 'tpope/vim-commentary' Plug 'tpope/vim-commentary'
" easier alignment
Plug 'godlygeek/tabular'
" extra visual feedback
Plug 'junegunn/rainbow_parentheses.vim'
" {{{
let g:rainbow_active = 1
let g:rainbow#pairs = [['(', ')'], ['[', ']'], ['{', '}']]
let g:rainbow_conf = {'guis': ['bold']}
" }}}
Plug 'unblevable/quick-scope'
" better motion
Plug 'tpope/vim-surround'
Plug 'justinmk/vim-sneak'
" {{{
let g:sneak#label = 1
let g:sneak#prompt = ' '
" case insensitive
let g:sneak#use_ic_scs = 1
" move to next search if cursor hasn't moved
let g:sneak#s_next = 1
" }}}
" git tools " git tools
Plug 'mhinz/vim-signify' Plug 'mhinz/vim-signify'
" {{{ " {{{
let g:signify_sign_add = '+'
let g:signify_sign_delete = '-' let g:signify_sign_delete = '-'
let g:signify_sign_change = '~'
let g:signify_sign_show_count = 0
let g:signify_sign_show_text = 1
" }}} " }}}
Plug 'tpope/vim-fugitive' Plug 'tpope/vim-fugitive'
@@ -111,44 +116,49 @@ Plug 'tpope/vim-fugitive'
Plug 'junegunn/fzf', { 'do': { -> fzf#install() } } Plug 'junegunn/fzf', { 'do': { -> fzf#install() } }
Plug 'junegunn/fzf.vim' Plug 'junegunn/fzf.vim'
" {{{ " {{{
let g:fzf_layout = { 'window': { 'width': 0.9, 'height': 0.9 } } let g:fzf_layout = { 'window': { 'width': 0.9, 'height': 0.6 } }
let g:fzf_preview_window = ['right:66%', 'ctrl-/'] let g:fzf_preview_window = ['right:66%', 'ctrl-/']
let g:fzf_buffers_jump = 1 let g:fzf_buffers_jump = 1
let g:fzf_commits_log_options = '--graph --color=always --format="%C(auto)%h%d %s %C(black)%C(bold)%cr"'
let $FZF_DEFAULT_OPTS="--ansi --layout reverse --margin=1,4 --preview 'batcat --color=always --style=header,grid --line-range :300 {}'"
let $FZF_DEFAULT_COMMAND = 'rg --files --ignore-case --hidden -g "!{.git,node_modules,vendor}/*"'
command! -bang -nargs=? -complete=dir Files
\ call fzf#vim#files(<q-args>, { 'options': $FZF_DEFAULT_OPTS}, <bang>0)
" }}} " }}}
Plug 'antoinemadec/coc-fzf'
Plug 'airblade/vim-rooter'
" coc " coc
Plug 'neoclide/coc.nvim', {'do': 'yarn install --frozen-lockfile'} Plug 'neoclide/coc.nvim', {'do': 'yarn install --frozen-lockfile'}
" {{{ " {{{
" Keep in sync with below
let g:coc_global_extensions = [ let g:coc_global_extensions = [
\ 'coc-actions',
\ 'coc-clangd',
\ 'coc-css', \ 'coc-css',
\ 'coc-docker',
\ 'coc-emmet',
\ 'coc-emoji',
\ 'coc-eslint', \ 'coc-eslint',
\ 'coc-explorer',
\ 'coc-fish',
\ 'coc-fzf-preview',
\ 'coc-git', \ 'coc-git',
\ 'coc-go',
\ 'coc-groovy',
\ 'coc-highlight',
\ 'coc-html', \ 'coc-html',
\ 'coc-json', \ 'coc-json',
\ 'coc-lists',
\ 'coc-marketplace',
\ 'coc-perl',
\ 'coc-prettier', \ 'coc-prettier',
\ 'coc-python', \ 'coc-python',
\ 'coc-rust-analyzer',
\ 'coc-sh',
\ 'coc-snippets',
\ 'coc-svg',
\ 'coc-tabnine', \ 'coc-tabnine',
\ 'coc-toml',
\ 'coc-tsserver', \ 'coc-tsserver',
\ 'coc-vimlsp',
\ 'coc-xml',
\ 'coc-yaml', \ 'coc-yaml',
\ ] \ ]
" }}} " }}}
Plug 'neoclide/coc-css', {'do': 'yarn install --frozen-lockfile'}
Plug 'neoclide/coc-eslint', {'do': 'yarn install --frozen-lockfile'}
Plug 'neoclide/coc-git', {'do': 'yarn install --frozen-lockfile'}
Plug 'neoclide/coc-html', {'do': 'yarn install --frozen-lockfile'}
Plug 'neoclide/coc-json', {'do': 'yarn install --frozen-lockfile'}
Plug 'neoclide/coc-prettier', {'do': 'yarn install --frozen-lockfile'}
Plug 'neoclide/coc-python', {'do': 'yarn install --frozen-lockfile'}
Plug 'neoclide/coc-tabnine', {'do': 'yarn install --frozen-lockfile'}
Plug 'neoclide/coc-tsserver', {'do': 'yarn install --frozen-lockfile'}
Plug 'neoclide/coc-yaml', {'do': 'yarn install --frozen-lockfile'}
call plug#end() call plug#end()

View File

@@ -1,6 +1,11 @@
if [ -z "$PROFILE_LOCK" ]; then # U _____ u _ _ __ __
export PROFILE_LOCK=1 # \| ___"|/| \ |"| \ \ /"/u
# | _|" <| \| |> \ \ / //
# | |___ U| |\ |u /\ V /_,-.
# |_____| |_| \_| U \_/-(_/
# << >> || \\,-.//
# (__) (__)(_") (_/(__)
#
# set PATH so it includes user's private bin # set PATH so it includes user's private bin
export PATH="$HOME/bin:$PATH" export PATH="$HOME/bin:$PATH"
export PATH="$HOME/.local/bin:$PATH" export PATH="$HOME/.local/bin:$PATH"
@@ -21,6 +26,11 @@ if [ -z "$PROFILE_LOCK" ]; then
fi fi
mkdir -p "$WORKSPACE" mkdir -p "$WORKSPACE"
# dotfiles
if [ -z "$DOTFILES" ]; then
export DOTFILES="$HOME/.dotfiles"
fi
# pyenv # pyenv
export PYENV_ROOT="$HOME/.pyenv" export PYENV_ROOT="$HOME/.pyenv"
export PATH="$PYENV_ROOT/bin:$PATH" export PATH="$PYENV_ROOT/bin:$PATH"
@@ -45,6 +55,31 @@ if [ -z "$PROFILE_LOCK" ]; then
mkdir -p "$YARN_DIR" mkdir -p "$YARN_DIR"
export PATH="$YARN_DIR/bin:$PATH" export PATH="$YARN_DIR/bin:$PATH"
fi # editor
export EDITOR="nvim"
export VISUAL="nvim"
# fzf
export FZF_DEFAULT_OPTS="--reverse --margin=1,5%"
export FZF_DEFAULT_COMMAND='fdfind --type f --hidden --follow --exclude .git'
export FZF_CTRL_T_COMMAND="$FZF_DEFAULT_COMMAND"
export FZF_COMPLETION_TRIGGER='**'
# do not use fishlogin for subshells
export SHELL=/bin/sh
# _ _ _ ____
# U /"\ u |"| ___ U /"\ u / __"| u
# \/ _ \/ U | | u |_"_| \/ _ \/ <\___ \/
# / ___ \ \| |/__ | | / ___ \ u___) |
# /_/ \_\ |_____| U/| |\u /_/ \_\ |____/>>
# \\ >> // \\.-,_|___|_,-.\\ >> )( (__)
# (__) (__)(_")("_)\_)-' '-(_/(__) (__)(__)
#
alias vim='nvim' alias vim='nvim'
alias vi='vim'
alias bat='batcat'
alias cat='bat'
alias j="z"

View File

@@ -1,6 +1,7 @@
apt-transport-https apt-transport-https
bat bat
curl curl
fdfind
git git
gnupg2 gnupg2
jq jq

View File

@@ -26,7 +26,7 @@ if not_installed "fishlogin"; then
mkdir -p ~/bin mkdir -p ~/bin
target="$HOME/bin/fishlogin" target="$HOME/bin/fishlogin"
tee -a $target << END tee -a $target << END
#!/bin/bash -l #!/bin/bash
exec -l fish "\$@" exec -l fish "\$@"
END END
sudo chmod +x $target sudo chmod +x $target

View File

@@ -15,5 +15,5 @@ npm install -g neovim elm-format
sudo gem install neovim sudo gem install neovim
echo "Running PlugInstall"; echo "Running PlugInstall";
nvim --headless +PlugInstall +PlugUpgrade +PlugUpdate +qall nvim --headless +PlugClean! +PlugInstall +PlugUpgrade +PlugUpdate +qall
nvim --version nvim --version

View File

@@ -4,7 +4,7 @@
# #
from distutils.spawn import find_executable from distutils.spawn import find_executable
from typing import List from typing import List
from subprocess import run, CalledProcessError from subprocess import run
import pytest import pytest
@@ -26,7 +26,7 @@ def in_shell_path(shell: str, binary: str) -> bool:
try: try:
result = run(command, shell=True) result = run(command, shell=True)
return (result.returncode == 0) return (result.returncode == 0)
except: except Exception:
return False return False
@@ -49,7 +49,9 @@ binaries: List[str] = [
"nvim", "nvim",
"firebase", "firebase",
"aws", "aws",
"gcloud",
"terraform", "terraform",
"kubectl",
"docker", "docker",
"docker-compose", "docker-compose",
"screenfetch", "screenfetch",
@@ -65,13 +67,19 @@ binaries: List[str] = [
"node", "node",
"npm", "npm",
"yarn", "yarn",
"elm", # "elm",
# language: java
"java",
# langauge: ruby
"ruby"
] ]
# ---------------------------------------------------------------------------- # # --------------------------------------------------------------------------- #
# Tests # Tests
# ---------------------------------------------------------------------------- # # --------------------------------------------------------------------------- #
@pytest.mark.parametrize("shell", shells) @pytest.mark.parametrize("shell", shells)
def test_shells(shell: str): def test_shells(shell: str):
""" Assert all shells we expect are in PATH. """ """ Assert all shells we expect are in PATH. """