I have a travis file (test file ) that builds different jobs depending on the build conditions set. However, all the job builds get performed, which can only suggest that the build (if) condition is resolving to true. Here is an example of one of the jobs;
- stage: waaoathxx
name: "Build WAAOATHXX Docker Image"
if: env(TRAVIS_COMMIT_MESSAGE) =~ /waaorchservices/
script:
- echo $BUILD_BRANCH
- echo $TRAVIS_COMMIT_MESSAGE
- echo "waaoathxx"
- stage: waaoathxxx
name: "Build WAAOATHXXX Docker Image"
script:
- echo $BUILD_BRANCH $TRAVIS_COMMIT_MESSAGE
- echo "waaoathxxx"
if: $TRAVIS_COMMIT_MESSAGE =~ /waaorchservices/
- stage: waaoathxxxx
name: "Build WAAOATHXXXX Docker Image"
if: env($TRAVIS_COMMIT_MESSAGE) =~ /waaorchservices/
scrit:
- echo $BUILD_BRANCH $TRAVIS_COMMIT_MESSAGE
- echo "waaoathxxxx"
The commit message is "test script [waa_full_build] … so if my understanding is correct none of these jobs should be performed, and in fact ignored.
Whats going wrong?