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

Add instructions on what to do when there are still staged changes after running git absorb #21

Open
danielcompton opened this issue Jul 15, 2019 · 3 comments

Comments

@danielcompton
Copy link

I ran git absorb and it created a number of fixup commits, but still left many staged changes. The documentation doesn't say what to do here, or what this means. I'm assuming that it means that absorb couldn't find any existing commits to fixup?

It could be good to explain what this means in the documentation, and give suggested remediation steps. If you have any staged changes then you can't proceed to the next step of git rebase -i --autosquash.

Apologies if I'm misunderstanding something!

@tummychow
Copy link
Owner

tummychow commented Jul 16, 2019

I'm assuming that it means that absorb couldn't find any existing commits to fixup?

yep, this understanding is correct. absorb will leave things in the index if it couldn't find a place to absorb them into.

i believe nickolay actually added some logging for this in #17 , which i just cut into a new release (https://github.com/tummychow/git-absorb/releases/tag/0.5.0) - give that a try and let me know what you think?

@nunofgs
Copy link

nunofgs commented Dec 19, 2022

It would be awesome to have some sort of interactive mode. Maybe a flag -i to force git-absorb to ask you which commit to place the changes.

Edit: maybe even an interactive mode such as git's patch staging mode (git add -p). It could show you each chunk and it would ask me which commit I'd like to absorb into. I could then decide to "split chunks", "do nothing" or choose a commit from the list.

@tummychow
Copy link
Owner

tummychow commented Dec 19, 2022

It would be awesome to have some sort of interactive mode. Maybe a flag -i to force git-absorb to ask you which commit to place the changes.

sorry but

  1. implementing all those prompts would be a colossal amount of work

  2. which is almost 100% redundant with the existing functionality of git rebase -i

if you want to arrange the commits manually, that's literally what interactive rebases are already for (e: which, by the way, is how git absorb itself actually works - if you only disagree with git absorb a little bit, you can do the rebase yourself and adjust the ordering that git absorb came up with, you don't need an entirely new user interface for that).

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

No branches or pull requests

3 participants