summaryrefslogtreecommitdiff
path: root/morphlib/plugins/branch_and_merge_plugin.py
diff options
context:
space:
mode:
authorRic Holland <richard.holland@codethink.co.uk>2013-03-22 15:54:21 +0000
committerRic Holland <richard.holland@codethink.co.uk>2013-03-22 15:54:21 +0000
commitad990ae074bc971f82375f31396d0e71a5e2463e (patch)
tree3ce3ec23ad5756f667c488ad259de95128461e39 /morphlib/plugins/branch_and_merge_plugin.py
parent8b2d8b9cbc162e99041c9bb50ac1191b9c726875 (diff)
downloadmorph-ad990ae074bc971f82375f31396d0e71a5e2463e.tar.gz
Improved error message when building or deploying outside system branch
Diffstat (limited to 'morphlib/plugins/branch_and_merge_plugin.py')
-rw-r--r--morphlib/plugins/branch_and_merge_plugin.py9
1 files changed, 7 insertions, 2 deletions
diff --git a/morphlib/plugins/branch_and_merge_plugin.py b/morphlib/plugins/branch_and_merge_plugin.py
index 32158a88..25f786e0 100644
--- a/morphlib/plugins/branch_and_merge_plugin.py
+++ b/morphlib/plugins/branch_and_merge_plugin.py
@@ -125,7 +125,10 @@ class BranchAndMergePlugin(cliapp.Plugin):
if os.path.isdir(dot_morph):
return dirname
dirname = os.path.dirname(dirname)
- raise cliapp.AppException("Can't find the workspace directory")
+ raise cliapp.AppException("Can't find the workspace directory.\n"
+ "Morph must be built and deployed within "
+ "the system branch checkout within the "
+ "workspace directory.")
def deduce_system_branch(self):
# 1. Deduce the workspace. If this fails, we're not inside a workspace.
@@ -150,7 +153,9 @@ class BranchAndMergePlugin(cliapp.Plugin):
branch_name = self.get_branch_config(dirname, 'branch.name')
return branch_name, dirname
- raise cliapp.AppException("Can't find the system branch directory")
+ raise cliapp.AppException("Can't find the system branch directory.\n"
+ "Morph must be built and deployed within "
+ "the system branch checkout.")
def find_repository(self, branch_dir, repo):
for dirname in self.walk_special_directories(branch_dir,