diff options
Diffstat (limited to 'gbp/scripts/pq.py')
-rwxr-xr-x | gbp/scripts/pq.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/gbp/scripts/pq.py b/gbp/scripts/pq.py index c32a36f..af9c90d 100755 --- a/gbp/scripts/pq.py +++ b/gbp/scripts/pq.py @@ -353,6 +353,10 @@ def main(argv): gbp.log.err("%s is not a git repository" % (os.path.abspath('.'))) return 1 + if os.path.abspath('.') != repo.path: + gbp.log.warn("Switching to topdir before running commands") + os.chdir(repo.path) + try: current = repo.get_branch() if action == "export": |