Add default for path to OpenSCAD on Mac OS X

This commit is contained in:
Sebastian Hoogen
2014-06-30 11:45:42 +02:00
committed by wmayer
parent b83f07fe2e
commit 5374302e93

View File

@@ -54,6 +54,11 @@ def searchforopenscadexe():
for testpath in testpaths:
if os.path.isfile(testpath):
return testpath
elif sys.platform == 'darwin':
#test the default path
testpath="/Applications/OpenSCAD.app/Contents/MacOS/OpenSCAD"
if os.path.isfile(testpath):
return testpath
else: #unix
p1=subprocess.Popen(['which','openscad'],stdout=subprocess.PIPE)
if p1.wait() == 0: