14
you are viewing a single comment's thread
view the rest of the comments
view the rest of the comments
this post was submitted on 07 Mar 2025
14 points (93.8% liked)
Programming
18728 readers
558 users here now
Welcome to the main community in programming.dev! Feel free to post anything relating to programming here!
Cross posting is strongly encouraged in the instance. If you feel your post or another person's post makes sense in another community cross post into it.
Hope you enjoy the instance!
Rules
Rules
- Follow the programming.dev instance rules
- Keep content related to programming in some way
- If you're posting long videos try to add in some form of tldr for those who don't want to watch videos
Wormhole
Follow the wormhole through a path of communities !webdev@programming.dev
founded 2 years ago
MODERATORS
That's not what I need, I can just abort the rebase in this case and I'd get back my branch as it was before I started, but I explicitly want to go to a state in the middle so not as to lose the modifications that I did intend to do.
Aside from that, I also do that, have seen what hell can be like in rebasing, so knowing where you started is always valuable, I agree
That's maybe something I think is sus. If it's at all possible, make a before-rebase branch, and make a small change in a rebase, check that the results are the same, then do another. I wrote git-test specifically for this work flow. (it runs tests, but only if the tree is one or hasn't seen before)
https://github.com/spotify/git-test
My issue wasn't so much if it managed to run and more of "I don't want this change to have happened here" kind of thing, still that's a neat tool! I wish I could use it, but the codebase I'm working on is in such a hugely sorry state, no testing suite set up is the last of the many problems that most likely won't be solved because they're not "important enough", not like features (built with cardboard and duct tape), yeah we can't allocate much time at all to code quality and general work for the project infrastructure if we can call it that.
About the generic advice of making smaller rebases one by one, yes, I'll learn to do that, I also solved it like that in the end
@QuazarOmega I don't know for sure, sorry. Like someone said on that link, the reflog should have a record, but you'll need to either abort the rebase and then pick out the right commit, or forcibly kill git's tracking of the rebase operation. When I know a rebase is going to be long and complicated, I'll break it down into multiple rebases.