From e57093d37a79a7b34644b21a169d1e312f4d5f0c Mon Sep 17 00:00:00 2001 From: Mike Aizatsky Date: Fri, 3 Mar 2017 14:10:33 -0800 Subject: [PATCH] [infra] don't use temp file --- infra/libfuzzer-pipeline.groovy | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/infra/libfuzzer-pipeline.groovy b/infra/libfuzzer-pipeline.groovy index 3760f1212..64fa8e285 100644 --- a/infra/libfuzzer-pipeline.groovy +++ b/infra/libfuzzer-pipeline.groovy @@ -71,10 +71,10 @@ def call(body) { sh "docker build --no-cache -t $dockerTag -f checkout/$dockerfile checkout/$dockerContextDir" // obtain srcmap - sh "docker run $dockerRunOptions --rm $dockerTag srcmap > $workspace/srcmap.json.tmp" + def srcmapJsonStr = sh(returnStdout: true, + script: "docker run $dockerRunOptions --rm $dockerTag srcmap").trim() // use classic slurper: http://stackoverflow.com/questions/37864542/jenkins-pipeline-notserializableexception-groovy-json-internal-lazymap - def srcmap = new groovy.json.JsonSlurperClassic().parse( - new File("$workspace/srcmap.json.tmp")) + def srcmap = new groovy.json.JsonSlurperClassic().parse(srcmapJsonStr) srcmap['/src'] = [ type: 'git', rev: dockerfileRev, url: dockerGit,