Answer the question
In order to leave comments, you need to log in
How to set alias for git globally?
How to set alias for git globally?
I know that you need to write your aliases in the .gitconfig file.
Now I have this:
[alias]
co = checkout
ci = commit
st = status
gs = git status
br = branch
hist = log --pretty=format:\"%h %ad | %s%d [%an]\" --graph --date=short
type = cat-file -t
dump = cat-file -p
Answer the question
In order to leave comments, you need to log in
This is already a system alias, not a git.
For bash
in the file ~/.bash_aliases
and write:
Then re-read the file:
alias st='git status'
. ~/.bash_aliases
Create a system alias. How to do this (and whether it is possible at all) depends on the OS.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question