[commit: ghc] wip/jenkins: Don't use deleteDir (8a32b6c)
git at git.haskell.org
git at git.haskell.org
Fri Jul 28 16:45:00 UTC 2017
Repository : ssh://git@git.haskell.org/ghc
On branch : wip/jenkins
Link : http://ghc.haskell.org/trac/ghc/changeset/8a32b6c12362bf9b53e18fe8e9b5e10a01a680be/ghc
>---------------------------------------------------------------
commit 8a32b6c12362bf9b53e18fe8e9b5e10a01a680be
Author: Ben Gamari <ben at smart-cactus.org>
Date: Tue Jun 27 21:39:36 2017 -0400
Don't use deleteDir
I suspect it is the reason that builds have been mysteriously failing despite
all steps succeeding.
>---------------------------------------------------------------
8a32b6c12362bf9b53e18fe8e9b5e10a01a680be
Jenkinsfile | 16 ++++++++--------
1 file changed, 8 insertions(+), 8 deletions(-)
diff --git a/Jenkinsfile b/Jenkinsfile
index fee5743..7f366d5 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -229,12 +229,12 @@ def withTempDir(String name, Closure f) {
rm -Rf ${name} || true
mkdir ${name}
"""
- dir(name) {
- try {
+ try {
+ dir(name) {
f()
- } finally {
- deleteDir()
}
+ } finally {
+ sh "rm -Rf ${name}"
}
}
@@ -260,12 +260,12 @@ def withGhcBinDist(String targetTriple, Closure f) {
def metadata = readJSON file: "bindist.json"
sh "tar -xf ${metadata.tarName}"
sh "tar -xf ghc-testsuite.tar.xz"
- dir(metadata.dirName) {
- try {
+ try {
+ dir(metadata.dirName) {
f()
- } finally {
- deleteDir()
}
+ } finally {
+ sh "rm -R ${metadata.dirName}"
}
}
}
More information about the ghc-commits
mailing list