├── .ackrc ├── .ctags ├── .tmux.conf ├── README.md ├── .bash_aliases ├── .bashrc.local └── .vimrc /.ackrc: -------------------------------------------------------------------------------- 1 | --ignore-file=is:tags 2 | --ignore-dir=tmp 3 | --ignore-dir=_site 4 | --ignore-dir=build 5 | --ignore-dir=.ipynb_checkpoints 6 | --ignore-dir=.build 7 | -------------------------------------------------------------------------------- /.ctags: -------------------------------------------------------------------------------- 1 | --extra=+f 2 | --recurse=yes 3 | --exclude=.git 4 | --exclude=vendor/* 5 | --exclude=node_modules/* 6 | --exclude=db/* 7 | --exclude=log/* 8 | --python-kinds=-iv 9 | --exclude=build 10 | --exclude=dist 11 | 12 | -------------------------------------------------------------------------------- /.tmux.conf: -------------------------------------------------------------------------------- 1 | set -g default-terminal "screen-256color" 2 | set-window-option -g mode-keys vi 3 | 4 | set-option -g mouse on 5 | set-option -g history-limit 5000 6 | 7 | unbind P 8 | bind-key P command-prompt -p 'save history to filename:' -I '~/tmux.history' 'capture-pane -S - ; save-buffer %1 ; delete-buffer' 9 | 10 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | I suggest you create a fork of this, so you can modify it. 2 | 3 | The approach used here is from https://developer.atlassian.com/blog/2016/02/best-way-to-store-dotfiles-git-bare-repo/ 4 | 5 | To set this up on your machine, use this script: https://github.com/fastai/fastsetup/blob/master/dotfiles.sh 6 | 7 | In that script, change `https://github.com/fastai/dotfiles.git` to your fork, before you run it. 8 | -------------------------------------------------------------------------------- /.bash_aliases: -------------------------------------------------------------------------------- 1 | commit () { git commit -am "${1}" && git push; } 2 | fixes () { git commit -am "fixes #${1}" && git push; } 3 | 4 | alias a=alias 5 | 6 | a issues="gh issue list" 7 | a issue="gh issue create" 8 | a enhancement="gh issue create -l enhancement -b '' -t" 9 | a bug="gh issue create -l bug -b '' -t" 10 | a breaking="gh issue create -l breaking -b '' -t" 11 | a note="gh issue -R jph00/notes create" 12 | 13 | alias gitssh="perl -pi -e 's#https://github\.com/#git\@github.com:# if /\[remote \"origin/../fetch =/' .git/config" 14 | 15 | a minst="mamba install -c defaults" 16 | 17 | -------------------------------------------------------------------------------- /.bashrc.local: -------------------------------------------------------------------------------- 1 | stty -ixon 2 | shopt -s globstar 3 | 4 | parse_git_branch() { b=$(git branch --show-current 2> /dev/null); echo ${b:+" ($b)"}; } 5 | PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]$(parse_git_branch)\[\033[00m\]\$ ' 6 | 7 | [ -f ~/.bash_aliases ] && . ~/.bash_aliases 8 | [ -f ~/.secrets ] && . ~/.secrets 9 | 10 | alias config="/usr/bin/git --git-dir=$HOME/.cfg/ --work-tree=$HOME" 11 | export VISUAL=vim 12 | export EDITOR="$VISUAL" 13 | export PERL_MM_USE_DEFAULT=1 14 | 15 | export GEM_HOME="$HOME/gems" 16 | export PATH="$HOME/gems/bin:$PATH" 17 | 18 | tarz () { tar -I pigz -cf $1.tgz $1; } 19 | commit () { git commit -am "${1}"; git push; } 20 | fixes () { git commit -am "fixes #${1}"; git push; } 21 | 22 | git_clone_all () { 23 | cd ~/git 24 | parallel -a repos 'git clone git@github.com:fastai/{}.git' 25 | cd - 26 | } 27 | 28 | git_pull_all () { 29 | pushd ~/git 30 | parallel -a repos 'echo " # {}" && cd ~/git/{} && git pull' 31 | popd 32 | } 33 | 34 | git_status_rel () { 35 | pushd ~/git 36 | parallel -a releases 'echo " # {}" && cd ~/git/{} && git status' 37 | popd 38 | } 39 | 40 | vibash () { 41 | vim ~/.bashrc 42 | . ~/.bashrc 43 | } 44 | 45 | vibashl () { 46 | vim ~/.bashrc.local 47 | . ~/.bashrc 48 | } 49 | 50 | eval "$(gh completion -s bash)" 51 | -------------------------------------------------------------------------------- /.vimrc: -------------------------------------------------------------------------------- 1 | unlet! skip_defaults_vim 2 | source $VIMRUNTIME/defaults.vim 3 | packadd! matchit 4 | 5 | set background=light 6 | "color slate 7 | let &t_ti.="\e[1 q" 8 | let &t_SI.="\e[5 q" 9 | let &t_EI.="\e[1 q" 10 | let &t_te.="\e[0 q" 11 | 12 | filetype off 13 | 14 | set ttyfast 15 | set mouse=a 16 | set t_Co=256 17 | 18 | "set foldcolumn=3 19 | 20 | set rtp+=~/.vim/bundle/Vundle.vim 21 | call vundle#begin() 22 | 23 | Plugin 'VundleVim/Vundle.vim' 24 | Plugin 'tmhedberg/SimpylFold' 25 | let g:SimpylFold_docstring_preview=1 26 | 27 | Plugin 'tpope/vim-repeat' 28 | Plugin 'tpope/vim-dispatch' 29 | Plugin 'tpope/vim-eunuch' 30 | Plugin 'tpope/vim-surround' 31 | Plugin 'tpope/vim-fugitive' 32 | Plugin 'jph00/swift-apple' 33 | 34 | "Plugin 'janko-m/vim-test' 35 | "nmap t :TestNearest 36 | "nmap T :TestFile 37 | "nmap a :TestSuite 38 | "nmap l :TestLast 39 | "nmap g :TestVisit 40 | 41 | Plugin 'jeetsukumaran/vim-indentwise' 42 | Plugin 'vim-scripts/indentpython.vim' 43 | "Plugin 'Konfekt/FastFold' 44 | 45 | call vundle#end() " required 46 | filetype plugin indent on 47 | 48 | let python_highlight_all=1 49 | syntax on 50 | set encoding=utf-8 51 | 52 | set backupdir=~/vimfiles/tmp,. 53 | set directory=~/vimfiles/tmp,. 54 | 55 | set pastetoggle= 56 | set tabstop=8 softtabstop=0 expandtab shiftwidth=2 smarttab autoindent fileformat=unix 57 | set fo-=t 58 | au BufNewFile,BufRead *.py set shiftwidth=4 textwidth=119 59 | "setlocal foldmethod=expr 60 | set list 61 | set listchars=tab:>- 62 | set display+=lastline 63 | set incsearch 64 | 65 | let mapleader = "\\" 66 | map ve :sp $HOME/.vimrc 67 | map vs :source $HOME/.vimrc 68 | 69 | map g] :stj 70 | map = = 71 | map _ 72 | map _ 73 | map _ 74 | map 1 99_ 75 | map 2 991j_ 76 | map 3 992j_ 77 | map 4 993j_ 78 | map 5 994j_ 79 | map d Oimport pdb; pdb.set_trace()^[ 80 | 81 | "split navigations 82 | nnoremap 83 | nnoremap 84 | nnoremap 85 | nnoremap 86 | nnoremap g 87 | 88 | " Press Enter to highlight current word 89 | let g:highlighting = 0 90 | function! Highlighting() 91 | if g:highlighting == 1 && @/ =~ '^\\<'.expand('').'\\>$' 92 | let g:highlighting = 0 93 | return ":silent nohlsearch\" 94 | endif 95 | let @/ = '\<'.expand('').'\>' 96 | let g:highlighting = 1 97 | return ":silent set hlsearch\" 98 | endfunction 99 | nnoremap Highlighting() 100 | 101 | --------------------------------------------------------------------------------