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

Closes #2959 autosquash commits in interactive rebases #4109

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

gabeseltzer
Copy link

@gabeseltzer gabeseltzer commented Feb 26, 2025

Description

Closes #2959

Adds the --autosquash flag to interactive rebases.

Note, I wasn't 100% sure if this is the right solution, but it works and was easy. As far as I know, there's no real downside to always using the autosquash feature. I had some other ideas but they were harder so I thought I'd PR and see what people thought. Here's the other options:

  1. Simply add --autosquash to the arguments for the existing --interactive line item for everyone. <<< This is what I did
  2. Simply add --autosquash to the arguments for the existing --interactive line item if users enable it with a vscode extension setting
  3. Add a new option that does both --interactive --autosquash, and show it all the time
  4. Add a new option that does both --interactive --autosquash, and only show it if there are fixup commits in your rebase range

Checklist

  • I have followed the guidelines in the Contributing document
  • My changes follow the coding style of this project
  • My changes build without any errors or warnings
  • My changes have been formatted and linted
  • My changes include any required corresponding changes to the documentation (including CHANGELOG.md and README.md)
  • My changes have been rebased and squashed to the minimal number (typically 1) of relevant commits
  • My changes have a descriptive commit message with a short title, including a Fixes $XXX - or Closes #XXX - prefix to auto-close the issue that your PR addresses

@gabeseltzer gabeseltzer marked this pull request as ready for review February 26, 2025 18:33
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.

Add the "--interactive --autosquash" option for rebase
1 participant