Skip to content

Fix the deploy condition for missing spaces around equals sign #256

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

Merged
merged 1 commit into from
Jan 12, 2019

Conversation

shinglyu
Copy link
Contributor

I was stupid to forgot to add spaces around the equals signs in the previous PR #250 .

Clearly if you do $FOO=true, it is always evaluated as true in bash's if [[ ... ]] condition. (Reference)

I tested in a branch and now it seems to skip the deployment step properly: https://travis-ci.org/RustPython/RustPython/builds/478033185

@@ -101,7 +101,7 @@ deploy:
keep-history: true
on:
branch: release
condition: $DEPLOY_DOC=true
condition: $DEPLOY_DOC = true
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should it not be DEPLOY_DOC=true? Without the dollar symbol?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

on in the deployment section seems to be different from the if elsewhere. Here is the quote form the doc:

condition: deploy when a single bash condition evaluates to true. This must be a string value, and is equivalent to if [[ <condition> ]]; then <deploy>; fi. For example, $CC = gcc.

Here is a working build: https://travis-ci.org/RustPython/RustPython/builds/478843944 . The deployment steps failed because I set a bad token to avoid actually deploying. But the deployment step seems to kick-off correctly.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wow, this is pretty crappy, but good research!

@windelbouwman windelbouwman merged commit ade4c88 into master Jan 12, 2019
@windelbouwman windelbouwman deleted the fix-deployment-again branch February 15, 2019 16:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants