Closed dhalperi closed 7 months ago
Hi! There is no direct way to do this for all dependencies automatically. What you can do, is pin each dependency using update-rules:
update-rules:
- dependencies: commons-io:commons-io
pin: "2."
- dependencies: com.typesafe.config
pin: "3."
It is now possible as a new bumping strategy.
Either patch-minor
- will bump to the latest patch before bumping major or minor-patch
- will first bump to the latest minor+patch and only if no newer minor is available, will bump patch.
Neither of these bump major.
configure it with
update-rules:
- bumping: minor-patch
it would set this strategy for all dependencies
This is cool, will check it out!
Does this work? e.g., https://github.com/batfish/batfish/actions/runs/7886257435/job/21519127953 still seems to be trying to upgrade major versions (bazel 7.0.2).
here's the config: https://github.com/batfish/batfish/blob/master/.bazel-steward.yaml
@dhalperi I am sorry for the confusion. The feature does work, the problem is with picking up your config file. Update your github actions with:
- uses: VirtusLab/bazel-steward@latest
with:
configuration-path: "./.bazel-steward.yaml"
Docs are confusing, as they state that you can use {.,}bazel-steward.y{a,}ml
as config name and bazel steward will pick it up. However this is only true if --configuration-path is not specified explicitly in the command line. The github action does specify a default configuration path as bazel-steward.yaml
and passes it as --configuration-path to Bazel Steward, thus the default detection logic doesn't kick.
We should clean up the definition of github action to by default use the CLI app default logic rather than always pass something in the --configuration-path flag.
Want to default all upgrades to only be same major version as current.