Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(git): install hub and alias it #23

Merged
merged 3 commits into from
Aug 1, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 7 additions & 6 deletions .aliases
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,13 @@ alias ri='ri -f ansi'
which colordiff &>/dev/null && alias diff='colordiff'

# Git
alias gst='git status'
alias ga='git add --patch'
alias gd='git diff'
alias glglm='git log --before=$(date "+%Y-%m-01") --after=$(date -d"1 month ago" "+%Y-%m-01") --author="$(git config user.name)" --reverse --pretty=format:"%cd - %h - %s" --date=short --no-merges'
alias glgcm='git log --before=$(date -d"+ 1 month" "+%Y-%m-01") --after=$(date "+%Y-%m-01") --author="$(git config user.name)" --reverse --pretty=format:"%cd - %h - %s" --date=short'
alias glgt='git log --since="yesterday" --author="$(git config user.name)" --pretty=format:"%cd - %h - %s" --date=short --no-merges'
alias g='hub'
alias gst='hub status'
alias ga='hub add --patch'
alias gd='hub diff'
alias glglm='hub log --before=$(date "+%Y-%m-01") --after=$(date -d"1 month ago" "+%Y-%m-01") --author="$(hub config user.name)" --reverse --pretty=format:"%cd - %h - %s" --date=short --no-merges'
alias glgcm='hub log --before=$(date -d"+ 1 month" "+%Y-%m-01") --after=$(date "+%Y-%m-01") --author="$(hub config user.name)" --reverse --pretty=format:"%cd - %h - %s" --date=short'
alias glgt='hub log --since="yesterday" --author="$(hub config user.name)" --pretty=format:"%cd - %h - %s" --date=short --no-merges'

# Some aliases to avoid making mistakes
alias rm='rm -i'
Expand Down
1 change: 1 addition & 0 deletions .brew
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,7 @@ brew install gnu-tar
brew install graphviz
brew install gsl
brew install htop-osx
brew install hub
brew install jq
brew install moreutils
brew install pre-commit
Expand Down
3 changes: 3 additions & 0 deletions .zshrc
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,9 @@ GCLOUD_SDK=/opt/homebrew-cask/Caskroom/google-cloud-sdk/latest/google-cloud-sdk
[[ -f "${GCLOUD_SDK}/completion.zsh.inc" ]] && \
source "${GCLOUD_SDK}/completion.zsh.inc"

# hub
eval "$(hub alias -s)"

# Aliases
[[ -f ~/.aliases ]] && source ~/.aliases

Expand Down