From 9f2c17b9796f0a7ecd8625c1102f1a5ce0cdff28 Mon Sep 17 00:00:00 2001 From: Dave Cahill Date: Sat, 9 Dec 2017 11:42:59 +0900 Subject: [PATCH] Improve behavior when elm-ios.py is called without arguments --- elm-ios.py | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/elm-ios.py b/elm-ios.py index 11bd9e6..d256b90 100755 --- a/elm-ios.py +++ b/elm-ios.py @@ -146,6 +146,11 @@ def main(): run_elm_make(elm_make_args) + # Assert that compiled elm code was output + if not os.path.exists(join_path(CWD, COMPILED_ELM_FNAME)): + print ("No compiled elm code found at {0}. Aborting.").format(join_path(CWD, COMPILED_ELM_FNAME)) + raise SystemExit + # Clean the build directory if os.path.isdir(BUILD_DIR): shutil.rmtree(BUILD_DIR)