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"

}

Avatar
Gigi 2y ago

https://gist.github.com/filoscoder/cab5e8769400c9248174051f4f81fc46

https://github.com/romkatv/powerlevel10k

Reply to this note

Please Login to reply.

Discussion

Avatar
DETERMINISTIC OPTIMISM 🌞 2y ago

I use something similar.

Thread collapsed