From fca3768cb0d87bb08ae448bc0e4c7c800187335c Mon Sep 17 00:00:00 2001 From: Marley Rae Date: Thu, 25 Jan 2024 12:30:14 -0800 Subject: [PATCH] =?UTF-8?q?=E2=9C=A8=20Add=20WIP=20commit=20aliases?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- git/aliases.zsh | 3 +++ 1 file changed, 3 insertions(+) diff --git a/git/aliases.zsh b/git/aliases.zsh index 0a69161..e452a0b 100644 --- a/git/aliases.zsh +++ b/git/aliases.zsh @@ -128,6 +128,9 @@ alias gstap="git stash pop" # retrieve changes alias gstal="git stash list" # list stashes alias gstas="git stash show --text" # --text treats all files as text +alias gwip='git add -A; git rm $(git ls-files --deleted) 2> /dev/null; git commit --no-verify --no-gpg-sign --message "🚧 --wip-- [skip ci]"' +alias gunwip='git rev-list --max-count=1 --format="%s" HEAD | grep -q "\🚧 --wip--" && git reset HEAD~1' + alias gcl="git clean -f" # remove unknown (untracked and unignored) files alias gcldr="git clean --dry-run"