-
Notifications
You must be signed in to change notification settings - Fork 2
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
publish using github release version #48
Conversation
1301c51
to
95194e8
Compare
37947f5
to
a3cd21d
Compare
5de96ef
to
6cb70a0
Compare
@@ -64,16 +67,22 @@ workflows: | |||
ignore: main | |||
|
|||
publish: | |||
when: << pipeline.git.tag >> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this workflow will only run when a new tag is created; this tag corresponds to the version of the orb
@@ -35,6 +35,9 @@ parameters: | |||
|
|||
workflows: | |||
lint-pack: | |||
when: | |||
not: | |||
equal: [ main, << pipeline.git.branch >> ] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Doesn't this mean that this job will never run?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Itll only be ran on personal branches, so this is the check before you can merge
Is the recommended pattern to create the tag to have the author do it locally, and then push it up to |
@@ -48,7 +51,7 @@ workflows: | |||
requires: | |||
- orb-tools/pack | |||
- shellcheck/check | |||
vcs-type: github | |||
vcs-type: << pipeline.project.type >> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why this change?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pipeline.project.type
is always defined in Circle, I think it's cleaner to use envvar than have it hardcoded
@@ -50,6 +50,9 @@ jobs: | |||
|
|||
workflows: | |||
test-deploy: | |||
when: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How does this test-deploy
pipeline get used?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
after lint-pack
is done, it will trigger test-deploy
, so it is part of the personal branch pipeline
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you describe the handshake between this and the main config.yml
file, and that this is necessitated by circle.
I think it's easier to create tags off of the UI personally, that's how I instructed it in the README; but they could create it locally |
but the overall pattern to have it be updated this way was from |
.circleci/config.yml
Outdated
@@ -48,7 +51,7 @@ workflows: | |||
requires: | |||
- orb-tools/pack | |||
- shellcheck/check | |||
vcs-type: github | |||
vcs-type: << pipeline.project.type >> | |||
- orb-tools/continue: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you add a comment here referencing the test-deploy.yml file and the workflow there?
6cb70a0
to
16e115f
Compare
Description:
Previously workflow did not run on main because the key
setup: true
does not allow multiple workflows.Tested by creating tag
v2.6.15
and setting it togv-main-branch-filter
-- see pipeline here that triggered a publish workflowFrom Circle docs:
New version created here
To fix we added a filter mechanism on the tag level; this release tag also corresponds to the new version of the orb.
Also updated the docs and added in a filter mechanism to work with the git tag; since the git tags are not able to be filter it just looks if it begins with
v
; however, the tag needs to have the format ofvX.X.X
in order to publish a new version. See CI thread hereWe have to add this filter on both the
workflow
level and thejob
level of thepublish
workflow because there is a bug in [CircleCI] (circleci/circleci-docs#6148 (comment))The New Workflow for Publishing Production Version Orbs
When an orb is merged the author needs to create a new release tag off of main. After it is created, this new tag will trigger a pipeline run to publish the new orb with the same version as the github tag version. The version must be in the format of
vX.X.X
Previously; we would update the version of the orb using the PR body and including a semver version in the title; the orb would read the PR's title and update based on that.
To Do:
add descrion for /continue workflow and test-deploy
Note:
Lots of commits because each git tag needed a new commit to test
The
continuation
in thelint-pack
workflow is what triggers thetest-deploy
yaml file. The workflow continues by trigger everything in thelint-pack
and when it is completed will automatically triggertest-deploy
. Full description of how this workflow work is described inorb-tools
here