Github stack does not persist across worktrees
- Ngôn ngữ chính
- Go
- Star
- 1.5k
- Fork
- 70
- Merge trung bình
- 1 ngày 8 giờ
- Pull request đã merge (30 ngày)
- 7
Mô tả
When opening a branch in a worktree and running `gh stack init`, it does not keep track of the stack locally. `gh-stack` keeps stack membership in local state tied to the checkout where `init` ran. If I create a worktree & use `gh-stack`, the stack doesn't persist on my machine, even if I open the branch back in my main worktree. Inside a worktree, $GIT_DIR is .git/worktrees// — so `worktree remove` deletes the stack state with it
This is confusing & not obvious. Additionally, a modern LLM workflow may involve different sub-agents in different worktrees. This makes gh-stack worse than, say git-spice for this purpose, since I can't easily update my work if I checkout the branch on my main worktree.
The stack _is_ stored remotely on Github, but THAT doesn't always work - seems like GitHub only records a stack for a chain of two or more PRs.
Hướng dẫn đóng góp
Hướng nghiên cứu
Bắt đầu từ entry point `gh stack init` và theo dõi cách membership của stack cục bộ được lưu trữ khi `$GIT_DIR` trỏ đến `.git/worktrees//`. Tái hiện hành vi giữa một worktree chính và một worktree được liên kết, bao gồm `worktree remove`; hoàn tất khi membership của stack vẫn khả dụng khi branch được mở từ một worktree khác.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Đánh giá
- Công nghệ
- git, github, go
- Lĩnh vực
- cli, tooling
- Loại issue
- Lỗi
- Độ khó
- 4/5
- Thời gian dự kiến
- 3-5 ngày
- Mức độ hoạt động
- Sôi nổi
- Độ rõ ràng
- Khá rõ ràng
- Mức phù hợp với người mới
- 52/100