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
I have branch kg-fix-switch and its child branch kg-test
I have just shipped branch kg-fix-switch at the remote
I have run git sync. It has deleted my local kg-fix-switch branch but ran into merge conflicts for branch kg-test. I ran git town skip to skip resolving these merge conflicts because I want to delete branch kg-test.
I now have branch kg-test checked out
I run git kill
expected behavior: it kills branch kg-test
actual behavior: I get this error:
[kg-test] git fetch --prune --tags
[kg-test] git push origin :kg-test
To github.com:git-town/git-town.git
- [deleted] kg-test
[kg-test] git checkout kg-sort-linter
Switched to branch 'kg-sort-linter'
Your branch is up to date with 'origin/kg-sort-linter'.
Error: cannot determine if branch "kg-test" has unmerged commits:
----------------------------------------
Diagnostic information of failed command
COMMAND: git log kg-fix-switch..kg-test
ERROR: exit status 128
OUTPUT START
fatal: ambiguous argument 'kg-fix-switch..kg-test': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
OUTPUT END
----------------------------------------
To continue after having resolved conflicts, run "git-town continue".
To go back to where you started, run "git-town undo".
The text was updated successfully, but these errors were encountered:
The problem is that in order to determine whether kg-test has unmerged commits, it diffs this branch against its former parent (kg-fix-switch). This branch no longer exists, causing the error. It should diff against the new parent of kg-test, which is main.
This is hitting an edge case where "git-town skip" doesn't work anymore: when "git sync" deletes a remotely shipped branch. The implementation of "git town skip" relies on assumptions that are no longer true when "git sync" deletes branches. This sparsely used command should have been removed when the "git sync" changes shipped, since it incentivizes anti-patterns like leaving particular branches unsynced.
kevgo
changed the title
error when killing a branch that has a shipped parent
error when killing a branch that has a shipped parent after "git skip"
Feb 2, 2024
kg-fix-switch
and its child branchkg-test
kg-fix-switch
at the remotegit sync
. It has deleted my localkg-fix-switch
branch but ran into merge conflicts for branchkg-test
. I rangit town skip
to skip resolving these merge conflicts because I want to delete branchkg-test
.kg-test
checked outgit kill
expected behavior: it kills branch
kg-test
actual behavior: I get this error:
The text was updated successfully, but these errors were encountered: