mirror of
https://github.com/shlomif/PySolFC.git
synced 2025-04-05 00:02:29 -04:00
Extract a method or a function.
This is Refactoring / code cleanup. See: * https://refactoring.com/catalog/extractMethod.html * https://en.wikipedia.org/wiki/Code_refactoring * https://www.refactoring.com/ * https://www.joelonsoftware.com/2002/01/23/rub-a-dub-dub/ Some small optimisations may have slipped in as well.
This commit is contained in:
parent
6dfbdb1e61
commit
ea897ab8dc
1 changed files with 5 additions and 2 deletions
|
@ -16,10 +16,13 @@ import subprocess
|
||||||
|
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
|
def _make_test(make_exe):
|
||||||
|
subprocess.check_call([make_exe, "test", "rules"])
|
||||||
|
|
||||||
try:
|
try:
|
||||||
subprocess.check_call(["gmake", "test", "rules"])
|
_make_test("gmake")
|
||||||
except subprocess.CalledProcessError:
|
except subprocess.CalledProcessError:
|
||||||
subprocess.check_call(["make", "test", "rules"])
|
_make_test("make")
|
||||||
|
|
||||||
if not os.path.exists("./images"):
|
if not os.path.exists("./images"):
|
||||||
os.symlink("./data/images/", "./images")
|
os.symlink("./data/images/", "./images")
|
||||||
|
|
Loading…
Add table
Reference in a new issue