-
Notifications
You must be signed in to change notification settings - Fork 3.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Document the effect of using set -e
in .travis.yml or in scripts
#1672
Comments
This is discussed in https://docs.travis-ci.com/user/customizing-the-build/#Implementing-Complex-Build-Steps
If you have ideas on where to put this for more prominence, I'm happy to discuss that with you. |
What about using |
It would be good to mention that using |
@maelvalais actually, using |
RVM is not the only thing that can break when |
then maybe we could add something like |
Doing this can cause some internal travis commands to fail the entire build. It is not recommended, see: travis-ci/docs-travis-ci-com#1672 Also includes some mac-specific fixes. Signed-off-by: Ole Herman Schumacher Elgesem <[email protected]>
Found the culprit: rvm provides `cd` binary! See: touist/touist@5d7a327#diff-354f30a63fb0907d4ad57269548329e3R52 See: https://github.com/rvm/rvm/blob/ff63fa117bd05e581ecbf2b0378d9ddbb263deb1/scripts/cd#L14 See: travis-ci/travis-ci#8703 (comment) and travis-ci/travis-ci#8703 (comment) Install pip locally Fix: Travis on OSX swallows error logs See: travis-ci/travis-ci#6018 "never use set -e directly in .travis.yml" See: travis-ci/docs-travis-ci-com#1672 (comment) See: travis-ci/travis-ci#6307 (comment) On OSX, do sudo. On Linux, dont.
rvm (#6307) strikes back && On OSX do sudo, on Linux dont. Found the culprit: rvm provides `cd` binary! See: touist/touist@5d7a327#diff-354f30a63fb0907d4ad57269548329e3R52 See: https://github.com/rvm/rvm/blob/ff63fa117bd05e581ecbf2b0378d9ddbb263deb1/scripts/cd#L14 See: travis-ci/travis-ci#8703 (comment) and travis-ci/travis-ci#8703 (comment) Install pip locally Fix: Travis on OSX swallows error logs See: travis-ci/travis-ci#6018 "never use set -e directly in .travis.yml" See: travis-ci/docs-travis-ci-com#1672 (comment) See: travis-ci/travis-ci#6307 (comment) On OSX, do sudo. On Linux, dont.
Otherwise the build may stop unexpectedly because of being non-zero status in internal travis scripts. See travis-ci/docs-travis-ci-com#1672
Otherwise the build may stop unexpectedly because of being non-zero status in internal travis scripts. See travis-ci/docs-travis-ci-com#1672
Otherwise the build may stop unexpectedly because of being non-zero status in internal travis scripts. See travis-ci/docs-travis-ci-com#1672
Otherwise the build may stop unexpectedly because of being non-zero status in internal travis scripts. See travis-ci/docs-travis-ci-com#1672
By moving the set -e inside its own file, it should prevent Travis bugs where set -e prevents travis own error handling to pick up the logs See travis-ci/docs-travis-ci-com#1672 for more information
Note, we can't use `set -e` here, since build may stop unexpectedly because of benign non-zero status in internal travis scripts (see travis-ci/docs-travis-ci-com#1672).
travis-ci/docs-travis-ci-com#1672 Co-authored-by: Vitaly Chikunov <[email protected]>
It can cause weird behaviour: travis-ci/docs-travis-ci-com#1672 Co-authored-by: Vitaly Chikunov <[email protected]>
Using
set -e
in .travis.yml or in scripts can cause weird behaviour on Travis CI. It would be nice to give visibility on this in our docs.Thanks to @maelvalais for the suggestion!
The text was updated successfully, but these errors were encountered: