Repository navigation
feat: Git 根初始化写入 checkout 隔离硬约束 - #127
Merged
Merged
Conversation
edges init 只把这条约束写进 Git 根(含 worktree 根)的系统入口。 下层入口不写。已有手写硬约束不覆盖;仍是两句通用种子时,再次 init 补上这一句。 Co-authored-by: Cursor Agent <cursoragent@cursor.com> Co-authored-by: Cheng Peng <VirusPC@users.noreply.github.com>
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars.
|
只在新建 Git 根入口时写入。刷新已有文件,包括缺硬约束区块时补种子,都不加这一行。 Co-authored-by: Cursor Agent <cursoragent@cursor.com> Co-authored-by: Cheng Peng <VirusPC@users.noreply.github.com>
skill 正文不再复述这条规则。Git 根新建入口的硬约束以 AGENTS.tmpl.md 为准。 Co-authored-by: Cursor Agent <cursoragent@cursor.com> Co-authored-by: Cheng Peng <VirusPC@users.noreply.github.com>
这条记忆的正文和 frontmatter 都回到 main 上的原样,不再出现在本 PR。 Co-authored-by: Cursor Agent <cursoragent@cursor.com> Co-authored-by: Cheng Peng <VirusPC@users.noreply.github.com>
按时间追加到 project_design_decisions。作者 frontmatter 仍是 viruspc。 Co-authored-by: Cursor Agent <cursoragent@cursor.com> Co-authored-by: Cheng Peng <VirusPC@users.noreply.github.com>
VirusPC
added a commit
that referenced
this pull request
Nov 14, 2026
把 #127 收进补丁:edges init 只在新建 Git 根 AGENTS.md 时写入 checkout 隔离硬约束,已有文件不回填。随包技能 edges 仍是 0.4.6。 Co-authored-by: Cursor Agent <cursoragent@cursor.com> Co-authored-by: Cheng Peng <VirusPC@users.noreply.github.com>
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.
做了什么
edges init的官方模板packages/skills/edges/references/memory/references/templates/AGENTS.tmpl.md增加一条 Git 根专用的 checkout 隔离硬约束。模板用<!-- git-root-constraint -->标出这一行,落盘时去掉注释。这条规则的正文只在模板里。skill 说明不再复述规则内容和触发细节,memory-init.md与LAYOUT.md只写「Git 根新建入口的硬约束以AGENTS.tmpl.md为准」。为什么这样设,追加在
packages/skills/edges/references/memory/.edges/memory/projects/project_design_decisions/INDEX.md的「2026-11-14:Git 根新建入口的隔离硬约束以模板为唯一事实源」。没有另开记忆条目,也没有改project_agents_three_blocks。该文件的作者仍是 viruspc。本仓根
AGENTS.md里原来的 worktree 短句改成同一句。下层AGENTS.md没有加这句。随包技能
edges升到 0.4.6,并写了 changelog。@viruspc/edges的包版本没有升,变更记在 CLI 与根 changelog 的 Unreleased。dist/由构建时的copy-memory-templates.ts从模板真源复制,不手改、不入库。没有把「本仓内容变更走 PR」写进通用种子。全局安装要换仓内 tracked 副本时另开 PR 已经在这句里。init 也会用在不走 PR 的目录上,所以不把「所有内容变更都走 PR」做成每份新入口的默认硬约束。
合入 main 时再打
skill/edges@0.4.6。这个 PR 不打 tag,也不合并。init 现在怎么写
只在新建 Git 根的
AGENTS.md时写入。普通仓库的.git目录和 worktree 根上的.git文件都算。AGENTS.md:硬约束种子是原来的两句,加上这一句。AGENTS.md一律不补这一句。缺硬约束区块时补上的仍是两句通用种子。老仓库要加这句话,人手改或另开 PR。验证
packages/cli下跑过新建 Git 根、worktree 根、下层、无 Git,以及已有文件(含缺硬约束区块)的 init 测试。这次只追加设计决策,没有改 CLI,也没有加测试。