Last active
May 22, 2019 01:34
-
-
Save ajcastro/8157ae89730b50d80aa0 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
alias ..="cd .." | |
alias ...="cd ../.." | |
alias ll="ls -alF" | |
alias proj="cd d:\Projects" | |
#*****# | |
# Git # | |
#*****# | |
alias gp="git pull" | |
alias gs="git status" | |
alias ga="git add" | |
alias gc="git commit -m" | |
alias gstash="git stash" | |
alias gct="git checkout" | |
alias gb="git branch" | |
alias gl="git log --oneline" | |
alias glog="git log --oneline" | |
alias glogg="git log --oneline --graph" | |
alias gmerge="git merge" | |
alias gd="git diff" | |
alias gds="git diff --staged" | |
alias gcp="git cherry-pick" | |
alias gshow="git show" | |
alias gdevelop="git checkout develop && git pull origin develop" | |
alias gmaster="git checkout master && git pull origin master" | |
function gfct() { | |
branch=$1 | |
git fetch origin $branch && git checkout $branch | |
} | |
function current_branch() { | |
branch=$(git symbolic-ref -q HEAD) | |
branch=${branch##refs/heads/} | |
branch=${branch:-HEAD} | |
echo ${branch} | |
} | |
function gpuo() { | |
git push -u origin $(current_branch) | |
} | |
function gpuof() { | |
git push -u origin $(current_branch) --force | |
} | |
function gpo() { | |
git pull origin $(current_branch) | |
} | |
function gpor() { | |
branch=$1 | |
git pull origin $branch --rebase | |
} | |
function gmd() { | |
echo "Switching..." | |
git checkout master && git pull origin master | |
echo "Switching..." | |
git checkout develop && git pull origin develop | |
echo "Rebasing master..." | |
git rebase master | |
echo "Pushing to origin/develop..." | |
git push -u origin develop | |
} | |
function gbdm() { | |
git branch --merged | egrep -v "(^\*|master|dev)" | xargs git branch -d | |
} | |
#*****************# | |
# PHP Development # | |
#*****************# | |
alias pa='php artisan' | |
alias pu="vendor/bin/phpunit" | |
alias pus="vendor/bin/phpunit --stop-on-failure" | |
alias cda="composer dump-autoload" | |
proj |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment