From 7b5e28d643e6c9998632a587863ba7af5dec95f7 Mon Sep 17 00:00:00 2001 From: Mathieu Virbel Date: Fri, 16 Nov 2018 10:52:02 +0100 Subject: [PATCH] add an error message for creating a project without python2 or python3 compiled. Closes #311 --- toolchain.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/toolchain.py b/toolchain.py index c039d69..198013b 100755 --- a/toolchain.py +++ b/toolchain.py @@ -1334,6 +1334,13 @@ Xcode: from cookiecutter.main import cookiecutter ctx = Context() ensure_recipes_loaded(ctx) + + if not hasattr(ctx, "python_ver"): + print("ERROR: No python recipes compiled!") + print("ERROR: You must have compiled at least python2 or") + print("ERROR: python3 recipes to be able to create a project.") + sys.exit(1) + template_dir = join(curdir, "tools", "templates") context = { "title": args.name,