summaryrefslogtreecommitdiff
path: root/morph
diff options
context:
space:
mode:
authorLars Wirzenius <lars.wirzenius@codethink.co.uk>2012-04-30 19:14:47 +0100
committerLars Wirzenius <lars.wirzenius@codethink.co.uk>2012-04-30 19:14:47 +0100
commit2d5b60bbbdf1a43d0271f352a0d5f536796002c9 (patch)
tree64e46c965ef66de48764ebe7ef7f1b00f38ad7f4 /morph
parentb76d00c7a1e07267b8db214e344e4e9b293e5287 (diff)
downloadmorph-2d5b60bbbdf1a43d0271f352a0d5f536796002c9.tar.gz
Add test for branching off not from master
Diffstat (limited to 'morph')
-rwxr-xr-xmorph4
1 files changed, 2 insertions, 2 deletions
diff --git a/morph b/morph
index 8f3ba311..0a77995b 100755
--- a/morph
+++ b/morph
@@ -719,13 +719,13 @@ class Morph(cliapp.Application):
def cmd_branch(self, args):
'''Branch the whole system.'''
- if len(args) != 1:
+ if len(args) not in [1, 2]:
raise cliapp.AppException('morph branch needs name of branch '
'as parameter')
new_branch = args[0]
repo = 'morphs'
- commit = 'master'
+ commit = 'master' if len(args) == 1 else args[1]
# Create the system branch directory.
os.makedirs(new_branch)