summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Maw <richard.maw@codethink.co.uk>2015-09-04 14:50:49 +0000
committerRichard Maw <richard.maw@codethink.co.uk>2015-09-04 14:50:49 +0000
commitba50f469ed085c8d8288bea061d5ae2e86802669 (patch)
treeb52e00c064697912f08c945a52d85f386ea016d0
parent174cad7e401b5a7532e337cc9911f67dbe5f0bc8 (diff)
downloadfirehose-ba50f469ed085c8d8288bea061d5ae2e86802669.tar.gz
firehose: Fix putting a full url for repo url
This calls in to the same logic that was used to create the repository, so it won't be out of sync, unlike the simple : replacement.
-rw-r--r--firehose/plugin/firehose_plugin.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/firehose/plugin/firehose_plugin.py b/firehose/plugin/firehose_plugin.py
index 5406623..12272fa 100644
--- a/firehose/plugin/firehose_plugin.py
+++ b/firehose/plugin/firehose_plugin.py
@@ -103,8 +103,10 @@ class FirehosePlugin(cliapp.Plugin):
self.app.subcommands['checkout']([root['repo'], root['myref']])
else:
raise
- repopath = root['repo'].replace(':', '/')
- self.gitpath = self.make_path("ws", root['myref'], repopath)
+ self.gitpath = morphlib.sysbranchdir.SystemBranchDirectory(
+ root_directory=self.make_path("ws", root['myref']),
+ root_repository_url=root['repo'],
+ system_branch_name=root['myref']).get_git_directory_name(root['repo'])
def reset_to_tracking(self, root):
branch_head_sha = self.app.runcmd(['git', 'rev-parse', 'HEAD'],