From 19dfe5eb097f06e3445491cf6794ca522272bb3c Mon Sep 17 00:00:00 2001 From: Dirk Heinrichs Date: Wed, 13 Apr 2022 23:27:07 +0200 Subject: [PATCH] Add support for fetch options "--force/-f" and "--prune-tags/-P". (#563) Signed-off-by: Dirk Heinrichs --- lib/git/lib.rb | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/git/lib.rb b/lib/git/lib.rb index cd13aa54..0fdae6f8 100644 --- a/lib/git/lib.rb +++ b/lib/git/lib.rb @@ -879,6 +879,8 @@ def fetch(remote, opts) arr_opts = [] arr_opts << '--tags' if opts[:t] || opts[:tags] arr_opts << '--prune' if opts[:p] || opts[:prune] + arr_opts << '--prune-tags' if opts[:P] || opts[:'prune-tags'] + arr_opts << '--force' if opts[:f] || opts[:force] arr_opts << '--unshallow' if opts[:unshallow] arr_opts << '--depth' << opts[:depth] if opts[:depth] arr_opts << '--'