From 390358f8a3bc49e8e48835c47e2d42d2312c7bc5 Mon Sep 17 00:00:00 2001 From: Bahadir Balban Date: Tue, 3 Nov 2009 11:04:30 +0200 Subject: [PATCH] configure.py shuts down gracefully if configfile is not saved --- configure.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/configure.py b/configure.py index 56f70c3..28d75d6 100755 --- a/configure.py +++ b/configure.py @@ -163,6 +163,11 @@ def configure_system(options, args): os.system(CML2TOOLSDIR + '/cmlconfigure.py -c -o ' + \ CML2_CONFIG_FILE + ' ' + CML2_COMPILED_RULES) + # After configure, if user might have chosen to quit without saving + if not os.path.exists(CML2_CONFIG_FILE): + print "Exiting without saving configuration." + sys.exit() + # Create header file os.system(TOOLSDIR + '/cml2header.py -o ' + \ CML2_CONFIG_H + ' -i ' + CML2_CONFIG_FILE)