From b78e7fce5938e22b9a23a9fa4e726bed30e2793f Mon Sep 17 00:00:00 2001 From: Oleg Broytman Date: Wed, 16 Mar 2016 02:57:49 +0300 Subject: [PATCH] .gitconfig: add `alias' and `aliases' aliases --- .gitconfig | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.gitconfig b/.gitconfig index 9301b8e..41e7f8a 100644 --- a/.gitconfig +++ b/.gitconfig @@ -1,4 +1,6 @@ [alias] + alias = "!f() { [ $# = 2 ] && git config --global alias.\"$1\" \"$2\" && return 0 || echo \"Usage: git alias \" >&2 && return 1; }; f" + aliases = !git config --get-regexp 'alias.*' | colrm 1 6 | sed 's/[ ]/ = /' b = branch branches = branch -a camend = commit --amend -C HEAD -- 2.39.5