Skip to content

Allow rebase custom patch options for subcommits-started patch if from current branch#5801

Open
brandondong wants to merge 1 commit into
jesseduffield:masterfrom
brandondong:patch_branch
Open

Allow rebase custom patch options for subcommits-started patch if from current branch#5801
brandondong wants to merge 1 commit into
jesseduffield:masterfrom
brandondong:patch_branch

Conversation

@brandondong

Copy link
Copy Markdown
Contributor

PR Description

I was really confused as to why sometimes after creating a custom patch, the custom patch options menu would be missing some options like "Remove patch from original commit" or "Move patch out into index" even though they should be possible.

After playing around some more and looking at the code, it turns out this was due to my inconsistent muscle memory sometimes starting the custom patch from the branches -> subcommits view of the currently checked-out branch vs directly from the commits panel.

I don't think this discrepancy should exist. The two views are essentially semantically identical when drilling down on the current branch and all the rebase-related operations work in one versus the other.

This code change matches the two in behavior for showing of options.

Please check if the PR fulfills these requirements

  • Cheatsheets are up-to-date (run go generate ./...)
  • Code has been formatted (see here)
  • Tests have been added/updated (see here for the integration test guide)
  • Text is internationalised (see here)
  • If a new UserConfig entry was added, make sure it can be hot-reloaded (see here)
  • Docs have been updated if necessary
  • You've read through your own file changes for silly mistakes etc

…m current branch

Semantically, starting a custom patch from the commits panel vs the subcommits
panel of the currently checked-out branch should be identical. However, the
rebase-related options are currently hidden for the latter case. This code
change matches the two in behavior.
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.

1 participant