mattbrictson / bundle_update_interactive

A stylish interactive mode for Bundler, inspired by `yarn upgrade-interactive`
MIT License
137 stars 3 forks source link

Add `--minor` and `--patch` options #33

Open dylnclrk opened 1 month ago

dylnclrk commented 1 month ago

Motivation

As discussed in #20, we would like a way to limit the risk of batch updates. The options --minor and --patch could be used to limit gem updates to the highest patch or minor level, which should mean no breaking changes.

Solution

Add the minor and patch options

Todo

mattbrictson commented 3 weeks ago

@dylnclrk FYI, there are a few recent and forthcoming changes to the codebase that might help out this PR.

Figure out a way to test calls to system in bundler_commands_test.rb

42 introduces an example of this.

Add a fixture + integration test to clearly test the patch/minor options.

If you want to go full end-to-end on these tests, a new pattern of integration test was added in #41 and will be expanded in #42.

Tidy the passing around of level in report.rb, is there a better way?

I think so! The reporting and bundle-updating concerns are being consolidated into an Updater class in #42. That should be one place where level lives; no more need to pass it around, I think.