Open delanni opened 4 years ago
You can find publishing options here. Have a look at the version policy section. This feature allows you to publish subsets of package. Does that take care of this issue ?
Unfortunately no. We've tried out the version policy feature, but it didn't seem like the feature/tool we actually need for our use-case.
As far as we understand, with version policies, you can prescribe a subset of packages to follow certain version bumping rules (as specified in the corresponding policy definition). What we wanted to do is at any time, when there are unpublished changes to packages {A, B, C, D} - we could decide to publish { A, C } for example, or { A, B, D }, or just { B } without having to rewrite some configuration. To my understanding, version policies are static in this sense.
Also - using version policies would require us to have completely unified version dependencies across the repository (I don't know if it was intended, but this check cannot be circumvented). This is a completely reasonable ask and target on the long run, but a HUGE undertaking for a repository that wants to jump on the Rush bike just now.
TL;DR: it doesn't seem like the feature I described.
This functionality is not currently available as you pointed out. If you have some time please feel free to take a stub and we can help with your PR.
@apostolisms
I agree with @delanni - this would be really nice to have. We have a similar situation where we might need to just publish a small subset of frontend pieces before we publish another package that lives in the monorepo. There are definitely times when we'll publish everything that changes, but it'd be nice to do it incrementally as well if needed.
As a workaround you can comment out the package definition(s) in rush.json
and run publish with --include-all
. Useful if one of the publish commands runs into an error halfway through.
Is this a feature or a bug?
Please describe the actual behavior. We're trying to bring in Rush to help our monorepo management. Now, we might be missing some key point, but we're puzzled because we don't find a way to only publish a subset of packages with the rush cli.
Here's a scenario: you have a bunch of teams working on their projects in a monorepo. Everyone contributes to the main development branch with their code changes as well as some sort of changesets they create with
rush change
. After this, we simply want to release one project/package (and it's upstream if there's any change in those packages). Rush (as far as we've seen so far) can only do a release from all the accumulated change descriptors, which is too eager and often meaningless for some projects in the repository because individual frontend bits might get released in their own pace.What is the expected behavior? Something in the lines of
rush release -a -p packageA --include-upstream
- this would only gobble up my requested package and it's upstream's change descriptors, and leave the rest untouched, waiting for another meaningful release.Is this something that's in line with Rush's philosophy? (I noted this is not something lerna wanted) Would you think there's room for a feature like this? I can try to issue a PR in case this is a liked feature.