[
  {
    "path": ".bash_aliases",
    "content": "alias gti='git'\n#alias tmux='tmux -2'\nalias less='less -R'\nalias diff='colordiff'\nalias dc='cd'\nalias nethack-online='ssh nethack@nethack.alt.org ; clear'\nalias tron-online='ssh sshtron.zachlatta.com ; clear'\nalias glog='git log --oneline --graph --color --all --decorate'\n"
  },
  {
    "path": ".bash_exports",
    "content": "export TERM=xterm-256color\n\nexport LESS='-R'\nexport LESSOPEN='|~/.lessfilter %s'\n\n# perl plenv\n# export PATH=\"$HOME/.plenv/bin:$PATH\"\n# eval \"$(plenv init -)\"\n\n# golang\nexport GOPATH=~/gocode\nexport PATH=\"$GOPATH/bin:${PATH}:/usr/local/go/bin\"\n\n# ruby rbenv\nexport PATH=\"$HOME/.rbenv/bin:$PATH\"\neval \"$(rbenv init -)\"\nexport PATH=\"$HOME/.rbenv/plugins/ruby-build/bin:$PATH\"\n\nexport EDITOR=/usr/bin/vim\n\n"
  },
  {
    "path": ".bash_profile",
    "content": "if [ -n \"$TMUX\" ]; then\n    # called inside tmux session, do tmux things\n    . ~/.profile\n\nfi\n# Trigger ~/.bashrc commands\n. ~/.bashrc\n"
  },
  {
    "path": ".bash_wrappers",
    "content": "# colored man pages\nman() {\n    env LESS_TERMCAP_mb=$'\\E[01;31m' \\\n    LESS_TERMCAP_md=$'\\E[01;38;5;74m' \\\n    LESS_TERMCAP_me=$'\\E[0m' \\\n    LESS_TERMCAP_se=$'\\E[0m' \\\n    LESS_TERMCAP_so=$'\\E[01;33;03;40m' \\\n    LESS_TERMCAP_ue=$'\\E[0m' \\\n    LESS_TERMCAP_us=$'\\E[04;38;5;146m' \\\n    man \"$@\"\n}\n\n\nwhatsgoingon() {\n    for i in $(find . -maxdepth 1 -type d | sed -e 's/\\.\\///' -e '/\\./d'); do\n        pushd $i >/dev/null\n        echo \"$(tput bold)$i$(tput sgr0)\"\n        if [ -z \"$(git status --porcelain)\" ]; then\n            echo \"is clean\"\n        else\n            git status -s\n        fi\n        popd >/dev/null\n    done\n}\n"
  },
  {
    "path": ".bashrc",
    "content": "# ~/.bashrc: executed by bash(1) for non-login shells.\n# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc)\n# for examples\n\n# If not running interactively, don't do anything\ncase $- in\n    *i*) ;;\n      *) return;;\nesac\n\n# don't put duplicate lines or lines starting with space in the history.\n# See bash(1) for more options\nHISTCONTROL=ignoreboth\n\n# append to the history file, don't overwrite it\nshopt -s histappend\n\n# for setting history length see HISTSIZE and HISTFILESIZE in bash(1)\nHISTSIZE=1000\nHISTFILESIZE=2000\n\n# check the window size after each command and, if necessary,\n# update the values of LINES and COLUMNS.\nshopt -s checkwinsize\n\n# If set, the pattern \"**\" used in a pathname expansion context will\n# match all files and zero or more directories and subdirectories.\n#shopt -s globstar\n\n# make less more friendly for non-text input files, see lesspipe(1)\n#[ -x /usr/bin/lesspipe ] && eval \"$(SHELL=/bin/sh lesspipe)\"\n\n# set variable identifying the chroot you work in (used in the prompt below)\nif [ -z \"${debian_chroot:-}\" ] && [ -r /etc/debian_chroot ]; then\n    debian_chroot=$(cat /etc/debian_chroot)\nfi\n\n# set a fancy prompt (non-color, unless we know we \"want\" color)\ncase \"$TERM\" in\n    xterm-color|*-256color) color_prompt=yes;;\nesac\n\n# uncomment for a colored prompt, if the terminal has the capability; turned\n# off by default to not distract the user: the focus in a terminal window\n# should be on the output of commands, not on the prompt\nforce_color_prompt=yes\n\nif [ -n \"$force_color_prompt\" ]; then\n    if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then\n\t# We have color support; assume it's compliant with Ecma-48\n\t# (ISO/IEC-6429). (Lack of such support is extremely rare, and such\n\t# a case would tend to support setf rather than setaf.)\n\tcolor_prompt=yes\n    else\n\tcolor_prompt=\n    fi\nfi\n\nif [ \"$color_prompt\" = yes ]; then\n    prompt_color='\\[\\033[;32m\\]'\n    info_color='\\[\\033[1;34m\\]'\n    prompt_symbol=📛\n    if [ \"$EUID\" -eq 0 ]; then # Change prompt colors for root user\n\tprompt_color='\\[\\033[;94m\\]'\n\tinfo_color='\\[\\033[1;31m\\]'\n\tprompt_symbol=💀\n    fi\n    PS1=$prompt_color'┌──${debian_chroot:+($debian_chroot)──}('$info_color'\\u${prompt_symbol}\\h'$prompt_color')-[\\[\\033[0;1m\\]\\w'$prompt_color']\\n'$prompt_color'└─'$info_color'\\$\\[\\033[0m\\] '\n    # BackTrack red prompt\n    #PS1='${debian_chroot:+($debian_chroot)}\\[\\033[01;31m\\]\\u@\\h\\[\\033[00m\\]:\\[\\033[01;34m\\]\\w\\[\\033[00m\\]\\$ '\nelse\n    PS1='${debian_chroot:+($debian_chroot)}\\u@\\h:\\w\\$ '\nfi\nunset color_prompt force_color_prompt\n\n# If this is an xterm set the title to user@host:dir\ncase \"$TERM\" in\nxterm*|rxvt*)\n    PS1=\"\\[\\e]0;${debian_chroot:+($debian_chroot)}\\u@\\h: \\w\\a\\]$PS1\"\n    ;;\n*)\n    ;;\nesac\n\n# enable color support of ls, less and man, and also add handy aliases\nif [ -x /usr/bin/dircolors ]; then\n    test -r ~/.dircolors && eval \"$(dircolors -b ~/.dircolors)\" || eval \"$(dircolors -b)\"\n    alias ls='ls --color=auto'\n    #alias dir='dir --color=auto'\n    #alias vdir='vdir --color=auto'\n\n    alias grep='grep --color=auto'\n    alias fgrep='fgrep --color=auto'\n    alias egrep='egrep --color=auto'\n    alias diff='diff --color=auto'\n    alias ip='ip --color=auto'\n\n    export LESS_TERMCAP_mb=$'\\E[1;31m'     # begin blink\n    export LESS_TERMCAP_md=$'\\E[1;36m'     # begin bold\n    export LESS_TERMCAP_me=$'\\E[0m'        # reset bold/blink\n    export LESS_TERMCAP_so=$'\\E[01;33m'    # begin reverse video\n    export LESS_TERMCAP_se=$'\\E[0m'        # reset reverse video\n    export LESS_TERMCAP_us=$'\\E[1;32m'     # begin underline\n    export LESS_TERMCAP_ue=$'\\E[0m'        # reset underline\nfi\n\n# colored GCC warnings and errors\n#export GCC_COLORS='error=01;31:warning=01;35:note=01;36:caret=01;32:locus=01:quote=01'\n\n# some more ls aliases\nalias ll='ls -l'\nalias la='ls -A'\nalias l='ls -CF'\n\n# Alias definitions.\n# You may want to put all your additions into a separate file like\n# ~/.bash_aliases, instead of adding them here directly.\n# See /usr/share/doc/bash-doc/examples in the bash-doc package.\n\nif [ -f ~/.bash_aliases ]; then\n    . ~/.bash_aliases\nfi\n\n# enable programmable completion features (you don't need to enable\n# this, if it's already enabled in /etc/bash.bashrc and /etc/profile\n# sources /etc/bash.bashrc).\nif ! shopt -oq posix; then\n  if [ -f /usr/share/bash-completion/bash_completion ]; then\n    . /usr/share/bash-completion/bash_completion\n  elif [ -f /etc/bash_completion ]; then\n    . /etc/bash_completion\n  fi\nfi\n"
  },
  {
    "path": ".screenrc",
    "content": "# GNU Screen - main configuration file\n# Allow bold colors - necessary for some reason\nattrcolor b \".I\"\n\n# Tell screen how to set colors. AB = background, AF=foreground\ntermcapinfo xterm 'Co#256:AB=\\E[48;5;%dm:AF=\\E[38;5;%dm'\n\n# Enables use of shift-PgUp and shift-PgDn\ntermcapinfo xterm|xterms|xs|rxvt ti@:te@\n\n# Erase background with current bg color\ndefbce \"on\"\n\n# Enable 256 color term\nterm xterm-256color\n\n# Cache 30000 lines for scroll back\ndefscrollback 30000\n\nhardstatus alwayslastline\n# Very nice tabbed colored hardstatus line\nhardstatus string '%{= Kd} %{= Kd}%-w%{= Kr}[%{= KW}%n %t%{= Kr}]%{= Kd}%+w %-= %{KG} %H%{KW}|%{KY}%101`%{KW}|%D %M %d %Y%{= Kc} %C%A%{-}'\n\n# change command character from ctrl-a to ctrl-b (emacs users may want this)\n#escape ^Bb\n\n# Hide hardstatus: ctrl-a f\nbind f eval \"hardstatus ignore\"\n# Show hardstatus: ctrl-a F\nbind F eval \"hardstatus alwayslastline\"\n"
  },
  {
    "path": ".tmux.conf",
    "content": "# Make it use C-a, similar to screen..\n#unbind C-b\n#set -g prefix C-a\n\nset -g default-terminal \"screen-256color\"\nset -g history-limit 50000\n\n# Tmux mouse mode\nset-option -g mouse on\n\n## Enable mouse with 'm' and disable with 'M'\nunbind m\nbind m \\\n set -g mouse on \\;\\\n display 'Mouse: ON'\nunbind M\n  bind M \\\n  set -g mouse off \\;\\\n  display 'Mouse: OFF'\n\n# THEME\nset -g status-bg colour235\nset -g status-fg yellow\n#set-option -g status-attr dim\n#set-window-option -g window-status-current-fg brightred #orange\n#set-window-option -g window-status-current-bg colour236\n#set-window-option -g window-status-current-attr bright\n\nset -g status-interval 60\nset -sg escape-time 1000\nset-option -g base-index 1\nsetw -g aggressive-resize on\nset -g status-justify centre\n#set -g status-left '#[fg=green]#(whoami)@#H#[default]'\nset -g status-left-length 70\nset -g status-left \"#[fg=yellow]#(ifconfig | grep 'inet ' | grep -v 127.0.0.1 | awk '{print \\\"Local \\\" $2}') #[fg=red]#(ifconfig tun0 | grep 'inet ' | awk '{print \\\"vpn \\\" $2}') #(ifconfig ppp0 | grep 'inet ' | awk '{print \\\"vpn \\\" $2}')\"\n# show session name, window & pane number, date and time on right side of status bar\nset -g status-right-length 60\nset -g status-right \"#[fg=blue]#S #I:#P #[fg=yellow]:: %d %b %Y #[fg=green]:: %l:%M %p :: #(date -u | awk '{print $4}')::\"\n# set pane colors - hilight the active pane\n#set-option -g pane-border-fg colour235 #base02\n#set-option -g pane-active-border-fg colour240 #base01\n\n\n# use PREFIX | to split window horizontally and PREFIX - to split vertically\n#bind | split-window -h\n#bind - split-window -v\n\n# Make the current window the first window\n#bind T swap-window -t 1\n\n# and use C-h and C-l to cycle thru panes\n#bind -r C-h select-window -t :-\n#bind -r C-l select-window -t :+\n\n#bind ` copy-mode\n#bind p paste-buffer\n\n# Resize window with alt arrow keys\nbind-key -n C-S-Up resize-pane -U 10\nbind-key -n C-S-Down resize-pane -D 10\nbind-key -n C-S-Left resize-pane -L 10\nbind-key -n C-S-Right resize-pane -R 10\n\n# Rename window with ctrl a r\n#bind-key -r r command-prompt 'rename-window %%'\n\n# Reorder windows\n#bind R                                      \\\n#    move-window -r\\;                        \\\n#    display-message \"Windows reordered...\"\n\n## pane border and colors\n#set-option -g pane-active-border-fg yellow\n#set-option -g pane-border-fg white\n"
  },
  {
    "path": ".vimrc",
    "content": "\" execute pathogen#infect()\nset mouse=\nset ttymouse=\n\" Allow saving of files as sudo when I forgot to start vim using sudo.\ncmap w!! w !sudo tee > /dev/null %\n\n\" Highlight characters over 80\n\"augroup vimrc_autocmds\n\"  autocmd BufEnter * highlight OverLength ctermbg=darkgrey guibg=#111111\n\"  autocmd BufEnter * match OverLength /\\%81v.*/\n\"augroup END\n\n\" Make Vim able to edit crontab files again.\nset backupskip=/tmp/*,/private/tmp/*\nset backup                        \" enable backups\nset noswapfile                    \" it's 2015, Vim.\nset undodir=~/.vim/tmp/undo//     \" undo files\nset backupdir=~/.vim/tmp/backup// \" backups\nset directory=~/.vim/tmp/swap//   \" swap files\n\" Make those folders automatically if they don't already exist.\nif !isdirectory(expand(&undodir))\n    call mkdir(expand(&undodir), \"p\")\nendif\nif !isdirectory(expand(&backupdir))\n    call mkdir(expand(&backupdir), \"p\")\nendif\nif !isdirectory(expand(&directory))\n    call mkdir(expand(&directory), \"p\")\nendif\n\n\" Resize splits when the window is resized\nau VimResized * :wincmd =\n\nset modelines=1\nset showmode\nset history=700\nset undofile\nset undoreload=10000\nset matchtime=3\nset splitbelow\nset splitright\nset autowrite\nset autoread\nset shiftround\nset title\nset linebreak\nset colorcolumn=+1\n\n\" Enable filetype plugins\nfiletype plugin on\nfiletype indent on\n\n\"Always show current position\nset ruler\n\n\"Clipboard stuff\nset clipboard=unnamedplus\n\n\" Height of the command bar\nset cmdheight=2\n\n\" A buffer becomes hidden when it is abandoned\nset hid\n\n\" Configure backspace so it acts as it should act\nset backspace=eol,start,indent\nset whichwrap+=<,>,h,l\n\n\" Ignore case when searching\nset ignorecase\n\n\" When searching try to be smart about cases\nset smartcase\n\n\" Highlight search results\nset hlsearch\n\n\" Makes search act like search in modern browsers\nset incsearch\n\n\" Don't redraw while executing macros (good performance config)\nset lazyredraw\n\n\" For regular expressions turn magic on\nset magic\n\n\" Show matching brackets when text indicator is over them\nset showmatch\n\n\" No annoying sound on errors\nset noerrorbells\nset novisualbell\nset t_vb=\n\n\"http://sunaku.github.io/vim-256color-bce.html\nset t_ut=\nset tm=500\n\n\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\n\" => Colors and Fonts\n\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\n\" Sets 256 color mode if the terminal supports it\nset t_Co=256\n\n\" Enable syntax highlighting\nsyntax enable\n\nset nu\nset background=dark\n\"let g:solarized_termcolors=256\n\" colorscheme brogrammer\n\n\" Set utf8 as standard encoding and en_US as the standard language\nset encoding=utf8\n\n\" Use Unix as the standard file type\nset ffs=unix,dos,mac\n\n\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\n\" => Text, tab and indent related\n\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\n\" Use spaces instead of tabs\nset expandtab\n\n\" Be smart when using tabs ;)\nset smarttab\n\n\" 1 tab == 4 spaces\nset shiftwidth=4\nset tabstop=4\n\n\" Linebreak on 500 characters\nset lbr\nset tw=500\n\nset ai \"Auto indent\nset si \"Smart indent\nset wrap \"Wrap lines\n\n\n\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\n\" => Visual mode related\n\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\n\" Visual mode pressing * or # searches for the current selection\n\" Super useful! From an idea by Michael Naumann\nvnoremap <silent> * :call VisualSelection('f')<CR>\nvnoremap <silent> # :call VisualSelection('b')<CR>\n\n\n\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\n\" => Status line\n\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\n\" Always show the status line\n\"set laststatus=1\n\n\" Format the status line\n\"set statusline=\\ %{HasPaste()}%F%m%r%h\\ %w\\ \\ CWD:\\ %r%{getcwd()}%h\\ \\ \\ Line:\\ %l\n\n\n\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\n\" => Moving around, tabs, windows and buffers\n\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\n\" Resize splits\nmap + <c-w>-\nmap - <c-w>+\nmap > <c-w><\nmap < <c-w>>\n\n\" Close the current buffer\nmap <leader>bd :Bclose<cr>\n\n\" Close all the buffers\nmap <leader>ba :1,1000 bd!<cr>\n\n\" Useful mappings for managing tabs\nmap <leader>tn :tabnew<cr>\nmap <leader>to :tabonly<cr>\nmap <leader>tc :tabclose<cr>\nmap <leader>tm :tabmove\n\n\" Opens a new tab with the current buffer's path\n\" Super useful when editing files in the same directory\nmap <leader>te :tabedit <c-r>=expand(\"%:p:h\")<cr>/\n\n\" Switch CWD to the directory of the open buffer\nmap <leader>cd :cd %:p:h<cr>:pwd<cr>\n\n\" Specify the behavior when switching between buffers\ntry\n  set switchbuf=useopen,usetab,newtab\n  set stal=2\ncatch\nendtry\n\n\" Return to last edit position when opening files (You want this!)\nautocmd BufReadPost *\n     \\ if line(\"'\\\"\") > 0 && line(\"'\\\"\") <= line(\"$\") |\n     \\   exe \"normal! g`\\\"\" |\n     \\ endif\n\" Remember info about open buffers on close\nset viminfo^=%\n\n\" Vim split options\n\" Remaps ctrl w + $key to ctrl $key\n\" ctrl j = move right\nnnoremap <C-J> <C-W><C-J>\n\" ctrl k = move up\nnnoremap <C-K> <C-W><C-K>\n\" ctrl l = move down\nnnoremap <C-L> <C-W><C-L>\n\" ctrl h = move left\nnnoremap <C-H> <C-W><C-H>\n\n\n\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\n\" => Helper functions\n\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\nfunction! CmdLine(str)\n    exe \"menu Foo.Bar :\" . a:str\n    emenu Foo.Bar\n    unmenu Foo\nendfunction\n\nfunction! VisualSelection(direction) range\n    let l:saved_reg = @\"\n    execute \"normal! vgvy\"\n\n    let l:pattern = escape(@\", '\\\\/.*$^~[]')\n    let l:pattern = substitute(l:pattern, \"\\n$\", \"\", \"\")\n\n    if a:direction == 'b'\n        execute \"normal ?\" . l:pattern . \"^M\"\n    elseif a:direction == 'gv'\n        call CmdLine(\"vimgrep \" . '/'. l:pattern . '/' . ' **/*.')\n    elseif a:direction == 'replace'\n        call CmdLine(\"%s\" . '/'. l:pattern . '/')\n    elseif a:direction == 'f'\n        execute \"normal /\" . l:pattern . \"^M\"\n    endif\n\n    let @/ = l:pattern\n    let @\" = l:saved_reg\nendfunction\n\n\n\" Returns true if paste mode is enabled\nfunction! HasPaste()\n    if &paste\n        return 'PASTE MODE  '\n    en\n    return ''\nendfunction\n\n\n\" Trailing whitespace {{{\n\" Only shown when not in insert mode so I don't go insane.\naugroup trailing\n    au!\n    au InsertEnter * :set listchars-=trail:⌴\n    au InsertLeave * :set listchars+=trail:⌴\naugroup END\n\n\" Make sure Vim returns to the same line when you reopen a file.\naugroup line_return\n    au!\n    au BufReadPost *\n        \\ if line(\"'\\\"\") > 0 && line(\"'\\\"\") <= line(\"$\") |\n        \\     execute 'normal! g`\"zvzz' |\n        \\ endif\naugroup END\n\n\" Reselect last-pasted text\nnnoremap gp `[v`]\n\n\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\n\" PATHOGEN PLUGINS \"\n\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\"\n\n\" START NERDTree if no files are specified\nautocmd StdinReadPre * let s:std_in=1\nautocmd VimEnter * if argc() == 0 && !exists(\"s:std_in\") | NERDTree | endif\n\n\" Close NERDTree if it's the only window left open\nautocmd bufenter * if (winnr(\"$\") == 1 && exists(\"b:NERDTreeType\") && b:NERDTreeType == \"primary\") | q | endif\n\n\" https://github.com/nathanaelkane/vim-indent-guides/issues/20\nlet g:indent_guides_exclude_filetypes = ['nerdtree']\n\" END NERDTree\n\n\" START Airline\nlet g:airline#extensions#tabline#enabled = 1\nset laststatus=2\nlet g:airline_theme='murmur'\nlet g:airline#extensions#hunks#enabled=0\nlet g:airline#extensions#branch#enabled=1\n\" END Airline\n\n\" START windowswap\nlet g:windowswap_map_keys = 0 \"prevent default bindings\nnnoremap <silent> <leader>yw :call WindowSwap#MarkWindowSwap()<CR>\nnnoremap <silent> <leader>pw :call WindowSwap#DoWindowSwap()<CR>\nnnoremap <silent> <leader>ww :call WindowSwap#EasyWindowSwap()<CR>\n\" END windowswap\n\n\" START ctrlp\nset runtimepath^=~/.vim/bundle/ctrlp.vim\n\" END ctrlp\n\n\" START ansible-vim\nlet g:ansible_extra_keywords_highlight = 1\nlet g:ansible_name_highlight = 'b'\nlet g:ansible_extra_syntaxes = \"sh.vim\"\n\nfunc! DeleteTrailingWS()\n    exe \"normal mz\"\n    %s/\\s\\+$//ge\n    exe \"normal `z\"\nendfunc\nautocmd BufWrite * :call DeleteTrailingWS()\n\n\" START vim-hclfmt\nlet g:hcl_fmt_autosave = 1\nlet g:tf_fmt_autosave = 0\nlet g:nomad_fmt_autosave = 1\n\" END vim-hclfmt\n\nnmap <silent> <leader><bslash> :call ToggleIndentGuidesSpaces()<cr>\nfunction! ToggleIndentGuidesSpaces()\n\tif exists('b:iguides_spaces')\n\t\tcall matchdelete(b:iguides_spaces)\n\t\tunlet b:iguides_spaces\n\telse\n\t\tlet pos = range(1, &l:textwidth, &l:shiftwidth)\n\t\tcall map(pos, '\"\\\\%\" . v:val . \"v\"')\n\t\tlet pat = '\\%(\\_^\\s*\\)\\@<=\\%(' . join(pos, '\\|') . '\\)\\s'\n\t\tlet b:iguides_spaces = matchadd('CursorLine', pat)\n\tendif\nendfunction\n\n\" START vim-hashicorp-terraform\nlet g:terraform_align = 1\n\" END vim-hashicorp-terraform\n"
  },
  {
    "path": ".zshrc",
    "content": "# ~/.zshrc file for zsh interactive shells.\n# see /usr/share/doc/zsh/examples/zshrc for examples\n\nsetopt autocd              # change directory just by typing its name\n#setopt correct            # auto correct mistakes\nsetopt interactivecomments # allow comments in interactive mode\nsetopt magicequalsubst     # enable filename expansion for arguments of the form ‘anything=expression’\nsetopt nonomatch           # hide error message if there is no match for the pattern\nsetopt notify              # report the status of background jobs immediately\nsetopt numericglobsort     # sort filenames numerically when it makes sense\nsetopt promptsubst         # enable command substitution in prompt\n\nWORDCHARS=${WORDCHARS//\\/} # Don't consider certain characters part of the word\n\n# hide EOL sign ('%')\nPROMPT_EOL_MARK=\"\"\n\n# configure key keybindings\nbindkey -e                                        # emacs key bindings\nbindkey ' ' magic-space                           # do history expansion on space\nbindkey '^U' backward-kill-line                   # ctrl + U\nbindkey '^[[3;5~' kill-word                       # ctrl + Supr\nbindkey '^[[3~' delete-char                       # delete\nbindkey '^[[1;5C' forward-word                    # ctrl + ->\nbindkey '^[[1;5D' backward-word                   # ctrl + <-\nbindkey '^[[5~' beginning-of-buffer-or-history    # page up\nbindkey '^[[6~' end-of-buffer-or-history          # page down\nbindkey '^[[H' beginning-of-line                  # home\nbindkey '^[[F' end-of-line                        # end\nbindkey '^[[Z' undo                               # shift + tab undo last action\n\n# enable completion features\nautoload -Uz compinit\ncompinit -d ~/.cache/zcompdump\nzstyle ':completion:*:*:*:*:*' menu select\nzstyle ':completion:*' auto-description 'specify: %d'\nzstyle ':completion:*' completer _expand _complete\nzstyle ':completion:*' format 'Completing %d'\nzstyle ':completion:*' group-name ''\nzstyle ':completion:*' list-colors ''\nzstyle ':completion:*' list-prompt %SAt %p: Hit TAB for more, or the character to insert%s\nzstyle ':completion:*' matcher-list 'm:{a-zA-Z}={A-Za-z}'\nzstyle ':completion:*' rehash true\nzstyle ':completion:*' select-prompt %SScrolling active: current selection at %p%s\nzstyle ':completion:*' use-compctl false\nzstyle ':completion:*' verbose true\nzstyle ':completion:*:kill:*' command 'ps -u $USER -o pid,%cpu,tty,cputime,cmd'\n\n# History configurations\nHISTFILE=~/.zsh_history\nHISTSIZE=1000\nSAVEHIST=2000\nsetopt hist_expire_dups_first # delete duplicates first when HISTFILE size exceeds HISTSIZE\nsetopt hist_ignore_dups       # ignore duplicated commands history list\nsetopt hist_ignore_space      # ignore commands that start with space\nsetopt hist_verify            # show command with history expansion to user before running it\n#setopt share_history         # share command history data\n\n# force zsh to show the complete history\nalias history=\"history 0\"\n\n# configure `time` format\nTIMEFMT=$'\\nreal\\t%E\\nuser\\t%U\\nsys\\t%S\\ncpu\\t%P'\n\n# make less more friendly for non-text input files, see lesspipe(1)\n#[ -x /usr/bin/lesspipe ] && eval \"$(SHELL=/bin/sh lesspipe)\"\n\n# set variable identifying the chroot you work in (used in the prompt below)\nif [ -z \"${debian_chroot:-}\" ] && [ -r /etc/debian_chroot ]; then\n    debian_chroot=$(cat /etc/debian_chroot)\nfi\n\n# set a fancy prompt (non-color, unless we know we \"want\" color)\ncase \"$TERM\" in\n    xterm-color|*-256color) color_prompt=yes;;\nesac\n\n# uncomment for a colored prompt, if the terminal has the capability; turned\n# off by default to not distract the user: the focus in a terminal window\n# should be on the output of commands, not on the prompt\nforce_color_prompt=yes\n\nif [ -n \"$force_color_prompt\" ]; then\n    if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then\n        # We have color support; assume it's compliant with Ecma-48\n        # (ISO/IEC-6429). (Lack of such support is extremely rare, and such\n        # a case would tend to support setf rather than setaf.)\n        color_prompt=yes\n    else\n        color_prompt=\n    fi\nfi\n\nconfigure_prompt() {\n    prompt_symbol=😈\n    # Skull emoji for root terminal\n    #[ \"$EUID\" -eq 0 ] && prompt_symbol=💀\n    case \"$PROMPT_ALTERNATIVE\" in\n        twoline)\n            PROMPT=$'%F{%(#.blue.green)}┌──${debian_chroot:+($debian_chroot)─}${VIRTUAL_ENV:+($(basename $VIRTUAL_ENV))─}(%B%F{%(#.red.blue)}%n'$prompt_symbol$'%m%b%F{%(#.blue.green)})-[%B%F{reset}%(6~.%-1~/…/%4~.%5~)%b%F{%(#.blue.green)}]\\n└─%B%(#.%F{red}#.%F{blue}$)%b%F{reset} '\n            # Right-side prompt with exit codes and background processes\n            #RPROMPT=$'%(?.. %? %F{red}%B⨯%b%F{reset})%(1j. %j %F{yellow}%B⚙%b%F{reset}.)'\n            ;;\n        oneline)\n            PROMPT=$'${debian_chroot:+($debian_chroot)}${VIRTUAL_ENV:+($(basename $VIRTUAL_ENV))}%B%F{%(#.red.blue)}%n@%m%b%F{reset}:%B%F{%(#.blue.green)}%~%b%F{reset}%(#.#.$) '\n            RPROMPT=\n            ;;\n        backtrack)\n            PROMPT=$'${debian_chroot:+($debian_chroot)}${VIRTUAL_ENV:+($(basename $VIRTUAL_ENV))}%B%F{red}%n@%m%b%F{reset}:%B%F{blue}%~%b%F{reset}%(#.#.$) '\n            RPROMPT=\n            ;;\n    esac\n    unset prompt_symbol\n}\n\n# The following block is surrounded by two delimiters.\n# These delimiters must not be modified. Thanks.\n# START KALI CONFIG VARIABLES\nPROMPT_ALTERNATIVE=twoline\nNEWLINE_BEFORE_PROMPT=yes\n# STOP KALI CONFIG VARIABLES\n\nif [ \"$color_prompt\" = yes ]; then\n    # override default virtualenv indicator in prompt\n    VIRTUAL_ENV_DISABLE_PROMPT=1\n\n    configure_prompt\n\n    # enable syntax-highlighting\n    if [ -f /usr/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh ]; then\n        . /usr/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh\n        ZSH_HIGHLIGHT_HIGHLIGHTERS=(main brackets pattern)\n        ZSH_HIGHLIGHT_STYLES[default]=none\n        ZSH_HIGHLIGHT_STYLES[unknown-token]=underline\n        ZSH_HIGHLIGHT_STYLES[reserved-word]=fg=cyan,bold\n        ZSH_HIGHLIGHT_STYLES[suffix-alias]=fg=green,underline\n        ZSH_HIGHLIGHT_STYLES[global-alias]=fg=green,bold\n        ZSH_HIGHLIGHT_STYLES[precommand]=fg=green,underline\n        ZSH_HIGHLIGHT_STYLES[commandseparator]=fg=blue,bold\n        ZSH_HIGHLIGHT_STYLES[autodirectory]=fg=green,underline\n        ZSH_HIGHLIGHT_STYLES[path]=bold\n        ZSH_HIGHLIGHT_STYLES[path_pathseparator]=\n        ZSH_HIGHLIGHT_STYLES[path_prefix_pathseparator]=\n        ZSH_HIGHLIGHT_STYLES[globbing]=fg=blue,bold\n        ZSH_HIGHLIGHT_STYLES[history-expansion]=fg=blue,bold\n        ZSH_HIGHLIGHT_STYLES[command-substitution]=none\n        ZSH_HIGHLIGHT_STYLES[command-substitution-delimiter]=fg=magenta,bold\n        ZSH_HIGHLIGHT_STYLES[process-substitution]=none\n        ZSH_HIGHLIGHT_STYLES[process-substitution-delimiter]=fg=magenta,bold\n        ZSH_HIGHLIGHT_STYLES[single-hyphen-option]=fg=green\n        ZSH_HIGHLIGHT_STYLES[double-hyphen-option]=fg=green\n        ZSH_HIGHLIGHT_STYLES[back-quoted-argument]=none\n        ZSH_HIGHLIGHT_STYLES[back-quoted-argument-delimiter]=fg=blue,bold\n        ZSH_HIGHLIGHT_STYLES[single-quoted-argument]=fg=yellow\n        ZSH_HIGHLIGHT_STYLES[double-quoted-argument]=fg=yellow\n        ZSH_HIGHLIGHT_STYLES[dollar-quoted-argument]=fg=yellow\n        ZSH_HIGHLIGHT_STYLES[rc-quote]=fg=magenta\n        ZSH_HIGHLIGHT_STYLES[dollar-double-quoted-argument]=fg=magenta,bold\n        ZSH_HIGHLIGHT_STYLES[back-double-quoted-argument]=fg=magenta,bold\n        ZSH_HIGHLIGHT_STYLES[back-dollar-quoted-argument]=fg=magenta,bold\n        ZSH_HIGHLIGHT_STYLES[assign]=none\n        ZSH_HIGHLIGHT_STYLES[redirection]=fg=blue,bold\n        ZSH_HIGHLIGHT_STYLES[comment]=fg=black,bold\n        ZSH_HIGHLIGHT_STYLES[named-fd]=none\n        ZSH_HIGHLIGHT_STYLES[numeric-fd]=none\n        ZSH_HIGHLIGHT_STYLES[arg0]=fg=cyan\n        ZSH_HIGHLIGHT_STYLES[bracket-error]=fg=red,bold\n        ZSH_HIGHLIGHT_STYLES[bracket-level-1]=fg=blue,bold\n        ZSH_HIGHLIGHT_STYLES[bracket-level-2]=fg=green,bold\n        ZSH_HIGHLIGHT_STYLES[bracket-level-3]=fg=magenta,bold\n        ZSH_HIGHLIGHT_STYLES[bracket-level-4]=fg=yellow,bold\n        ZSH_HIGHLIGHT_STYLES[bracket-level-5]=fg=cyan,bold\n        ZSH_HIGHLIGHT_STYLES[cursor-matchingbracket]=standout\n    fi\nelse\n    PROMPT='${debian_chroot:+($debian_chroot)}%n@%m:%~%(#.#.$) '\nfi\nunset color_prompt force_color_prompt\n\ntoggle_oneline_prompt(){\n    if [ \"$PROMPT_ALTERNATIVE\" = oneline ]; then\n        PROMPT_ALTERNATIVE=twoline\n    else\n        PROMPT_ALTERNATIVE=oneline\n    fi\n    configure_prompt\n    zle reset-prompt\n}\nzle -N toggle_oneline_prompt\nbindkey ^P toggle_oneline_prompt\n\n# If this is an xterm set the title to user@host:dir\ncase \"$TERM\" in\nxterm*|rxvt*|Eterm|aterm|kterm|gnome*|alacritty)\n    TERM_TITLE=$'\\e]0;${debian_chroot:+($debian_chroot)}${VIRTUAL_ENV:+($(basename $VIRTUAL_ENV))}%n@%m: %~\\a'\n    ;;\n*)\n    ;;\nesac\n\nprecmd() {\n    # Print the previously configured title\n    print -Pnr -- \"$TERM_TITLE\"\n\n    # Print a new line before the prompt, but only if it is not the first line\n    if [ \"$NEWLINE_BEFORE_PROMPT\" = yes ]; then\n        if [ -z \"$_NEW_LINE_BEFORE_PROMPT\" ]; then\n            _NEW_LINE_BEFORE_PROMPT=1\n        else\n            print \"\"\n        fi\n    fi\n}\n\n# enable color support of ls, less and man, and also add handy aliases\nif [ -x /usr/bin/dircolors ]; then\n    test -r ~/.dircolors && eval \"$(dircolors -b ~/.dircolors)\" || eval \"$(dircolors -b)\"\n    export LS_COLORS=\"$LS_COLORS:ow=30;44:\" # fix ls color for folders with 777 permissions\n\n    alias ls='ls --color=auto'\n    #alias dir='dir --color=auto'\n    #alias vdir='vdir --color=auto'\n\n    alias grep='grep --color=auto'\n    alias fgrep='fgrep --color=auto'\n    alias egrep='egrep --color=auto'\n    alias diff='diff --color=auto'\n    alias ip='ip --color=auto'\n\n    export LESS_TERMCAP_mb=$'\\E[1;31m'     # begin blink\n    export LESS_TERMCAP_md=$'\\E[1;36m'     # begin bold\n    export LESS_TERMCAP_me=$'\\E[0m'        # reset bold/blink\n    export LESS_TERMCAP_so=$'\\E[01;33m'    # begin reverse video\n    export LESS_TERMCAP_se=$'\\E[0m'        # reset reverse video\n    export LESS_TERMCAP_us=$'\\E[1;32m'     # begin underline\n    export LESS_TERMCAP_ue=$'\\E[0m'        # reset underline\n\n    # Take advantage of $LS_COLORS for completion as well\n    zstyle ':completion:*' list-colors \"${(s.:.)LS_COLORS}\"\n    zstyle ':completion:*:*:kill:*:processes' list-colors '=(#b) #([0-9]#)*=0=01;31'\nfi\n\n# some more ls aliases\nalias ll='ls -l'\nalias la='ls -A'\nalias l='ls -CF'\n\n# enable auto-suggestions based on the history\nif [ -f /usr/share/zsh-autosuggestions/zsh-autosuggestions.zsh ]; then\n    . /usr/share/zsh-autosuggestions/zsh-autosuggestions.zsh\n    # change suggestion color\n    ZSH_AUTOSUGGEST_HIGHLIGHT_STYLE='fg=#999'\nfi\n\n# enable command-not-found if installed\nif [ -f /etc/zsh_command_not_found ]; then\n    . /etc/zsh_command_not_found\nfi\n\n"
  },
  {
    "path": "README.md",
    "content": "# Installation\n### Download and change folder\n```\ncd ~\ngit clone https://github.com/flipsidecreations/dotfiles.git\n\ncd dotfiles\n```\n### Run install\n```\n./install.sh\n```\n\n# Uninstallation\n\n### Change to dotfiles folder\n```\ncd ~/dotfiles\n```\n\n### Run uninstaller\n```\n./uninstall.sh\n```\n"
  },
  {
    "path": "install.sh",
    "content": "#!/bin/bash\n\n# Find all dot files then if the original file exists, create a backup\n# Once backed up to {file}.dtbak symlink the new dotfile in place\nfor file in $(find . -maxdepth 1 -name \".*\" -type f  -printf \"%f\\n\" ); do\n    if [ -e ~/$file ]; then\n        mv -f ~/$file{,.dtbak}\n    fi\n    ln -s $PWD/$file ~/$file\ndone\n\n# Install  vim-addons ZSH and ZSH extras\n    echo \"installing extras\"\n    sudo apt update && sudo apt -y install vim-scripts zsh zsh-syntax-highlighting zsh-autosuggestions\n\necho \"Installed\"\necho \"use chsh -s /bin/zsh to switch to ZSH shell\"\n\n\n"
  },
  {
    "path": "uninstall.sh",
    "content": "#!/bin/bash\n\n# Loop through all the dotfiles, if the file is a symlink then remove it\n# Then if the backup file exists, restore it to it's original location\nfor file in $(find . -maxdepth 1 -name \".*\" -type f  -printf \"%f\\n\" ); do\n    if [ -h ~/$file ]; then\n        rm -f ~/$file\n    fi\n    if [ -e ~/${file}.dtbak ]; then\n        mv -f ~/$file{.dtbak,}\n    fi\ndone\n\necho \"Uninstalled\"\n"
  }
]