diff --git a/Brewfile b/Brewfile index 17fdd46..5d106dd 100644 --- a/Brewfile +++ b/Brewfile @@ -5,11 +5,14 @@ tap 'homebrew/services' tap 'thoughtbot/formulae' brew 'antibody' brew 'autojump' +brew 'bat' brew 'direnv' +brew 'dust' brew 'fd' brew 'fzf' brew 'go' brew 'heroku' +brew 'hexedit' brew 'hub' brew 'jq' brew 'mas' @@ -17,13 +20,14 @@ brew 'r' brew 'rcm' brew 'starship' brew 'terminal-notifier' +brew 'tldr' brew 'wget' brew 'zsh' -tap 'caskroom/cask' tap 'homebrew/cask-fonts' cask_args appdir: '/Applications' cask '1password' +cask '1password-cli' cask 'datagrip' cask 'docker' cask 'evernote' diff --git a/com.googlecode.iterm2.plist b/com.googlecode.iterm2.plist index 09de2a1..da33c34 100644 --- a/com.googlecode.iterm2.plist +++ b/com.googlecode.iterm2.plist @@ -4,6 +4,8 @@ AppleAntiAliasingThreshold 1 + ApplePressAndHoldEnabled + AppleScrollAnimationEnabled 0 AppleSmoothFixedFontsSizeThreshold @@ -36,6 +38,8 @@ ~/src/dotfiles NSNavPanelExpandedSizeForOpenMode {712, 448} + NSNavPanelExpandedSizeForSaveMode + {712, 448} NSQuotedKeystrokeBinding NSRepeatCountBinding @@ -51,24 +55,24 @@ NSTableView Columns v2 KeyBingingTable - YnBsaXN0MDDUAQIDBAUGNjdYJHZlcnNpb25YJG9iamVjdHNZJGFyY2hpdmVyVCR0b3AS - AAGGoK4HCA8aGxwdHh8gJjAxMlUkbnVsbNIJCgsOWk5TLm9iamVjdHNWJGNsYXNzogwN - gAKACoAN0xAJChEVGVdOUy5rZXlzoxITFIADgASABaMWFxiABoAHgAiACVpJZGVudGlm - aWVyVVdpZHRoVkhpZGRlblEwI0BowAAAAAAACNIhIiMkWiRjbGFzc25hbWVYJGNsYXNz - ZXNcTlNEaWN0aW9uYXJ5oiMlWE5TT2JqZWN00xAJCicrGaMSExSAA4AEgAWjLC0YgAuA - DIAIgAlRMSNAdKGdsi0OVtIhIjM0Xk5TTXV0YWJsZUFycmF5ozM1JVdOU0FycmF5XxAP - TlNLZXllZEFyY2hpdmVy0Tg5VUFycmF5gAEACAARABoAIwAtADIANwBGAEwAUQBcAGMA - ZgBoAGoAbABzAHsAfwCBAIMAhQCJAIsAjQCPAJEAnACiAKkAqwC0ALUAugDFAM4A2wDe - AOcA7gDyAPQA9gD4APwA/gEAAQIBBAEGAQ8BFAEjAScBLwFBAUQBSgAAAAAAAAIBAAAA + YnBsaXN0MDDUAQIDBAUGBwpYJHZlcnNpb25ZJGFyY2hpdmVyVCR0b3BYJG9iamVjdHMS + AAGGoF8QD05TS2V5ZWRBcmNoaXZlctEICVVBcnJheYABrgsMEx4fICEiIyQqNDU2VSRu + dWxs0g0ODxJaTlMub2JqZWN0c1YkY2xhc3OiEBGAAoAKgA3TFA0OFRkdV05TLmtleXOj + FhcYgAOABIAFoxobHIAGgAeACIAJWklkZW50aWZpZXJVV2lkdGhWSGlkZGVuUTAjQGjA + AAAAAAAI0iUmJyhaJGNsYXNzbmFtZVgkY2xhc3Nlc1xOU0RpY3Rpb25hcnmiJylYTlNP + YmplY3TTFA0OKy8doxYXGIADgASABaMwMRyAC4AMgAiACVExI0B0oZ2yLQ5W0iUmNzhe + TlNNdXRhYmxlQXJyYXmjNzkpV05TQXJyYXkACAARABoAJAApADIANwBJAEwAUgBUAGMA + aQBuAHkAgACDAIUAhwCJAJAAmACcAJ4AoACiAKYAqACqAKwArgC5AL8AxgDIANEA0gDX + AOIA6wD4APsBBAELAQ8BEQETARUBGQEbAR0BHwEhASMBLAExAUABRAAAAAAAAAIBAAAA AAAAADoAAAAAAAAAAAAAAAAAAAFM NSTableView Sort Ordering v2 KeyBingingTable - YnBsaXN0MDDUAQIDBAUGFBVYJHZlcnNpb25YJG9iamVjdHNZJGFyY2hpdmVyVCR0b3AS - AAGGoKMHCA1VJG51bGzSCQoLDFpOUy5vYmplY3RzViRjbGFzc6CAAtIODxARWiRjbGFz - c25hbWVYJGNsYXNzZXNeTlNNdXRhYmxlQXJyYXmjEBITV05TQXJyYXlYTlNPYmplY3Rf - EA9OU0tleWVkQXJjaGl2ZXLRFhdVQXJyYXmAAQgRGiMtMjc7QUZRWFlbYGt0g4ePmKqt - swAAAAAAAAEBAAAAAAAAABgAAAAAAAAAAAAAAAAAAAC1 + YnBsaXN0MDDUAQIDBAUGBwpYJHZlcnNpb25ZJGFyY2hpdmVyVCR0b3BYJG9iamVjdHMS + AAGGoF8QD05TS2V5ZWRBcmNoaXZlctEICVVBcnJheYABowsMEVUkbnVsbNINDg8QWk5T + Lm9iamVjdHNWJGNsYXNzoIAC0hITFBVaJGNsYXNzbmFtZVgkY2xhc3Nlc15OU011dGFi + bGVBcnJheaMUFhdXTlNBcnJheVhOU09iamVjdAgRGiQpMjdJTFJUWF5jbnV2eH2IkaCk + rAAAAAAAAAEBAAAAAAAAABgAAAAAAAAAAAAAAAAAAAC1 NSTableView Supports v2 KeyBingingTable @@ -77,14 +81,20 @@ TB Is Shown 1 - NSWindow Frame NSColorPanel - 0 163 224 275 0 0 1680 1027 + NSWindow Frame SUStatusFrame + 760 786 400 129 0 0 1920 1177 NSWindow Frame SUUpdateAlert - 650 588 620 392 0 0 1920 1177 + 650 588 620 392 0 0 1680 1027 + NSWindow Frame SessionsPreferences + 342 -930 606 469 122 -1050 1680 1027 + NSWindow Frame SharedPreferences + 314 370 1018 447 0 0 1680 1027 + NSWindow Frame UKCrashReporter + 127 443 592 584 0 0 1680 1027 NSWindow Frame iTerm Window 0 - 362 101 1210 892 0 0 1680 1027 + 375 73 1210 942 0 0 1920 1177 NSWindow Frame iTerm Window 1 - 212 102 570 452 0 0 1680 1027 + 0 85 1210 942 0 0 1920 1177 New Bookmarks @@ -293,7 +303,7 @@ Custom Command No Custom Directory - No + Recycle Default Bookmark No Description @@ -319,6 +329,8 @@ 1 Idle Code 0 + Initial Use Transparency + Jobs to Ignore rlogin @@ -696,14 +708,13 @@ NoSyncAllAppVersions - 3.3.2 - 3.3.3 - - NoSyncBFPRecents - - Fira Code - Fira Mono for Powerline - Monaco + 3.3.8 + 3.2.9 + 3.3.1 + 3.3.4 + 3.3.0 + 3.3.7 + 3.3.6 NoSyncCommandHistoryHasEverBeenUsed @@ -712,26 +723,24 @@ screenFrame {{0, 0}, {1920, 1200}} topLeft - {269, 845} + {638, 935} - NoSyncHaveUsedCopyMode + NoSyncHaveWarnedAboutPasteConfirmationChange NoSyncInstallationId - 5172F315-8C30-43A1-8566-4053ECD1B956 - NoSyncLastTipTime - 590174506.00996602 + E62744D1-B0F7-4F92-AE5F-87F0CBEC362A NoSyncLaunchExperienceControllerRunCount - 7 + 29 NoSyncNeverRemindPrefsChangesLostForFile NoSyncNeverRemindPrefsChangesLostForFile_selection 0 NoSyncNextAnnoyanceTime - 588267587.514516 + 586539063.30087698 NoSyncOnboardingWindowHasBeenShown NoSyncPermissionToShowTip - + NoSyncRecordedVariables 0 @@ -1082,7 +1091,7 @@ isTerminal name - currentTab.currentSession.terminalIconName + currentTab.currentSession.terminalWindowName nonterminalContext 0 @@ -1090,7 +1099,7 @@ isTerminal name - currentTab.currentSession.terminalWindowName + currentTab.currentSession.terminalIconName nonterminalContext 0 @@ -1154,7 +1163,7 @@ isTerminal name - number + currentTab.currentSession.path nonterminalContext 0 @@ -1162,7 +1171,7 @@ isTerminal name - currentTab.currentSession.path + currentTab.currentSession.commandLine nonterminalContext 0 @@ -1170,7 +1179,7 @@ isTerminal name - currentTab.currentSession.commandLine + number nonterminalContext 0 @@ -1227,27 +1236,27 @@ isTerminal - + name - currentSession + currentSession.commandLine nonterminalContext - 1 + 0 isTerminal name - currentSession.commandLine + currentSession.terminalIconName nonterminalContext 0 isTerminal - + name - currentSession.terminalIconName + title nonterminalContext - 0 + 1 isTerminal @@ -1261,7 +1270,7 @@ isTerminal name - currentSession.presentationName + title nonterminalContext 0 @@ -1269,7 +1278,7 @@ isTerminal name - iterm2.localhostName + currentSession.presentationName nonterminalContext 0 @@ -1277,7 +1286,7 @@ isTerminal name - currentSession.jobPid + iterm2.localhostName nonterminalContext 0 @@ -1329,14 +1338,6 @@ nonterminalContext 0 - - isTerminal - - name - currentSession.lastCommand - nonterminalContext - 0 - isTerminal @@ -1361,14 +1362,6 @@ nonterminalContext 0 - - isTerminal - - name - currentSession.termid - nonterminalContext - 0 - isTerminal @@ -1381,7 +1374,7 @@ isTerminal name - currentSession.pid + currentSession.path nonterminalContext 0 @@ -1405,7 +1398,7 @@ isTerminal name - currentSession.terminalWindowName + currentSession.pid nonterminalContext 0 @@ -1413,7 +1406,7 @@ isTerminal name - currentSession.path + currentSession.terminalWindowName nonterminalContext 0 @@ -1425,6 +1418,14 @@ nonterminalContext 0 + + isTerminal + + name + currentSession + nonterminalContext + 1 + isTerminal @@ -1462,30 +1463,8 @@ - NoSyncTipOfTheDayEligibilityBeganTime - 587934427.87246704 - NoSyncTipsDisabled - - NoSyncTipsToNotShow - - 000 - 0000 - 0001 - 0002 - 0003 - 0004 - 0005 - 0006 - 0007 - 0008 - 0009 - 0010 - 0011 - 0012 - 0013 - 0014 - 0015 - + NoSyncTimeOfFirstLaunchOfVersionWithTip + 522779968.962524 PMPrintingExpandedStateForPrint2 PasteSpecialChunkDelay @@ -1539,6 +1518,8 @@ /Users/alexburgel/src/dotfiles Print In Black And White + PromptOnQuitEvenIfThereAreNoWindows + QuickPasteBytesPerCall 11389 QuickPasteDelayBetweenCalls @@ -1548,11 +1529,11 @@ SUFeedAlternateAppNameKey iTerm SUFeedURL - https://iterm2.com/appcasts/final_new.xml?shard=2 + https://iterm2.com/appcasts/final_new.xml?shard=51 SUHasLaunchedBefore SULastCheckTime - 2019-09-12T17:04:01Z + 2020-02-03T15:08:21Z SUSendProfileInfo SUUpdateRelaunchingMarker @@ -1565,6 +1546,10 @@ 0.38334084535256407 TabStyleWithAutomaticOption 5 + UKCrashReporterLastCrashReportDate + 1545409280 + URLHandlersByGuid + VisualIndicatorForEsc Window Arrangements @@ -1578,6 +1563,6 @@ findRegex_iTerm iTerm Version - 3.3.3 + 3.3.8 diff --git a/gitconfig b/gitconfig index 67e9abe..41ac817 100644 --- a/gitconfig +++ b/gitconfig @@ -44,3 +44,5 @@ tool = Kaleidoscope [credential] helper = osxkeychain +[diff] + colorMoved = zebra diff --git a/tmux.conf b/tmux.conf index 11205bc..628d17c 100644 --- a/tmux.conf +++ b/tmux.conf @@ -3,10 +3,10 @@ set -g default-terminal 'screen-256color' # act like vim setw -g mode-keys vi -bind h select-pane -L -bind j select-pane -D -bind k select-pane -U -bind l select-pane -R +bind-key h select-pane -L +bind-key j select-pane -D +bind-key k select-pane -U +bind-key l select-pane -R bind-key -r C-h select-window -t :- bind-key -r C-l select-window -t :+ @@ -20,8 +20,7 @@ set-window-option -g pane-base-index 1 set -g renumber-windows on # soften status bar color from harsh green to light gray -set -g status-bg '#666666' -set -g status-fg '#aaaaaa' +set -g status-style bg='#666666',fg='#aaaaaa' # remove administrative debris (session name, hostname, time) in status bar set -g status-left '' diff --git a/vimrc b/vimrc index 52cdd28..fc66370 100644 --- a/vimrc +++ b/vimrc @@ -1,3 +1,5 @@ +set encoding=utf-8 + " Leader let mapleader = " " @@ -11,6 +13,8 @@ set showcmd " display incomplete commands set incsearch " do incremental searching set laststatus=2 " Always display the status line set autowrite " Automatically :write before running commands +set modelines=0 " Disable modelines as a security precaution +set nomodeline " Switch syntax highlighting on, when the terminal has colors " Also switch on highlighting the last used search pattern. @@ -41,9 +45,29 @@ augroup vimrcEx \ endif " Set syntax highlighting for specific file types - autocmd BufRead,BufNewFile Appraisals set filetype=ruby autocmd BufRead,BufNewFile *.md set filetype=markdown autocmd BufRead,BufNewFile .{jscs,jshint,eslint}rc set filetype=json + autocmd BufRead,BufNewFile aliases.local,zshrc.local,*/zsh/configs/* set filetype=sh + autocmd BufRead,BufNewFile gitconfig.local set filetype=gitconfig + autocmd BufRead,BufNewFile tmux.conf.local set filetype=tmux + autocmd BufRead,BufNewFile vimrc.local set filetype=vim +augroup END + +" ALE linting events +augroup ale + autocmd! + + if g:has_async + autocmd VimEnter * + \ set updatetime=1000 | + \ let g:ale_lint_on_text_changed = 0 + autocmd CursorHold * call ale#Queue(0) + autocmd CursorHoldI * call ale#Queue(0) + autocmd InsertEnter * call ale#Queue(0) + autocmd InsertLeave * call ale#Queue(0) + else + echoerr "The thoughtbot dotfiles require NeoVim or Vim 8" + endif augroup END " When the type of shell script is /bin/sh, assume a POSIX-compatible @@ -67,11 +91,8 @@ if executable('ag') " Use Ag over Grep set grepprg=ag\ --nogroup\ --nocolor - " Use ag in CtrlP for listing files. Lightning fast and respects .gitignore - let g:ctrlp_user_command = 'ag -Q -l --nocolor --hidden -g "" %s' - - " ag is fast enough that CtrlP doesn't need to cache - let g:ctrlp_use_caching = 0 + " Use ag in fzf for listing files. Lightning fast and respects .gitignore + let $FZF_DEFAULT_COMMAND = 'ag --literal --files-with-matches --nocolor --hidden -g ""' if !exists(":Ag") command -nargs=+ -complete=file -bar Ag silent! grep! |cwindow|redraw! @@ -94,16 +115,16 @@ set wildmode=list:longest,list:full function! InsertTabWrapper() let col = col('.') - 1 if !col || getline('.')[col - 1] !~ '\k' - return "\" + return "\" else - return "\" + return "\" endif endfunction -inoremap =InsertTabWrapper() -inoremap +inoremap =InsertTabWrapper() +inoremap " Switch between the last two files -nnoremap +nnoremap " Get off my lawn nnoremap :echoe "Use h" @@ -116,14 +137,17 @@ nnoremap t :TestFile nnoremap s :TestNearest nnoremap l :TestLast nnoremap a :TestSuite -nnoremap gt :TestVisit +nnoremap gt :TestVisit " Run commands that require an interactive shell -nnoremap r :RunInInteractiveShell +nnoremap r :RunInInteractiveShell " Treat
  • and

    tags like the block tags they are let g:html_indent_tags = 'li\|p' +" Set tags for vim-fugitive +set tags^=.git/tags + " Open new split panes to right and bottom, which feels more natural set splitbelow set splitright @@ -134,11 +158,12 @@ nnoremap k nnoremap h nnoremap l -" configure syntastic syntax checking to check on open as well as save -let g:syntastic_check_on_open=1 -let g:syntastic_html_tidy_ignore_errors=[" proprietary attribute \"ng-"] -let g:syntastic_eruby_ruby_quiet_messages = - \ {"regex": "possibly useless use of a variable in void context"} +" Move between linting errors +nnoremap ]r :ALENextWrap +nnoremap [r :ALEPreviousWrap + +" Map Ctrl + p to open fuzzy find (FZF) +nnoremap :Files " Set spellfile to location that is guaranteed to exist, can be symlinked to " Dropbox or kept in Git and managed outside of thoughtbot/dotfiles using rcm. @@ -149,3 +174,8 @@ set complete+=kspell " Always use vertical diffs set diffopt+=vertical + +" Local config +if filereadable($HOME . "/.vimrc.local") + source ~/.vimrc.local +endif diff --git a/vimrc.bundles b/vimrc.bundles index 0de5cd4..633a44f 100644 --- a/vimrc.bundles +++ b/vimrc.bundles @@ -10,38 +10,27 @@ function! s:UnPlug(plug_name) endfunction command! -nargs=1 UnPlug call s:UnPlug() -" Shim command and function to allow migration from Vundle to vim-plug. -function! VundleToPlug(vundle_command, arg, ...) - echom "You are using Vundle's `".a:vundle_command."` command to declare plugins. Dotfiles now uses vim-plug for plugin management. Please rename uses of `".a:vundle_command."` to `Plug`. Plugin was '".a:arg."'." - let vim_plug_options = {} - - if a:0 > 0 - if has_key(a:1, 'name') - let name = a:1.name - let vim_plug_options.dir = "$HOME/.vim/bundle/".a:1.name - endif - - if has_key(a:1, 'rtp') - let vim_plug_options.rtp = a:1.rtp - endif - endif - - Plug a:arg, vim_plug_options -endfunction - -com! -nargs=+ -bar Plugin call VundleToPlug("Plugin", ) -com! -nargs=+ -bar Bundle call VundleToPlug("Bundle", ) +let g:has_async = v:version >= 800 || has('nvim') call plug#begin('~/.vim/bundle') " Define bundles via Github repos Plug 'christoomey/vim-run-interactive' -Plug 'ctrlpvim/ctrlp.vim' + +" If fzf has already been installed via Homebrew, use the existing fzf +" Otherwise, install fzf. The `--all` flag makes fzf accessible outside of vim +if isdirectory("/usr/local/opt/fzf") + Plug '/usr/local/opt/fzf' +else + Plug 'junegunn/fzf', { 'dir': '~/.fzf', 'do': './install --all' } +endif + +Plug 'junegunn/fzf.vim' Plug 'elixir-lang/vim-elixir' Plug 'fatih/vim-go' Plug 'janko-m/vim-test' +Plug 'pangloss/vim-javascript' Plug 'pbrisbin/vim-mkdir' -Plug 'scrooloose/syntastic' Plug 'slim-template/vim-slim' Plug 'tpope/vim-bundler' Plug 'tpope/vim-endwise' @@ -56,4 +45,12 @@ Plug 'tpope/vim-surround' Plug 'vim-ruby/vim-ruby' Plug 'vim-scripts/tComment' +if g:has_async + Plug 'dense-analysis/ale' +endif + +if filereadable(expand("~/.vimrc.bundles.local")) + source ~/.vimrc.bundles.local +endif + call plug#end() diff --git a/vscode.settings.json b/vscode.settings.json index e7c3df0..7b85ec3 100644 --- a/vscode.settings.json +++ b/vscode.settings.json @@ -48,5 +48,9 @@ "gitlens.views.search.location": "scm", "editor.cursorStyle": "block", "editor.cursorBlinking": "solid", - "editor.renderWhitespace": "all" + "editor.renderWhitespace": "all", + "[typescript]": { + "editor.defaultFormatter": "esbenp.prettier-vscode" + }, + "editor.multiCursorModifier": "ctrlCmd" } diff --git a/zsh/configs/poetry b/zsh/configs/poetry new file mode 100644 index 0000000..bfda5e4 --- /dev/null +++ b/zsh/configs/poetry @@ -0,0 +1 @@ +export PATH="$HOME/.poetry/bin:$PATH"