Skip to content

Commit 80592f0

Browse files
Updating Jenkinsfile to try building for second time
1 parent b440fc6 commit 80592f0

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

Jenkinsfile

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -199,7 +199,20 @@ pipeline
199199
bat 'dir'
200200
unstash 'source'
201201
bat 'dir'
202-
bat 'Build.bat -DRUNCPP2_BUILD_TESTS=ON'
202+
script
203+
{
204+
try
205+
{
206+
bat 'Build.bat -DRUNCPP2_BUILD_TESTS=ON'
207+
}
208+
catch(error)
209+
{
210+
echo "Build failed. Maybe .pdb is locked? Retrying..."
211+
sleep 5
212+
bat 'Build.bat -DRUNCPP2_BUILD_TESTS=ON'
213+
}
214+
}
215+
203216
stash 'windows_build'
204217
}
205218
post { failure { script { FAILED_STAGE = env.STAGE_NAME } } }

0 commit comments

Comments
 (0)