[enh] check for gm binary

This commit is contained in:
Laurent Peuch 2015-12-09 06:57:53 +01:00
parent 776674cb3e
commit c8ceee9e9e

View File

@ -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"))