-
Notifications
You must be signed in to change notification settings - Fork 248
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
chore(ci): ignore private repositories (esp. backstage app, backend) when release plugins #1510
chore(ci): ignore private repositories (esp. backstage app, backend) when release plugins #1510
Conversation
29a2193
to
114c31a
Compare
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.
lgtm! Should we maybe document this in CONTRIBUTING.md
that if someone includes an example app/backend they should add "ignore": ["app", "backend"]
in the respective workspace's .changeset/config.json?
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.
Hi @jerolimov, thanks for running with this! I was wondering if would it be possible to leverage the private
property in the package.json
to drive this? Packages with private: true
don't get published which in turn means they don't need to be versioned. Using this would mean that we don't have to manually maintain this list in the .changeset/config.json
.
Some of them do have So I think setting the private property to true prevents the package from being published but a Version Packages PR is still made for it. |
Yes, I had the same hope but couldn't find another solution yet. As said, I also tried first to run yarn changeset version --ignore app --ignore backend, but it works only fine on projects with an backstage app, but fail on these without. |
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.
Hi @jerolimov, I've since found this: changesets/changesets#1093 (comment). Can we try that instead, please?
If this works we should update this as well: https://github.com/backstage/community-plugins/blob/main/workspaces/repo-tools/packages/cli/src/lib/workspaces/.changeset/config.json
Thanks, that's a better approche! I'm looking into this. But after adding "privatePackages": {
"tag": false,
"version": false
} with and without updating @changeset/cli it crashes:
I'll move this to a draft and keep you updated. |
114c31a
to
2997439
Compare
e49cdd0
to
9665078
Compare
Thanks for the detailed follow up @christoph-jerolimov! Let's go with this:
The |
9665078
to
10bb718
Compare
I rebased this PR and applied this change. This mean
Thanks for your patience and let me know if I should address something else. |
40174f1
to
a1cc6ee
Compare
@awanlin can you take a fresh look? Thanks :) |
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.
Hi @christoph-jerolimov, something seems to have gone wrong or I misunderstood the direction forward. None of the changes in this PR are using privatePackages
and they are all still using ignore
, also there are no repo-tool
or mend
changes. Can you take another look, please?
Oh what a shame. Sorry, i switched between my pc and notebook and it looks like I rebased the old version. I will take a look later today. |
a1cc6ee
to
8279e37
Compare
Changed Packages
|
Fixed. (Rebased on the right machine. Code reviews are a life saver.) |
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.
Super close, if you can just remove the repo-tools
changeset then we should be good to merge.
…when release plugins Signed-off-by: Christoph Jerolimov <[email protected]>
8279e37
to
af4f860
Compare
Sure. I've removed the file and rebased the 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.
Alright, let's get this in place. Thanks again for all your work back and forth on this @christoph-jerolimov 🙏
Hey, I just made a Pull Request!
This fixes #1508 by adding this configuration all changeset
config.json
s:See changesets/changesets#1093 (comment) and https://github.com/changesets/changesets/blob/main/packages/cli/CHANGELOG.md#2251
I tried this locally in the npm package, which contains a changeset and a backstage app.
Without this ignore list it touches these files:
With this change, it touches only:
I noticed that the changeset CLI crashes if a workspace contains only private packages and plugins. As discussed, I raise another PR to fix that for the npm plugin.
✔️ Checklist
Signed-off-by
line in the message. (more info)