Browse Source

Don't update branches for bare repos (#14)

tags/v0.3
Ben Kurtovic 9 years ago
parent
commit
5a4e49ea56
1 changed files with 3 additions and 2 deletions
  1. +3
    -2
      gitup/update.py

+ 3
- 2
gitup/update.py View File

@@ -237,12 +237,13 @@ def _update_repository(repo, current_only=False, rebase=False, merge=False):
else: else:
remotes = repo.remotes remotes = repo.remotes
if not remotes: if not remotes:
print(INDENT2, ERROR, "no remotes configured to pull from.")
print(INDENT2, ERROR, "no remotes configured to fetch.")
return return
rebase = rebase or _read_config(repo, "pull.rebase") rebase = rebase or _read_config(repo, "pull.rebase")


_fetch_remotes(remotes) _fetch_remotes(remotes)
_update_branches(repo, active, merge, rebase)
if not repo.bare:
_update_branches(repo, active, merge, rebase)


def _update_subdirectories(path, long_name, update_args): def _update_subdirectories(path, long_name, update_args):
"""Update all subdirectories that are git repos in a given directory.""" """Update all subdirectories that are git repos in a given directory."""


Loading…
Cancel
Save