From d1d52b5c1e40bdc94431ab303fa6368b12fe4f53 Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Wed, 27 Jan 2016 15:42:46 +0100 Subject: properly complain about invalid entries in --module-subset Change-Id: I13ec7a6acdc8a47efea14bfabf0413d8a3570870 Reviewed-by: Simon Hausmann --- init-repository | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/init-repository b/init-repository index 966e0c16..ae3f0495 100755 --- a/init-repository +++ b/init-repository @@ -337,8 +337,12 @@ sub git_clone_all_submodules } elsif ($mod eq "obsolete") { map { $include{$_} = 1; } grep { ($subinits{$_} || 0) eq STS_OBSOLETE } keys %subbases; } elsif ($mod =~ s/^-//) { + print "Warning: excluding non-existent module '$mod'.\n" + if (!defined($subdirs{$mod})); delete $include{$mod}; } else { + die("Error: module subset names non-existent '$mod'.\n") + if (!defined($subdirs{$mod})); $include{$mod} = 1; } } -- cgit v1.2.3