fix(git): complete Git Log reference actions on Windows and macOS - #298
Merged
Conversation
1lck
requested changes
Aug 28, 2026
1lck
left a comment
Owner
There was a problem hiding this comment.
整体方向是对的,分层和完整 ref 传递也比较清楚。不过下面几个边界场景会直接影响功能正确性,建议合并前修掉。测试也建议从“只看参数”补到真实本地 remote 和实际菜单行为,这样后面排错会轻松很多。
| /// Checks out a local or remote branch, then rebases it onto the branch that | ||
| /// was current before the switch. A dirty tree is rejected before checkout so | ||
| /// the composite operation cannot leave the repository half-switched. | ||
| fn checkout_and_rebase( |
Owner
There was a problem hiding this comment.
这段流程继续放进 3400+ 行的 git/mod.rs,后面会越来越难维护,也不符合仓库的 facade 约定。建议移到 git/mutations.rs(或现有 owning module),这里保留 dispatch 就够了。
Owner
There was a problem hiding this comment.
这条目前还没有完全解决:remote_branch_components 已经移到了 git/mutations.rs,但新增的 checkout_and_rebase 复合 mutation 流程仍然放在 git/mod.rs。请把这部分流程也移到 git/mutations.rs(或对应的 owning module),让 git/mod.rs 只保留 dispatch/facade;完成后再标记此讨论为 resolved。
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Addresses all implementation items in #293.
Validation
git diff --checkpassedEnvironment limitation
The current host is Windows and has no Swift or zsh toolchain, so
scripts/test-macos.sh, the macOS timing harness, and Swift compilation could not be run locally. A deterministic macOS GitFeatureModel test was added for full remote reference identity and both pull strategies; macOS CI should execute it.