From 73d843245d18448826ceba9b084abb970baad4c2 Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Sat, 27 Apr 2013 20:54:03 -0400 Subject: [PATCH 01/28] Initial commit --- bashrc | 190 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++ vimrc | 41 +++++++++++++ 2 files changed, 231 insertions(+) create mode 100644 bashrc create mode 100644 vimrc diff --git a/bashrc b/bashrc new file mode 100644 index 0000000..e5cf190 --- /dev/null +++ b/bashrc @@ -0,0 +1,190 @@ +# ~/.bashrc: executed by bash(1) for non-login shells. +# see /usr/share/doc/bash/examples/startup-files (in the package bash-doc) +# for examples + +# If not running interactively, don't do anything +[ -z "$PS1" ] && return + +# don't put duplicate lines in the history. See bash(1) for more options +# don't overwrite GNU Midnight Commander's setting of `ignorespace'. +HISTCONTROL=$HISTCONTROL${HISTCONTROL+,}ignoredups +# ... or force ignoredups and ignorespace +HISTCONTROL=ignoreboth + +# Add Ruby gem bin directory to the system path +PATH=/var/lib/gems/1.8/bin:$PATH + +# Add home folder's bin to the system path +PATH=~/bin:$PATH + +# Add the Android SDK's tools directory to the system path +PATH=/usr/local/android/tools:$PATH + +# Add the go bin directory to the system path +PATH=/usr/local/go/bin:$PATH + +# Add the lessc bin directory to the system path +PATH=~/node_modules/less/bin:$PATH + +# append to the history file, don't overwrite it +shopt -s histappend + +# for setting history length see HISTSIZE and HISTFILESIZE in bash(1) + +# check the window size after each command and, if necessary, +# update the values of LINES and COLUMNS. +shopt -s checkwinsize + +# make less more friendly for non-text input files, see lesspipe(1) +[ -x /usr/bin/lesspipe ] && eval "$(SHELL=/bin/sh lesspipe)" + +# set variable identifying the chroot you work in (used in the prompt below) +if [ -z "$debian_chroot" ] && [ -r /etc/debian_chroot ]; then + debian_chroot=$(cat /etc/debian_chroot) +fi + +# Make the terminal by default xterm-256color +export TERM=xterm-256color + +# set a fancy prompt (non-color, unless we know we "want" color) +case "$TERM" in + xterm-color) color_prompt=yes;; +esac + +# uncomment for a colored prompt, if the terminal has the capability; turned +# off by default to not distract the user: the focus in a terminal window +# should be on the output of commands, not on the prompt +force_color_prompt=yes + +if [ -n "$force_color_prompt" ]; then + if [ -x /usr/bin/tput ] && tput setaf 1 >&/dev/null; then + # We have color support; assume it's compliant with Ecma-48 + # (ISO/IEC-6429). (Lack of such support is extremely rare, and such + # a case would tend to support setf rather than setaf.) + color_prompt=yes + else + color_prompt= + fi +fi + +if [ "$color_prompt" = yes ]; then + PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ ' +else + PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ ' +fi +unset color_prompt force_color_prompt + +# If this is an xterm set the title to user@host:dir +case "$TERM" in + xterm*|rxvt*) + PS1="\[\e]0;${debian_chroot:+($debian_chroot)}\u@\h: \w\a\]$PS1" + ;; + *) + ;; +esac + +# enable color support of ls and also add handy aliases +if [ -x /usr/bin/dircolors ]; then + test -r ~/.dircolors && eval "$(dircolors -b ~/.dircolors)" || eval "$(dircolors -b)" + alias ls='ls --color=auto' + #alias dir='dir --color=auto' + #alias vdir='vdir --color=auto' + + alias grep='grep --color=auto' + alias fgrep='fgrep --color=auto' + alias egrep='egrep --color=auto' +fi + +# Set up a local ssh-agent if necessary. +SSHAGENT=/usr/bin/ssh-agent +SSHAGENTARGS="-s" +SSHADDARGS="~/.ssh/id_rsa-jj@geewax.org" +if [ -z "$SSH_AUTH_SOCK" -a -x "$SSHAGENT" ]; then + eval `$SSHAGENT $SSHAGENTARGS` + trap "kill $SSH_AGENT_PID" 0 +fi + +# Make the first call to SSH (on an empty agent) add the key to the agent. +ssh-add -l >/dev/null || \ + alias ssh="ssh-add -l >/dev/null || ssh-add $SSHADDARGS && unalias ssh; ssh" + +# some more ls aliases +#alias ll='ls -l' +#alias la='ls -A' +#alias l='ls -CF' + +# Alias definitions. +# You may want to put all your additions into a separate file like +# ~/.bash_aliases, instead of adding them here directly. +# See /usr/share/doc/bash-doc/examples in the bash-doc package. + +if [ -f ~/.bash_aliases ]; then + . ~/.bash_aliases +fi + +# enable programmable completion features (you don't need to enable +# this, if it's already enabled in /etc/bash.bashrc and /etc/profile +# sources /etc/bash.bashrc). +if [ -f /etc/bash_completion ] && ! shopt -oq posix; then + . /etc/bash_completion +fi + +# Git stuff +get_branch() { + git branch 2> /dev/null | grep \* | awk '{print "("$2")"}' +} + +# Default PS1 +#PS1="\[\033[01;34m\]\$(get_repository)\[\033[31m\]\$(get_branch)\[\033[37m\]\[\033[00m\]\[\033[38m\]\u@\h:\w$ " +PS1="\[\033[31m\]\$(get_branch)\[\033[37m\]\[\033[00m\]\[\033[38m\]\u@\h:\w$ " + +# tmux attach utility (https://github.com/ryandotsmith/tat/) +export CODE_ROOT_DIRS=~/projects/:~/playground/ +tat() { + local session_name="$1" + local sessions=( $(tmux list-sessions 2>/dev/null | cut -d ":" -f 1 | grep "^$session_name$") ) + + if [ ${#sessions[@]} -gt 0 ]; then + # If there is already a session with the same name, attach to it. + tmux attach-session -d -t "$session_name" + else + # If there is no existing session, create a new (detached) one. + tmux new-session -d -s "$session_name" + + # Try to find a matching code directory. + local code_root_dirs=$(echo $CODE_ROOT_DIRS | sed 's/:/ /g') + local matching_dirs=( $(find $code_root_dirs -maxdepth 1 -name "$session_name" -type d ) ) + + # If there is a matching directory, set it as the default path. + if [ ${#matching_dirs[@]} -gt 0 ]; then + local code_dir=${matching_dirs[0]} + tmux set default-path "$code_dir" 1>/dev/null + tmux send-keys -t "$session_name:1" "cd $code_dir && clear" C-m + + # Check if there is a .tmux file in this directory. + if [ -f "$code_dir/.tmux" ]; then + echo "there is a tmux file, executing" + eval "$code_dir/.tmux" $session_name + fi + fi + + # Finally, attach to the newly created session. + tmux attach-session -t "$session_name" + fi +} + +_tat() { + COMPREPLY=() + local session="${COMP_WORDS[COMP_CWORD]}" + local code_root_dirs=$(echo $CODE_ROOT_DIRS | sed 's/:/ /g') + local sessions=( $(compgen -W "$(tmux list-sessions 2>/dev/null | awk -F: '{ print $1 }')" -- "$session") ) + local directories=( $( + for dir in $code_root_dirs; do + cd "$dir" 2 >/dev/null && compgen -d -- "$session" + done + ) ) + COMPREPLY=( ${sessions[@]} ${directories[@]} ) +} + +complete -o filenames -o nospace -F _tat tat + diff --git a/vimrc b/vimrc new file mode 100644 index 0000000..52da5ce --- /dev/null +++ b/vimrc @@ -0,0 +1,41 @@ +" Pathogen +execute pathogen#infect() + +filetype plugin indent on + +set nocompatible +set ruler +set mouse=a +set noerrorbells +set listchars=tab:>-,trail:- +set number +set numberwidth=3 + +set autoindent +set tabstop=2 +set shiftwidth=2 +set expandtab + +" Indentation guidelines (vim-indent-guides) +colorscheme default +hi IndentGuidesOdd ctermbg=0 +hi IndentGuidesEven ctermbg=234 +let g:indent_guides_start_level = 2 +let g:indent_guides_guide_size = 1 +let g:indent_guides_auto_colors = 0 +let g:indent_guides_enable_on_vim_startup = 1 + +" Wildmenu +if has("wildmenu") + set wildignore+=*.a,*.o,*.pyc + set wildignore+=*.bmp,*.gif,*.ico,*.jpg,*.png + set wildignore+=.DS_Store,.git,.hg,.svn + set wildignore+=*~,*.swp,*.tmp + set wildmenu + set wildmode=longest,list,full +endif + +" Highlight trailing whitespace +highlight ExtraWhitespace ctermbg=red guibg=red +autocmd BufWinEnter * match ExtraWhitespace /\s\+$/ + From e41143fbee182cc3cdc09545abafef29fd45474d Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Sat, 27 Apr 2013 20:58:13 -0400 Subject: [PATCH 02/28] Added comments to which bundles I had installed. --- vimrc | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/vimrc b/vimrc index 52da5ce..b6c392e 100644 --- a/vimrc +++ b/vimrc @@ -1,6 +1,13 @@ " Pathogen execute pathogen#infect() +" My plugins include: +" +" vim-coffee-script +" vim-indent-guides +" vim-less +" vim-stylus + filetype plugin indent on set nocompatible @@ -38,4 +45,3 @@ endif " Highlight trailing whitespace highlight ExtraWhitespace ctermbg=red guibg=red autocmd BufWinEnter * match ExtraWhitespace /\s\+$/ - From d79c2f2ad13ed592416315876ea8be6ed6faec11 Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Fri, 17 Jan 2014 15:57:45 -0500 Subject: [PATCH 03/28] Added tmux.conf --- tmux.conf | 91 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 91 insertions(+) create mode 100644 tmux.conf diff --git a/tmux.conf b/tmux.conf new file mode 100644 index 0000000..6ea29fe --- /dev/null +++ b/tmux.conf @@ -0,0 +1,91 @@ +# Leader key should be the same as screen (C-a) +set -g prefix C-a + +# Double tap to go to previous window +bind C-a last-window + +# Splitting windows should use | and - +unbind % +bind | split-window -h +bind - split-window -v + +# r should reload the local tmux configuration file +bind r source-file ~/.tmux.conf + +# A should prompt to rename the window like screen +unbind A +bind A command-prompt "rename-window %%" + +# C-left and C-right moves between windows +bind-key -n C-right next +bind-key -n C-left prev +bind C-n next +bind C-p previous-window + +# / Prompts for a command to show as a man page in separate pane +bind / command-prompt "split-window 'exec man %%'" + +# Scrollback buffer +set -g history-limit 5000 + +# Listen for activity on all windows +set -g bell-action any + +# On-screen time for display-panes in ms +set -g display-panes-time 2000 + +# Start window indexing at one instead of zero +set -g base-index 1 + +# Wm window titles +set -g set-titles on + +# Wm window title string (uses statusbar variables) +set -g set-titles-string "tmux.#S.#I.#W" + +# Mouse mode should be on +set -g mode-mouse on +set -g mouse-resize-pane on +set -g mouse-select-pane on +set -g mouse-select-window on + +# Make sure we're supporting 256 color mode. +set -g default-terminal "screen-256color" + +# Status bar settings +set -g status-bg "#333333" +set -g status-fg "#ffff00" +set -g status-attr default +set -g status-justify centre +set -g status-interval 60 +set -g status-left " #S #[fg=white]on #[fg=green]#H #[default]" +set -g status-left-length 30 +set -g status-right "#[fg=green]%a %Y-%m-%d %H:%M " +set -g status-right-length 50 +bind-key b set-option status + +# Window title colors +set-window-option -g window-status-fg "#888888" # Light-ish grey +set-window-option -g window-status-bg default +set-window-option -g window-status-attr dim + +# Active window title colors +set-window-option -g window-status-current-fg "#ff3300" # Orange +set-window-option -g window-status-current-bg default +set-window-option -g window-status-current-attr bright + +# Pane border style and color +set -g pane-border-fg colour235 #base02 +set -g pane-active-border-fg colour240 #base01 + +# Message text +set -g message-bg colour235 #base02 +set -g message-fg colour166 #orange + +# Pane number display colors +set -g display-panes-active-colour colour33 #blue +set -g display-panes-colour colour166 #orange + +# Clock settings +setw -g clock-mode-style 24 + From 4a5553f8710b14efe87e747af9ee9d46c73c7fec Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Sun, 8 Jun 2014 11:28:40 +0800 Subject: [PATCH 04/28] Made sure that CODE_ROOT_DIRS exist for tat. --- bashrc | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/bashrc b/bashrc index e5cf190..6eeafcd 100644 --- a/bashrc +++ b/bashrc @@ -26,6 +26,9 @@ PATH=/usr/local/go/bin:$PATH # Add the lessc bin directory to the system path PATH=~/node_modules/less/bin:$PATH +# Add Dart SDK to the system path +PATH=/opt/dart-sdk/bin:$PATH + # append to the history file, don't overwrite it shopt -s histappend @@ -140,6 +143,12 @@ PS1="\[\033[31m\]\$(get_branch)\[\033[37m\]\[\033[00m\]\[\033[38m\]\u@\h:\w$ " # tmux attach utility (https://github.com/ryandotsmith/tat/) export CODE_ROOT_DIRS=~/projects/:~/playground/ +# Make sure the directories exist. +( IFS=: + for d in $CODE_ROOT_DIRS; do + mkdir -p $d + done +) tat() { local session_name="$1" local sessions=( $(tmux list-sessions 2>/dev/null | cut -d ":" -f 1 | grep "^$session_name$") ) @@ -187,4 +196,3 @@ _tat() { } complete -o filenames -o nospace -F _tat tat - From 6670c9e9ec1ac601402c6a58172a1db5611d89af Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Sun, 8 Jun 2014 11:38:28 +0800 Subject: [PATCH 05/28] Rename tmux.conf to .tmux.conf --- tmux.conf => .tmux.conf | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename tmux.conf => .tmux.conf (100%) diff --git a/tmux.conf b/.tmux.conf similarity index 100% rename from tmux.conf rename to .tmux.conf From ca2828439a301f632718cb16e974a3434cfdedb4 Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Sun, 8 Jun 2014 11:38:41 +0800 Subject: [PATCH 06/28] Rename bashrc to .bashrc --- bashrc => .bashrc | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename bashrc => .bashrc (100%) diff --git a/bashrc b/.bashrc similarity index 100% rename from bashrc rename to .bashrc From f2a973e81fc0652d3e39651e3b58eb56cd35b234 Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Sun, 8 Jun 2014 11:38:50 +0800 Subject: [PATCH 07/28] Rename vimrc to .vimrc --- vimrc => .vimrc | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename vimrc => .vimrc (100%) diff --git a/vimrc b/.vimrc similarity index 100% rename from vimrc rename to .vimrc From d18c0df7779191fc3ac1b398282fdd34207f401f Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Sun, 8 Jun 2014 11:50:05 +0800 Subject: [PATCH 08/28] Created auto-configure file. --- configure | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) create mode 100644 configure diff --git a/configure b/configure new file mode 100644 index 0000000..534d637 --- /dev/null +++ b/configure @@ -0,0 +1,26 @@ +# This file will configure a new VM with all the things I want... +# Usage: +# source <(curl https://raw.githubusercontent.com/jgeewax/dotfiles/master/configure) + +jjg-configure() { + echo "Configuring machine..." + + # Install the appropriate packages. + sudo apt-get update + sudo apt-get install -y g++ less vim tmux openjdk-7-jdk git subversion + + # Make sure that Vim Pathogen is installed. .vimrc won't work without it. + if [[ ! -f ~/.vim/autoload/pathogen.vim ]]; then + mkdir -p ~/.vim/autoload ~/.vim/bundle && \ + curl -LSso ~/.vim/autoload/pathogen.vim https://tpo.pe/pathogen.vim + fi + + # Grab configuration files from GitHub. + curl -LSso ~/.bashrc https://raw.githubusercontent.com/jgeewax/dotfiles/master/.bashrc + curl -LSso ~/.tmux.conf https://raw.githubusercontent.com/jgeewax/dotfiles/master/.tmux.conf + curl -LSso ~/.vimrc https://raw.githubusercontent.com/jgeewax/dotfiles/master/.vimrc + + echo "Done" +} + +jjg-configure From 4789e22a7215c95cda689e075f3c8bc177b01a24 Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Sun, 8 Jun 2014 11:53:43 +0800 Subject: [PATCH 09/28] Added gcloud install to the configuration script. --- configure | 3 +++ 1 file changed, 3 insertions(+) diff --git a/configure b/configure index 534d637..b0f50d4 100644 --- a/configure +++ b/configure @@ -14,6 +14,9 @@ jjg-configure() { mkdir -p ~/.vim/autoload ~/.vim/bundle && \ curl -LSso ~/.vim/autoload/pathogen.vim https://tpo.pe/pathogen.vim fi + + # Install the Google Cloud SDK. + curl https://sdk.cloud.google.com | bash # Grab configuration files from GitHub. curl -LSso ~/.bashrc https://raw.githubusercontent.com/jgeewax/dotfiles/master/.bashrc From acef7f13ae8bca1960e4957011787513956ea998 Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Sun, 8 Jun 2014 11:57:08 +0800 Subject: [PATCH 10/28] Updated configure with shortlink. --- configure | 2 ++ 1 file changed, 2 insertions(+) diff --git a/configure b/configure index b0f50d4..b058a97 100644 --- a/configure +++ b/configure @@ -1,5 +1,7 @@ # This file will configure a new VM with all the things I want... # Usage: +# source <(curl -L http://bit.ly/jjg-configure) +# OR # source <(curl https://raw.githubusercontent.com/jgeewax/dotfiles/master/configure) jjg-configure() { From 00b2341acb47f91309bd91cdb041a43a45e3d297 Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Sun, 8 Jun 2014 11:59:08 +0800 Subject: [PATCH 11/28] Updated cloud SDK installer to check for existence --- configure | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/configure b/configure index b058a97..65635a5 100644 --- a/configure +++ b/configure @@ -18,7 +18,10 @@ jjg-configure() { fi # Install the Google Cloud SDK. - curl https://sdk.cloud.google.com | bash + if [[ ! -f ~/google-cloud-sdk ]]; then + curl https://sdk.cloud.google.com | bash + source ~/.bash_profile + fi # Grab configuration files from GitHub. curl -LSso ~/.bashrc https://raw.githubusercontent.com/jgeewax/dotfiles/master/.bashrc From e94aecf10319c110c5dd63e8cb1aa17208b83eae Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Sun, 8 Jun 2014 12:06:56 +0800 Subject: [PATCH 12/28] Fixed cloud SDK existence check. --- configure | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure b/configure index 65635a5..9bec80a 100644 --- a/configure +++ b/configure @@ -18,7 +18,7 @@ jjg-configure() { fi # Install the Google Cloud SDK. - if [[ ! -f ~/google-cloud-sdk ]]; then + if [[ ! -d ~/google-cloud-sdk ]]; then curl https://sdk.cloud.google.com | bash source ~/.bash_profile fi From 87b395fa492ebcf00521d2585baf34439a6bdaa3 Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Sat, 28 Jun 2014 21:41:35 -0400 Subject: [PATCH 13/28] Added .gitconfig. --- .gitconfig | 12 ++++++++++++ configure | 3 ++- 2 files changed, 14 insertions(+), 1 deletion(-) create mode 100644 .gitconfig diff --git a/.gitconfig b/.gitconfig new file mode 100644 index 0000000..b34e1f8 --- /dev/null +++ b/.gitconfig @@ -0,0 +1,12 @@ +[alias] + st = status +[core] + excludesfile = ~/.gitignore + editor = vim +[user] + email = jj@geewax.org + name = JJ Geewax +[color] + ui = true +[push] + default = simple diff --git a/configure b/configure index 9bec80a..05e1f43 100644 --- a/configure +++ b/configure @@ -16,7 +16,7 @@ jjg-configure() { mkdir -p ~/.vim/autoload ~/.vim/bundle && \ curl -LSso ~/.vim/autoload/pathogen.vim https://tpo.pe/pathogen.vim fi - + # Install the Google Cloud SDK. if [[ ! -d ~/google-cloud-sdk ]]; then curl https://sdk.cloud.google.com | bash @@ -27,6 +27,7 @@ jjg-configure() { curl -LSso ~/.bashrc https://raw.githubusercontent.com/jgeewax/dotfiles/master/.bashrc curl -LSso ~/.tmux.conf https://raw.githubusercontent.com/jgeewax/dotfiles/master/.tmux.conf curl -LSso ~/.vimrc https://raw.githubusercontent.com/jgeewax/dotfiles/master/.vimrc + curl -LSso ~/.gitconfig https://raw.githubusercontent.com/jgeewax/dotfiles/master/.gitconfig echo "Done" } From d43f688959f9ab06c366edb387e97fd11d86548f Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Sat, 28 Jun 2014 21:43:07 -0400 Subject: [PATCH 14/28] Update configure --- configure | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure b/configure index 05e1f43..04c666e 100644 --- a/configure +++ b/configure @@ -1,6 +1,6 @@ # This file will configure a new VM with all the things I want... # Usage: -# source <(curl -L http://bit.ly/jjg-configure) +# source <(curl -L config.geewax.org) # OR # source <(curl https://raw.githubusercontent.com/jgeewax/dotfiles/master/configure) From e536df36b6197cccebc71043cff643178b5bbe1a Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Sat, 28 Jun 2014 23:00:30 -0400 Subject: [PATCH 15/28] Added .gitingore. --- .gitignore | 1 + configure | 1 + 2 files changed, 2 insertions(+) create mode 100644 .gitignore diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..4c933b8 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +*.sw[po] diff --git a/configure b/configure index 04c666e..e24b71c 100644 --- a/configure +++ b/configure @@ -28,6 +28,7 @@ jjg-configure() { curl -LSso ~/.tmux.conf https://raw.githubusercontent.com/jgeewax/dotfiles/master/.tmux.conf curl -LSso ~/.vimrc https://raw.githubusercontent.com/jgeewax/dotfiles/master/.vimrc curl -LSso ~/.gitconfig https://raw.githubusercontent.com/jgeewax/dotfiles/master/.gitconfig + curl -LSso ~/.gitignore https://raw.githubusercontent.com/jgeewax/dotfiles/master/.gitignore echo "Done" } From 86902811e532830f702d625a4be49065479a0072 Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Thu, 3 Sep 2015 05:23:35 -0400 Subject: [PATCH 16/28] Update .bashrc --- .bashrc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.bashrc b/.bashrc index 6eeafcd..8c50c05 100644 --- a/.bashrc +++ b/.bashrc @@ -11,6 +11,8 @@ HISTCONTROL=$HISTCONTROL${HISTCONTROL+,}ignoredups # ... or force ignoredups and ignorespace HISTCONTROL=ignoreboth +#HISTFILE="${HOME}/.history/$(date -u +%Y/%m/%d.%H.%M.%S)_${HOSTNAME_SHORT}_$$" + # Add Ruby gem bin directory to the system path PATH=/var/lib/gems/1.8/bin:$PATH From fb03961ceffbf704a0145a2b2673b27d4b991cd7 Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Sun, 4 Oct 2015 13:30:20 -0400 Subject: [PATCH 17/28] Create .git_commit_msg.txt --- .git_commit_msg.txt | 5 +++++ 1 file changed, 5 insertions(+) create mode 100644 .git_commit_msg.txt diff --git a/.git_commit_msg.txt b/.git_commit_msg.txt new file mode 100644 index 0000000..b01d96c --- /dev/null +++ b/.git_commit_msg.txt @@ -0,0 +1,5 @@ +# If applied, this commit will... + +# Why is this change being made? + +# Provide links to relevant tickets, URLs, or resources: From 3074a18b7bb3279ab8f3852eeafcd6e33c35ae5c Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Sun, 4 Oct 2015 13:31:37 -0400 Subject: [PATCH 18/28] Add a default commit template. Sometimes we need reminding about what to put in a git commit message! --- .gitconfig | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.gitconfig b/.gitconfig index b34e1f8..83c6502 100644 --- a/.gitconfig +++ b/.gitconfig @@ -10,3 +10,5 @@ ui = true [push] default = simple +[commit] + template = ~/.git_commit_msg.txt From 84ddcdb06bbac9d77bdcf01d4da20ac947d6a504 Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Mon, 12 Oct 2015 10:00:11 -0400 Subject: [PATCH 19/28] Refreshes vimrc --- .vimrc | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/.vimrc b/.vimrc index b6c392e..452f797 100644 --- a/.vimrc +++ b/.vimrc @@ -10,9 +10,13 @@ execute pathogen#infect() filetype plugin indent on +syntax on + +set clipboard=unnamedplus set nocompatible set ruler set mouse=a +set ttymouse=sgr set noerrorbells set listchars=tab:>-,trail:- set number @@ -32,6 +36,11 @@ let g:indent_guides_guide_size = 1 let g:indent_guides_auto_colors = 0 let g:indent_guides_enable_on_vim_startup = 1 +" 80-character guideline +if exists("+colorcolumn") + set colorcolumn=80 +endif + " Wildmenu if has("wildmenu") set wildignore+=*.a,*.o,*.pyc @@ -45,3 +54,6 @@ endif " Highlight trailing whitespace highlight ExtraWhitespace ctermbg=red guibg=red autocmd BufWinEnter * match ExtraWhitespace /\s\+$/ + +" .ng files should act like html files +au BufReadPost *.ng set syntax=html From 2dc5e734c90c5a8bf17e74ceacbfd52256bbaa0c Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Mon, 12 Oct 2015 23:24:59 -0400 Subject: [PATCH 20/28] Fix ttymouse setting on Mac --- .vimrc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/.vimrc b/.vimrc index 452f797..1d0e4e8 100644 --- a/.vimrc +++ b/.vimrc @@ -16,7 +16,9 @@ set clipboard=unnamedplus set nocompatible set ruler set mouse=a -set ttymouse=sgr +if has("mouse_sgr") + set ttymouse=sgr +endif set noerrorbells set listchars=tab:>-,trail:- set number From abfabb74eadbc4118cf3258a411367efaeab339f Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Fri, 16 Oct 2015 19:47:29 -0400 Subject: [PATCH 21/28] Add vim markdown folding disabled --- .vimrc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.vimrc b/.vimrc index 1d0e4e8..0a099b3 100644 --- a/.vimrc +++ b/.vimrc @@ -59,3 +59,6 @@ autocmd BufWinEnter * match ExtraWhitespace /\s\+$/ " .ng files should act like html files au BufReadPost *.ng set syntax=html + +" No markdown folding +let g:vim_markdown_folding_disabled=1 From 1e2a845abd261400383611b01ae7a93b27b73468 Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Sat, 19 Dec 2015 08:47:04 -0500 Subject: [PATCH 22/28] Added curlrc --- .curlrc | 1 + 1 file changed, 1 insertion(+) create mode 100644 .curlrc diff --git a/.curlrc b/.curlrc new file mode 100644 index 0000000..534bacd --- /dev/null +++ b/.curlrc @@ -0,0 +1 @@ +-w "\n" From f48cffaf95e01ec0013076cde7683711e5477a83 Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Tue, 12 Jan 2016 11:41:42 -0500 Subject: [PATCH 23/28] Made curl silent by default --- .curlrc | 1 + 1 file changed, 1 insertion(+) diff --git a/.curlrc b/.curlrc index 534bacd..cdd76ed 100644 --- a/.curlrc +++ b/.curlrc @@ -1 +1,2 @@ -w "\n" +-s From 534b20258360b0d1b78cbe8a4ec968219d43c36d Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Tue, 12 Jan 2016 11:42:13 -0500 Subject: [PATCH 24/28] Added .bash_aliases --- .bash_aliases | 2 ++ 1 file changed, 2 insertions(+) create mode 100644 .bash_aliases diff --git a/.bash_aliases b/.bash_aliases new file mode 100644 index 0000000..64c5004 --- /dev/null +++ b/.bash_aliases @@ -0,0 +1,2 @@ +alias wideterm="rxvt-unicode -bg black -fg white -fn xft:monospace -letsp -1" +alias json="python -c \"import json, sys; print json.dumps(json.loads(sys.stdin.read()), indent=2);\"" From c300ec3873d523b9f2ce49035563489950093a0e Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Tue, 12 Jan 2016 11:43:22 -0500 Subject: [PATCH 25/28] Switched prettyjson to use Python's json.tool --- .bash_aliases | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.bash_aliases b/.bash_aliases index 64c5004..0ee8a7e 100644 --- a/.bash_aliases +++ b/.bash_aliases @@ -1,2 +1,2 @@ alias wideterm="rxvt-unicode -bg black -fg white -fn xft:monospace -letsp -1" -alias json="python -c \"import json, sys; print json.dumps(json.loads(sys.stdin.read()), indent=2);\"" +alias prettyjson="python -m json.tool" From 563397bc066ef16baf94d902fa3b15ba0bf87c57 Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Sun, 17 Jan 2016 10:31:20 -0500 Subject: [PATCH 26/28] Added less mouse scrolling --- .bashrc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.bashrc b/.bashrc index 8c50c05..98d2793 100644 --- a/.bashrc +++ b/.bashrc @@ -100,6 +100,9 @@ if [ -x /usr/bin/dircolors ]; then alias egrep='egrep --color=auto' fi +# less should scroll +LESS=-R + # Set up a local ssh-agent if necessary. SSHAGENT=/usr/bin/ssh-agent SSHAGENTARGS="-s" From f42f99f899ad44e9c7ae97e1374d0039a24c0d2c Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Mon, 18 Jan 2016 07:36:18 -0500 Subject: [PATCH 27/28] Changed 80-character border color to dark grey --- .vimrc | 1 + 1 file changed, 1 insertion(+) diff --git a/.vimrc b/.vimrc index 0a099b3..f60c77e 100644 --- a/.vimrc +++ b/.vimrc @@ -41,6 +41,7 @@ let g:indent_guides_enable_on_vim_startup = 1 " 80-character guideline if exists("+colorcolumn") set colorcolumn=80 + hi ColorColumn ctermbg=235 guibg=#262626 endif " Wildmenu From 4a11bb7e08d406f2953ca1661752b8ae9d05692b Mon Sep 17 00:00:00 2001 From: JJ Geewax Date: Fri, 27 May 2016 09:50:55 -0400 Subject: [PATCH 28/28] Added JS plugin for VIM --- configure | 3 +++ 1 file changed, 3 insertions(+) diff --git a/configure b/configure index e24b71c..c21cc99 100644 --- a/configure +++ b/configure @@ -16,6 +16,9 @@ jjg-configure() { mkdir -p ~/.vim/autoload ~/.vim/bundle && \ curl -LSso ~/.vim/autoload/pathogen.vim https://tpo.pe/pathogen.vim fi + + # Install vim plugins + git clone https://github.com/pangloss/vim-javascript.git ~/.vim/bundle/vim-javascript # Install the Google Cloud SDK. if [[ ! -d ~/google-cloud-sdk ]]; then