I think we're all onboard with git these days - it's the best way to collaborate on code with a team or to just keep things organized, synchronized...
For further actions, you may consider blocking this person and/or reporting abuse
A nice one is
For those times you were just too quick on the trigger, and want to add some additional staged files to your last commit.
Feel free to use a different alias, like
goops
orgredo
🤨I've been meaning to add one like this - thinking
gcrap
orgdoh
, or maybe justgc!
I use this to set
git lg
to be a cleaner overview of history:Results in a nice tree view of history showing authors, hashes, titles and the tag/branch names.
That's a good one.
I must say that I never goes beyond the aliases that are by default in zsh and oh_my_zsh.
Here is a quick extract of the aliases available in oh_my_zsh :
I wish that the aliases in
oh_my_zsh
were commented to tell you what they do in plain english. I will often look in there and try to add a new one to my arsenal, but that becomes a bit of a research project since I'm not fluent ingit
commands and typically need to look things up, at least just to be sure that the commands will do what I suspect.One of my fav aliases I always set up in git's own aliasing config is:
git ac
For git "all commit". Which is an alias for
git add .; git commit -m
.To just add & commit everything in one go.
git add .
is 'all commit' only if you have changes on the current path. If you have changes in e.g. sibling dir it won't work as you'd have to go up the path which is..
. For a true 'all commit' usegit add -A
.Thanks!
I do always run this from project root so I'm ok. But I think I'll switch to your suggestion! :)
I like that - I have
gc
aliased togit commit
so I'll usually dogc -am "commit message"
but that does have the the drawback of not adding new files and I forget that 90% of the time and then have to amend the commit which is a whole thing.Today I came across to this one:
alias gconf='git diff --name-only --diff-filter=U'
To list the conficted files after a merge
I use
hub
and I aliasgit=hub
then I have
git sync, git pr list, git pull-request create, git release etc...
I hadn't heard of
hub
, will have to check it out.hub: A command-line tool that makes git easier to use with GitHub
Here are the aliases I use gist.github.com/zivni/90a6a93fec67...
Just created this little handy alias for interactive rebase