now checks that paths are specified

Fri, 24 May 2019 14:20:18 +0200

author
Teemu Piippo <teemu@hecknology.net>
date
Fri, 24 May 2019 14:20:18 +0200
changeset 36
2753aad79678
parent 35
865cd526e8b6
child 37
e46fa477007b

now checks that paths are specified

ldcheck.py file | annotate | diff | comparison | revisions
--- a/ldcheck.py	Fri May 24 14:18:31 2019 +0200
+++ b/ldcheck.py	Fri May 24 14:20:18 2019 +0200
@@ -40,7 +40,9 @@
 def check_library_paths(config):
     from sys import exit
     problems = False
+    have_paths = False
     for library_path in library_paths(config):
+        have_paths = True
         if not library_path.exists():
             problems = True
             print(str.format(
@@ -53,6 +55,9 @@
                 'Library path {} is not a directory',
                 library_path,
             ))
+    if not have_paths:
+        print('No LDraw path specified')
+        problems = True
     if problems:
         print('Please fix ldcheck.cfg')
         exit(1)

mercurial