Skip to content

Commit ff284c5

Browse files
committed
Git alias for new branch
1 parent d07be67 commit ff284c5

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

rc/gitconfig

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@
4646
deltag = !git tag -d $1 && git push origin :refs/tags/$1
4747
jeff = !git diff --ignore-space-at-eol -b -w --ignore-blank-lines
4848
lg = !git --no-pager log --reverse --pretty='%C(yellow)%h %C(bold blue)%<(15,trunc)%an%Creset %Cgreen%ad%Creset %s%C(auto)%d%Creset' --date=format:'%Y/%m/%d %H:%M' -n32
49+
newbranch = "!f() { git branch \"$1\" && git push -u origin \"$1\" && git checkout \"$1\"; }; f"
4950
remotes = !git remote -vv
5051
stashes = !git stash list
5152
sync = !git fetch && git pull && git cleanup && git push

0 commit comments

Comments
 (0)