You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When switching between branches, Squot creates private commits that stash away (without using the git stash) the uncommitted changes. These commits naturally have the branch tip as their parent commit.
However, when the history of the branch is later rewritten, the stash commit stays at the original tip of the branch. Currently, in #switchAndMoveUnsavedChangesOverTo:, the stash version is simply loaded, which might unnecessarily load an out-of-date version of the branch. Instead, the stashed changes should be cherry-picked (without saving/committing) to the current branch tip.
For performing merges on the Squot code itself, this is important because it might break loading altogether. For other projects that merely use Squot, it might simply confuse the users because they may see vast diffs and do not know where they come from. But unnecessary patching of the memory is always a bad thing in case something goes wrong.
This is related to #160, but it is not the same problem from a functional perspective. Here the situation is that the head commit has "moved" in the history, so there is an "equivalent" version in the branch and the unsaved changes should be preserved, whereas in #160 the head was deliberately changed to another version, so it might be better to drop the unsaved changes.
The text was updated successfully, but these errors were encountered:
Even though the issue title clearly states "cherry-pick" I only made sure that the ancestry is not affected by the merging of the "unsaved" changes. So, it still merges all the changes up to the temporary commit, instead of cherry-picking just this commit. This is bad if the branch was reset to an earlier commit. The changes discarded from the branch will be loaded again when Squot switches to the branch. Reopening.
When switching between branches, Squot creates private commits that stash away (without using the git stash) the uncommitted changes. These commits naturally have the branch tip as their parent commit.
However, when the history of the branch is later rewritten, the stash commit stays at the original tip of the branch. Currently, in #switchAndMoveUnsavedChangesOverTo:, the stash version is simply loaded, which might unnecessarily load an out-of-date version of the branch. Instead, the stashed changes should be cherry-picked (without saving/committing) to the current branch tip.
For performing merges on the Squot code itself, this is important because it might break loading altogether. For other projects that merely use Squot, it might simply confuse the users because they may see vast diffs and do not know where they come from. But unnecessary patching of the memory is always a bad thing in case something goes wrong.
This is related to #160, but it is not the same problem from a functional perspective. Here the situation is that the head commit has "moved" in the history, so there is an "equivalent" version in the branch and the unsaved changes should be preserved, whereas in #160 the head was deliberately changed to another version, so it might be better to drop the unsaved changes.
The text was updated successfully, but these errors were encountered: