Replying to Avatar DETERMINISTIC OPTIMISM ๐ŸŒž

Git time savers I use often. [ZSH]

## Capitulation, fuck my changes and clean up.

gifu(){

branch=$(git rev-parse --abbrev-ref HEAD);

git fetch origin;

git reset --hard origin/$branch;

print -P "=> Git, I Fucked Up; cleaned it for you."

}

## Open Project on Github

gop(){

open `git remote -v | sed 's/^.*:/http:\/\/github.com\//' | sed 's/.git .*//' | tail -1`

}

## Open Project Issues on Github

gip(){

url=$(git remote -v | perl -n -e 'm{:(.+?).git} && print $1,"\n"' | uniq );

open "http://github.com/$url/issues"

}

74
HODLร‰ire๐Ÿ‡ฎ๐Ÿ‡ช 2y ago

Somehow do git reset hard and still somehow have changes from 2017 on my local branch ๐Ÿ‘€

Reply to this note

Please Login to reply.

Discussion

No replies yet.