feature: add an option in repository configuration to enable --prune on fetch (#590)

Signed-off-by: leo <longshuang@msn.cn>
This commit is contained in:
leo 2024-10-30 18:39:38 +08:00
parent a4befd010a
commit 3cbffa6ff9
No known key found for this signature in database
12 changed files with 50 additions and 11 deletions

View file

@ -4,7 +4,7 @@ namespace SourceGit.Commands
{
public class Fetch : Command
{
public Fetch(string repo, string remote, bool noTags, Action<string> outputHandler)
public Fetch(string repo, string remote, bool noTags, bool prune, Action<string> outputHandler)
{
_outputHandler = outputHandler;
WorkingDirectory = repo;
@ -18,6 +18,9 @@ namespace SourceGit.Commands
else
Args += "--force ";
if (prune)
Args += "--prune ";
Args += remote;
}