From af6fe7c33d8af1bf728a0fb3867e8765138c4258 Mon Sep 17 00:00:00 2001 From: Toby Vincent Date: Sun, 11 Apr 2021 14:22:18 -0500 Subject: feat: added github clone alias --- zsh/aliases.zsh | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/zsh/aliases.zsh b/zsh/aliases.zsh index 16ab231..a673b34 100644 --- a/zsh/aliases.zsh +++ b/zsh/aliases.zsh @@ -7,4 +7,14 @@ alias untar="tar -zxvf " alias py=python3 alias python=python3 alias pip=pip3 -alias dsh="dce sh" \ No newline at end of file +alias dsh="dce sh" +alias clone=github-clone + + +function github-clone() { + if [[ "$1" != *"/"* ]]; then + 1="$(git config user.username)/$1" + fi + + git clone git@github.com:$1.git +} \ No newline at end of file -- cgit v1.2.3-70-g09d2