Skip to content
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

bookmarks: Make target revision a required argument to create/move/set #5527

Merged
merged 1 commit into from
Feb 11, 2025

Conversation

drieber
Copy link
Contributor

@drieber drieber commented Jan 30, 2025

This change is not backwards compatible, but it should be very easy to adapt to it.

This fixes
#5374
See also
#5363

Checklist

If applicable:

  • I have updated CHANGELOG.md
  • I have updated the documentation (README.md, docs/, demos/)
  • I have updated the config schema (cli/src/config-schema.json)
  • I have added tests to cover my changes

Copy link
Contributor

@yuja yuja left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks.

cli/src/commands/bookmark/create.rs Show resolved Hide resolved
cli/tests/test_git_fetch.rs~ Outdated Show resolved Hide resolved
@drieber drieber force-pushed the push-vqwusvyuutsl branch 3 times, most recently from b4610d5 to 0a590d7 Compare January 31, 2025 19:32
@arxanas
Copy link
Contributor

arxanas commented Jan 31, 2025

Should we make this a soft deprecation in the next version and a hard error in the subsequent version? It seems like it might break real interactive and non-interactive workflows in a frustrating way. It looks like the hard work of migrating all the tests is already done, so hopefully it's a small additional change?

@PhilipMetzger
Copy link
Contributor

Should we make this a soft deprecation in the next version and a hard error in the subsequent version? It seems like it might break real interactive and non-interactive workflows in a frustrating way

yes, that should be done and actually deprecated after 6 releases, like the rest of the user-visible command changes.

@drieber
Copy link
Contributor Author

drieber commented Feb 10, 2025

Should we make this a soft deprecation in the next version and a hard error in the subsequent version? It seems like it might break real interactive and non-interactive workflows in a frustrating way

yes, that should be done and actually deprecated after 6 releases, like the rest of the user-visible command changes.

Done.

@drieber drieber closed this Feb 10, 2025
@drieber drieber reopened this Feb 10, 2025
@drieber
Copy link
Contributor Author

drieber commented Feb 10, 2025

Sorry, I accidentally closed this PR. Reopening....

Copy link
Contributor

@PhilipMetzger PhilipMetzger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

last minor nits from me

cli/src/commands/bookmark/create.rs Show resolved Hide resolved
cli/src/commands/bookmark/create.rs Show resolved Hide resolved
CHANGELOG.md Outdated Show resolved Hide resolved
cli/src/commands/bookmark/move.rs Show resolved Hide resolved
…bookmark create/move/set.

With this change a warning is shown if the user does not explicitly specify the target revision, but the behavior is unchanged (it still defaults to the working copy).
In the future the warning will be turned into an error. In other words, it will be required to specify target revision.

The bulk of the changes here are to prepare tests for the upcoming change, to make the transition easier.

For additional details please see:
* #5374
* #5363
@drieber drieber added this pull request to the merge queue Feb 11, 2025
Merged via the queue into main with commit dd73b5a Feb 11, 2025
42 checks passed
@drieber drieber deleted the push-vqwusvyuutsl branch February 11, 2025 22:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants