[kteam-tools][PATCH] maint-startnewrelease: stop if DEBEMAIL is unset

Kamal Mostafa kamal at canonical.com
Thu Feb 1 19:20:09 UTC 2018


Signed-off-by: Kamal Mostafa <kamal at canonical.com>
---
 maintscripts/maint-startnewrelease | 7 +++----
 1 file changed, 3 insertions(+), 4 deletions(-)

diff --git a/maintscripts/maint-startnewrelease b/maintscripts/maint-startnewrelease
index 3d3f9b1..50ccdd8 100755
--- a/maintscripts/maint-startnewrelease
+++ b/maintscripts/maint-startnewrelease
@@ -57,10 +57,9 @@ if not mailenforce:
 	mailenforce = "@canonical.com"
 
 debem = os.getenv("DEBEMAIL")
-if debem is not None:
-	if mailenforce not in debem:
-		print 'DEBEMAIL does not contain', mailenforce
-		sys.exit(1)
+if (debem is None) or (debem is not None and mailenforce not in debem):
+            print 'DEBEMAIL is unset, or does not contain', mailenforce
+            sys.exit(1)
 
 #------------------------------------------------------------------------------
 # Find the abstracted debian directory and make sure it is there (IOW we are
-- 
2.7.4





More information about the kernel-team mailing list