From 6ad94e14b1cea05c7f75abfd1eb223a7fcbdb778 Mon Sep 17 00:00:00 2001 From: Jonathan Channon Date: Wed, 20 Apr 2016 09:35:27 +0100 Subject: [PATCH] Added --force-with-lease method --- plugins/git/git.plugin.zsh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/plugins/git/git.plugin.zsh b/plugins/git/git.plugin.zsh index 95ce1ae26..65d34c838 100644 --- a/plugins/git/git.plugin.zsh +++ b/plugins/git/git.plugin.zsh @@ -95,6 +95,10 @@ ggf() { [[ "$#" != 1 ]] && local b="$(git_current_branch)" git push --force origin "${b:=$1}" } +ggfl() { +[[ "$#" != 1 ]] && local b="$(git_current_branch)" +git push --force-with-lease origin "${b:=$1}" +} compdef _git ggf=git-checkout ggl() { if [[ "$#" != 0 ]] && [[ "$#" != 1 ]]; then