diff --git a/.gitignore b/.gitignore index a57d76865c7..1214493374b 100644 --- a/.gitignore +++ b/.gitignore @@ -6,5 +6,7 @@ atom.symlink/compile-cache/ atom.symlink/packages atom.symlink/storage atom.symlink/themes +atom.symlink/blob-store +atom.symlink/recovery git/gitconfig.local.symlink diff --git a/Brewfile b/Brewfile index 9b35eb8f10a..2bd5e909309 100644 --- a/Brewfile +++ b/Brewfile @@ -1,6 +1,7 @@ cask_args appdir: '/Applications' tap 'homebrew/bundle' +tap 'puma/puma' brew 'ack' brew 'coreutils' @@ -8,12 +9,14 @@ brew 'go' brew 'grc' brew 'imagemagick' brew 'jp2a' +brew 'jq' brew 'libcaca', args: ['with-imlib2'] brew 'libgit2' brew 'openssl' brew 'node' brew 'readline' brew 'postgresql' +brew 'puma/puma/puma-dev' brew 'ruby-build' brew 'rbenv' brew 'roundup' @@ -21,6 +24,7 @@ brew 'spaceman-diff' brew 'spark' brew 'unrar' brew 'wget' +brew 'yarn' brew 'youtube-dl' cask '1password' diff --git a/README.md b/README.md index 81a9d57fe3c..c5b13c9a7dc 100644 --- a/README.md +++ b/README.md @@ -69,6 +69,9 @@ There's a few special files in the hierarchy. - **topic/\*logout.zsh**: Any file ending in `logout.zsh` is loaded for login shells only and only when you exit/logout the shell. +- **topic/install.sh**: Any file named `install.sh` is executed when you + run `script/install`. To avoid being loaded automatically, its + extension is `.sh`, not `.zsh`. - **topic/\*.symlink**: Any files ending in `*.symlink` get symlinked into your `$HOME`. This is so you can keep all of those versioned in your dotfiles but still keep those autoloaded files in your home directory. These get diff --git a/atom.symlink/config.cson b/atom.symlink/config.cson index 65670f49bef..a8f7556621f 100644 --- a/atom.symlink/config.cson +++ b/atom.symlink/config.cson @@ -21,11 +21,14 @@ ] editor: fontFamily: "Menlo" + fontSize: 15 invisibles: {} showIndentGuide: true softWrapAtPreferredLineLength: true "go-plus": goPath: "/Users/holman/Code/go" + "linter-eslint": + useGlobalEslint: true "release-notes": viewedVersion: "0.89.0" "spell-check": diff --git a/bin/atom-package-backup b/bin/atom-package-backup new file mode 100755 index 00000000000..25f8a451b95 --- /dev/null +++ b/bin/atom-package-backup @@ -0,0 +1,11 @@ +#!/bin/sh +# +# Usage: atom-package-backup +# +# Saves a list of your currently installed atom packages to +# ~/.dotfiles/atom.symlink/packages.txt suitable for install +# via atom-package-install + +set -e + +apm list --installed --bare > ~/.dotfiles/atom.symlink/packages.txt diff --git a/bin/atom-package-install b/bin/atom-package-install new file mode 100755 index 00000000000..218bf414ee1 --- /dev/null +++ b/bin/atom-package-install @@ -0,0 +1,13 @@ +#!/bin/sh +# +# Usage: atom-package-install +# +# Installs the atom packages listed in your packages.txt file +# located at ~/.dotfiles/atom.symlink/packages.txt +# +# You can generate a new list based on currently installed +# packages via atom-package-backup + +set -e + +apm install --packages-file ~/.dotfiles/atom.symlink/packages.txt diff --git a/bin/e b/bin/e index f8b6c05fcb6..501ad6e372b 100755 --- a/bin/e +++ b/bin/e @@ -13,9 +13,4 @@ # $ e . # $ e /usr/local # # => opens the specified directory in your editor - -if [ "$1" = "" ] ; then - exec $EDITOR . -else - exec $EDITOR "$1" -fi +exec "$EDITOR" "${1:-.}" diff --git a/bin/search b/bin/search index d899b4ce332..fc64731684d 100755 --- a/bin/search +++ b/bin/search @@ -1,12 +1,12 @@ #!/bin/sh # -# Quick search in a directory for a string ($1). +# Quick search in a directory for a string ($@). # set -e # use -iru to search directories ack usually ignores (like .git) if [ -x /usr/bin/ack-grep ]; then - ack-grep -i $1 + ack-grep -i "$@" else - ack -i $1 + ack -i "$@" fi diff --git a/docker/aliases.zsh b/docker/aliases.zsh new file mode 100644 index 00000000000..17b10f6bc90 --- /dev/null +++ b/docker/aliases.zsh @@ -0,0 +1,2 @@ +alias d='docker $*' +alias d-c='docker-compose $*' diff --git a/git/aliases.zsh b/git/aliases.zsh index 572e7ef9676..a442f4bbdec 100644 --- a/git/aliases.zsh +++ b/git/aliases.zsh @@ -10,7 +10,10 @@ fi alias gl='git pull --prune' alias glog="git log --graph --pretty=format:'%Cred%h%Creset %an: %s - %Creset %C(yellow)%d%Creset %Cgreen(%cr)%Creset' --abbrev-commit --date=relative" alias gp='git push origin HEAD' -alias gd='git diff' + +# Remove `+` and `-` from start of diff lines; just rely upon color. +alias gd='git diff --color | sed "s/^\([^-+ ]*\)[-+ ]/\\1/" | less -r' + alias gc='git commit' alias gca='git commit -a' alias gco='git checkout' diff --git a/homebrew/install.sh b/homebrew/install.sh index 1921f008fbb..f01dbdc7f75 100755 --- a/homebrew/install.sh +++ b/homebrew/install.sh @@ -16,7 +16,7 @@ then ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)" elif test "$(expr substr $(uname -s) 1 5)" = "Linux" then - ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/linuxbrew/go/install)" + ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Linuxbrew/install/master/install)" fi fi diff --git a/yarn/path.zsh b/yarn/path.zsh new file mode 100644 index 00000000000..d7f690dfaa1 --- /dev/null +++ b/yarn/path.zsh @@ -0,0 +1,4 @@ +# sup yarn +# https://yarnpkg.com + +export PATH="$HOME/.yarn/bin:$PATH" diff --git a/zsh/config.zsh b/zsh/config.zsh index a7a7b17117a..243cbf065e4 100644 --- a/zsh/config.zsh +++ b/zsh/config.zsh @@ -1,9 +1,3 @@ -if [[ -n $SSH_CONNECTION ]]; then - export PS1='%m:%3~$(git_info_for_prompt)%# ' -else - export PS1='%3~$(git_info_for_prompt)%# ' -fi - export LSCOLORS="exfxcxdxbxegedabagacad" export CLICOLOR=true @@ -37,12 +31,9 @@ setopt HIST_REDUCE_BLANKS # like: git comm-[tab] setopt complete_aliases -zle -N newtab - bindkey '^[^[[D' backward-word bindkey '^[^[[C' forward-word bindkey '^[[5D' beginning-of-line bindkey '^[[5C' end-of-line bindkey '^[[3~' delete-char -bindkey '^[^N' newtab bindkey '^?' backward-delete-char