mirror of
https://github.com/Mercury-Language/mercury.git
synced 2026-04-19 11:23:46 +00:00
Estimated hours taken: 0.5
Avoid about half of the slow "mmake realclean"s required by a bootcheck.
tests/*/runtests:
Concentrate all the actions performed before the test and after
a successful tests (both of which involve an "mmake realclean")
into two scripts, tests/{startup,shutdown}.
tests/shutdown:
Clean up the directory, and touch the file CLEAN.
tests/startup:
If the file CLEAN exists and is the most recent file in the directory,
consider the directory clean to beging with. Otherwise, run mmake
realclean.
9 lines
225 B
Plaintext
9 lines
225 B
Plaintext
echo cleaning up the directory before the tests
|
|
if ls -lt | head -2 | egrep CLEAN > /dev/null 2>&1
|
|
then
|
|
rm -f CLEAN > /dev/null 2>&1
|
|
else
|
|
rm -f CLEAN > /dev/null 2>&1
|
|
mmake $gradeopt $jfactor realclean > /dev/null 2>&1
|
|
fi
|