melos
melos copied to clipboard
feat: Add global dependency overrides
Description
Support global dependency_overrides (#439)
This allows to define dependency overrides for each workspace package in melos.yaml like:
name: foo
packages:
- packages/**
globalDependencyOverrides:
my_dependency: 1.2.3
Type of Change
- [x] โจ
feat-- New feature (non-breaking change which adds functionality) - [ ] ๐ ๏ธ
fix-- Bug fix (non-breaking change which fixes an issue) - [ ] โ
!-- Breaking change (fix or feature that would cause existing functionality to change) - [ ] ๐งน
refactor-- Code refactor - [ ] โ
ci-- Build configuration change - [ ] ๐
docs-- Documentation - [ ] ๐๏ธ
chore-- Chore
To view this pull requests documentation preview, visit the following URL:
Documentation is deployed and generated using docs.page.
Hint:
The added globalDependencyOverrides and the existing dependencyOverridePaths do add the dependency override(s) to all workspace packages. This means packages that do not have a regular or dev dependency also get the override(s) which seems to be bad. Is this behaviour intended?
@jtdLab Thanks for this contribution!
We already have dependencyOverridePaths . Could you make the new option a sibling of that one? I think dependencyOverrides would be enough as its name. Please also document the new option.
Is this behaviour intended?
Yes. Often, dependency overrides are used to override transitive dependencies.
@blaugold i am no sure about the docs is it only the overview page which needs an update?
Any updates on this?
@blaugold @Salakar can some check this pr?
@jtdLab this is offering the same functionality as #594 right?
I'll close this since the functionality will be implemented with the new system in 594, thanks for the effort though!