Skip to content
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

Create two separate workflows for circleci. #1082

Merged
merged 2 commits into from
Oct 3, 2018

Conversation

tryantwit
Copy link
Contributor

Description

Workflow that deploys requires a git tag to run. Adding a tag filter
would require all other tasks to have a tag as well. Splitting into two
workflows, the build-test flow can work on all branches/commits
while build-test-deploy only works when a git tag matching vX.X.X is pushed.

More Details

Git Tag Documentation

According to the documentation if using tag filters and a job requires any other job directly or indirectly, those jobs must also require regular expression filters for tags.

Corresponding Issue

#1075

Screenshots

Test Coverage

🚫

Workflow that deploys requires a git tag to run. Adding a tag filter
would require all other tasks to have a tag as well. Splitting into two
workflows, the build-test flow can work on all other branches/commits
while build-test-deploy only works when a git tag matching vX.X.X is pushed.
@julianguyen
Copy link
Member

Thanks sooo much for working on this! Question, does the regex for the tag version just mean we can only have single digits e.g. 2.2.0 but not 13.2.0?

only: master
ignore: /.*/
tags:
only: /^v[0-9]+\.[0-9]+\.[0-9]+/
Copy link
Member

Choose a reason for hiding this comment

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

Do we just want to have tags in the deploy job? Could you clarify why it's in the other jobs?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

According to CircleCI documentation on using tags if a job has a tag filter and relies on any other job, that one must have a tags filter as well. So since we want to use a filter tag in deploy, since it relies on upload-coverage which relies on build those jobs would require the filters tag as well. Or that's my interpretation on that at any rate.

Copy link
Member

Choose a reason for hiding this comment

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

Thanks for explaining!

@tryantwit
Copy link
Contributor Author

Regex means it has to match vX.X.X but any of the X can contain any number of characters that match [0-9]. So v12.2.1 is supported, as is something like v1.2.10000

Copy link
Member

@julianguyen julianguyen left a comment

Choose a reason for hiding this comment

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

LGTM!

@julianguyen julianguyen merged commit 3eea31c into ifmeorg:master Oct 3, 2018
@tryantwit tryantwit deleted the 1075-deploy-process branch October 3, 2018 18:56
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