Skip to content

Commit

Permalink
Use isUnix() for testing whether to use bat or sh
Browse files Browse the repository at this point in the history
Signed-off-by: Stewart X Addison <[email protected]>
  • Loading branch information
sxa committed Sep 10, 2024
1 parent ecbb95e commit 3107b76
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions pipelines/build/common/openjdk_build_pipeline.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -1503,10 +1503,10 @@ class Build {
*/
def batOrSh(command)
{
if ( buildConfig.TARGET_OS == 'windows' && buildConfig.DOCKER_IMAGE ) {
context.bat(command)
} else {
if ( context.isUnix() ) {
context.sh(command)
} else {
context.bat(command)
}
}

Expand Down

0 comments on commit 3107b76

Please sign in to comment.