diff --git a/fdroidserver/deploy.py b/fdroidserver/deploy.py index b56c5c40..68a40906 100644 --- a/fdroidserver/deploy.py +++ b/fdroidserver/deploy.py @@ -790,9 +790,9 @@ def update_servergitmirrors(servergitmirrors, repo_section): else: logging.debug(remote.url + ': ' + pushinfo.summary) - # Switch to the initial branch + # Switch to the initial branch and unstage all files repo.head.reference = initial_branch_ref - repo.head.reset(index=True, working_tree=True) + repo.head.reset(index=True, working_tree=False) if progress: progressbar.done()