├── README.md ├── omf.fish ├── settings.json ├── .tmux.conf └── init.vim /README.md: -------------------------------------------------------------------------------- 1 | # My config files for tmux, neovim, vscode, and fish shell 2 | -------------------------------------------------------------------------------- /omf.fish: -------------------------------------------------------------------------------- 1 | # Path to Oh My Fish install. 2 | set -q XDG_DATA_HOME 3 | and set -gx OMF_PATH "$XDG_DATA_HOME/omf" 4 | or set -gx OMF_PATH "$HOME/.local/share/omf" 5 | 6 | # Load Oh My Fish configuration. 7 | source $OMF_PATH/init.fish 8 | 9 | # custom stuff 10 | 11 | set -gx PATH /Users/benawad/bin $PATH 12 | set -gx PATH /Users/benawad/Library/Python/3.7/bin $PATH 13 | 14 | alias c='clear' 15 | fish_vi_key_bindings 16 | -------------------------------------------------------------------------------- /settings.json: -------------------------------------------------------------------------------- 1 | { 2 | // Place your settings in this file to overwrite the default settings 3 | "vim.insertModeKeyBindings": [ 4 | { 5 | "before": ["j", "k"], 6 | "after": [""] 7 | } 8 | ], 9 | "window.zoomLevel": 0.75, 10 | "editor.fontSize": 18, 11 | "terminal.integrated.fontSize": 17, 12 | "editor.formatOnSave": true, 13 | "files.exclude": { 14 | "**/.git": true, 15 | "**/.svn": true, 16 | "**/.hg": true, 17 | "**/CVS": true, 18 | "**/.DS_Store": true, 19 | "**/node_modules": true 20 | }, 21 | "[javascript]": { 22 | "editor.tabSize": 2 23 | }, 24 | "[typescriptreact]": { 25 | "editor.tabSize": 2 26 | }, 27 | "[typescript]": { 28 | "editor.tabSize": 2 29 | }, 30 | "[graphql]": { 31 | "editor.tabSize": 2 32 | }, 33 | "editor.minimap.enabled": false, 34 | "explorer.confirmDragAndDrop": false, 35 | "workbench.statusBar.feedback.visible": false, 36 | "workbench.editor.labelFormat": "short", 37 | "terminal.integrated.rendererType": "dom", 38 | "emmet.excludeLanguages": ["typescript", "typescriptreact", "javascript"], 39 | "terminal.integrated.shell.osx": "/usr/local/bin/fish", 40 | "workbench.editor.showTabs": true, 41 | "breadcrumbs.enabled": true 42 | } 43 | -------------------------------------------------------------------------------- /.tmux.conf: -------------------------------------------------------------------------------- 1 | # ctrl-space for modifier 2 | unbind C-b 3 | set -g prefix C-Space 4 | bind C-Space send-prefix 5 | 6 | # start window and pane numbering from 1 7 | set -g base-index 1 8 | setw -g pane-base-index 1 9 | 10 | # renumber windows on close 11 | set -g renumber-windows on 12 | 13 | # have tmux remember more lines 14 | set -g history-limit 10000 15 | 16 | # smooth copy and pasting 17 | # tmux < v2.1: 18 | if-shell "[[ `tmux -V | cut -d' ' -f2` -lt 2.1 ]]" "setw -g mode-mouse off" 19 | # tmux >= v2.1: 20 | if-shell "[[ `tmux -V | cut -d' ' -f2` -ge 2.1 ]]" "setw -g mouse off" 21 | 22 | # increase vim responsiveness 23 | set -sg escape-time 0 24 | 25 | # Smart pane switching with awareness of vim splits 26 | # See: https://github.com/christoomey/vim-tmux-navigator 27 | is_vim='echo "#{pane_current_command}" | grep -iqE "(^|\/)g?(view|n?vim?x?)(diff)?$"' 28 | bind -n C-h if-shell "$is_vim" "send-keys C-h" "select-pane -L" 29 | bind -n C-j if-shell "$is_vim" "send-keys C-j" "select-pane -D" 30 | bind -n C-k if-shell "$is_vim" "send-keys C-k" "select-pane -U" 31 | bind -n C-l if-shell "$is_vim" "send-keys C-l" "select-pane -R" 32 | bind -n C-\ if-shell "$is_vim" "send-keys C-\\" "select-pane -l" 33 | 34 | bind '%' split-window -h -c '#{pane_current_path}' # Split panes horizontal 35 | bind '"' split-window -v -c '#{pane_current_path}' # Split panes vertically 36 | bind c new-window -c '#{pane_current_path}' # Create new window 37 | 38 | set -g default-shell $SHELL 39 | set -g default-command "reattach-to-user-namespace -l ${SHELL}" 40 | 41 | # fix scrolling 42 | set -g mouse on 43 | bind -n WheelUpPane if-shell -F -t = "#{mouse_any_flag}" "send-keys -M" "if -Ft= '#{pane_in_mode}' 'send-keys -M' 'select-pane -t=; copy-mode -e; send-keys -M'" 44 | bind -n WheelDownPane select-pane -t= \; send-keys -M 45 | 46 | # color theme 47 | set -g default-terminal "xterm-256color" 48 | set -ga terminal-overrides ",xterm-256color:Tc" 49 | -------------------------------------------------------------------------------- /init.vim: -------------------------------------------------------------------------------- 1 | call plug#begin('~/.config/nvim/bundle') 2 | Plug 'Shougo/deoplete.nvim', { 'do': ':UpdateRemotePlugins' } 3 | Plug 'scrooloose/nerdtree' 4 | Plug 'scrooloose/nerdcommenter' 5 | Plug 'christoomey/vim-tmux-navigator' 6 | Plug 'zchee/deoplete-jedi' 7 | Plug 'trevordmiller/nova-vim' 8 | Plug 'pangloss/vim-javascript' 9 | Plug 'mxw/vim-jsx' 10 | Plug 'w0rp/ale' 11 | " call PlugInstall to install new plugins 12 | call plug#end() 13 | 14 | " basics 15 | filetype plugin indent on 16 | syntax on set number 17 | set relativenumber 18 | set incsearch 19 | set ignorecase 20 | set smartcase 21 | set nohlsearch 22 | set tabstop=4 23 | set softtabstop=0 24 | set shiftwidth=4 25 | set expandtab 26 | set nobackup 27 | set noswapfile 28 | set nowrap 29 | 30 | " preferences 31 | inoremap jk 32 | let mapleader = "\" 33 | set pastetoggle= 34 | " j/k will move virtual lines (lines that wrap) 35 | noremap j (v:count == 0 ? 'gj' : 'j') 36 | noremap k (v:count == 0 ? 'gk' : 'k') 37 | " Stay in visual mode when indenting. You will never have to run gv after 38 | " performing an indentation. 39 | vnoremap < >gv 41 | " Make Y yank everything from the cursor to the end of the line. This makes Y 42 | " act more like C or D because by default, Y yanks the current line (i.e. the 43 | " same as yy). 44 | noremap Y y$ 45 | " navigate split screens easily 46 | nmap :wincmd k 47 | nmap :wincmd j 48 | nmap :wincmd h 49 | nmap :wincmd l 50 | " change spacing for language specific 51 | autocmd Filetype javascript setlocal ts=2 sts=2 sw=2 52 | 53 | " plugin settings 54 | 55 | " deoplete 56 | let g:deoplete#enable_at_startup = 1 57 | " use tab to forward cycle 58 | inoremap pumvisible() ? "\" : "\" 59 | " use tab to backward cycle 60 | inoremap pumvisible() ? "\" : "\" 61 | " Close the documentation window when completion is done 62 | autocmd InsertLeave,CompleteDone * if pumvisible() == 0 | pclose | endif 63 | 64 | " Theme 65 | syntax enable 66 | "let $NVIM_TUI_ENABLE_TRUE_COLOR=1 67 | set termguicolors 68 | set background=dark 69 | colorscheme nova 70 | 71 | "NERDTree 72 | " How can I close vim if the only window left open is a NERDTree? 73 | autocmd bufenter * if (winnr("$") == 1 && exists("b:NERDTree") && b:NERDTree.isTabTree()) | q | endif 74 | " toggle NERDTree 75 | map :NERDTreeToggle 76 | let g:NERDTreeChDirMode=2 77 | let g:NERDTreeIgnore=['\.rbc$', '\~$', '\.pyc$', '\.db$', '\.sqlite$', '__pycache__', 'node_modules'] 78 | let g:NERDTreeSortOrder=['^__\.py$', '\/$', '*', '\.swp$', '\.bak$', '\~$'] 79 | let g:NERDTreeShowBookmarks=1 80 | let g:nerdtree_tabs_focus_on_files=1 81 | let g:NERDTreeMapOpenInTabSilent = '' 82 | set wildignore+=*/tmp/*,*.so,*.swp,*.zip,*.pyc,*.db,*.sqlite 83 | 84 | " jsx 85 | let g:jsx_ext_required = 0 86 | 87 | " ale prettier-eslint 88 | "let g:ale_fixers = { 89 | "\ 'javascript': ['prettier_eslint'], 90 | "\} 91 | "let g:ale_fix_on_save = 1 92 | "let g:ale_javascript_prettier_eslint_executable = 'prettier-eslint' 93 | "let g:ale_javascript_prettier_eslint_use_global = 1 94 | --------------------------------------------------------------------------------