From c8ceee9e9e6c2ed37a1420b81528964bf024b950 Mon Sep 17 00:00:00 2001 From: Laurent Peuch Date: Wed, 9 Dec 2015 06:57:53 +0100 Subject: [PATCH] [enh] check for gm binary --- prosopopoee | 3 +++ 1 file changed, 3 insertions(+) diff --git a/prosopopoee b/prosopopoee index 976eec0..36f70e5 100755 --- a/prosopopoee +++ b/prosopopoee @@ -34,6 +34,9 @@ def error(test, error_message): def main(): + if os.system("which gm > /dev/null") != 0: + sys.stderr.write("WARNING: I can't locate the 'gm' binary, I won't be able to resize images.\n") + error(os.path.exists(os.path.join(os.getcwd(), "settings.yaml")), "I can't find a settings.yaml in the current working directory") settings = yaml.safe_load(open("settings.yaml", "r"))