|
41 | 41 |
|
42 | 42 | setDebugFlags("nogen") /* Don't generate dll/so-files when instantiating classes (performance) */; |
43 | 43 |
|
44 | | -import shutil |
45 | | - |
46 | 44 | // rmSymlinks |
47 | 45 | // (false) should we keep readable names (nice online, if the server handles symbolic links), or |
48 | 46 | // (true) use the hashed names in the links (nice if you want a zipped version to work on Windows). This removes the readable names, keeping only the hashed and de-duped images. |
@@ -81,10 +79,9 @@ py:=getInstallationDirectoryPath() + "/share/doc/omc/testmodels/generate_icons.p |
81 | 79 |
|
82 | 80 | // adrpo: do not run the python stuff when running the testsuite |
83 | 81 | if getEnvironmentVar("GenerateDocTest") == "YES" then |
84 | | - if not os.path.exists("Icons"): |
85 | | - os.mkdir("Icons") |
| 82 | + system("mkdir -p Icons"); |
86 | 83 | else |
87 | | - commands:={"python "+py+" --quiet --output-dir Icons "+typeNameString(cl) for cl in reversed(getClassNames(builtin=false))};getErrorString(); |
| 84 | + commands:={"python "+py+" --quiet --output-dir Icons "+typeNameString(cl) for cl in getClassNames(builtin=false)};getErrorString(); |
88 | 85 | res:=system_parallel(commands);getErrorString(); |
89 | 86 | //system("rm -f *.json");getErrorString(); |
90 | 87 | end if; |
@@ -459,11 +456,15 @@ echo(shouldEcho); |
459 | 456 | system("rm -f tidy.links tidy.out tidy.err tidy.filtered"); |
460 | 457 |
|
461 | 458 | "Copying original HTML files to 'old-html-tmp'"; |
462 | | -oldtmp = "old-html-tmp" |
| 459 | +writeFile("copyold.py","#!/usr/bin/env python |
| 460 | +import shutil |
| 461 | +oldtmp = 'old-html-tmp' |
463 | 462 | if not os.path.exists(oldtmp): |
464 | 463 | os.mkdir(oldtmp) |
465 | 464 | for file in glob.glob('*.html'): |
466 | 465 | shutil.copy(file, oldtmp) |
| 466 | +"); |
| 467 | +system("python copyold.py"); |
467 | 468 |
|
468 | 469 | "Tidy.py"; |
469 | 470 | system("python Tidy.py 2> tidy.err"); |
|
0 commit comments