Skip to main content

engram-project-structure

Repository structure and placement rules for Engram. Trigger: Creating files, packages, handlers, templates, styles, or tests in this repo.

来源信息

仓库
Gentleman-Programming/engram
最近来源活动
2026年3月7日 19:29
检测到的 SKILL.md 语言
英语
星标
7,679
Forks
805

安装方式

默认使用会先检查来源的 Prompt;你也可以切换为直接命令,或下载本地副本。

检查来源文件

决定是否安装前,请先阅读 SKILL.md,以及 SkillsMP 当前展示的配套文件。

正在显示 SKILL.md

SKILL.md
来源说明 · 只读预览
name
engram-project-structure
description
Repository structure and placement rules for Engram. Trigger: Creating files, packages, handlers, templates, styles, or tests in this repo.
license
Apache-2.0
metadata
{"author":"gentleman-programming","version":"1.0"}
## When to Use Use this skill when: - Creating a new package, file, or directory - Deciding where code belongs - Adding tests, templates, assets, or docs --- ## Placement Rules 1. Put behavior near its domain, not near the caller that happens to use it. 2. Keep templates in `internal/cloud/dashboard/*.templ` and generated files checked in. 3. Keep dashboard styling in `internal/cloud/dashboard/static/styles.css` unless a new static asset is clearly needed. 4. Put HTTP handlers in server packages, not in store packages. 5. Put persistence queries in store/cloudstore, not in handlers. --- ## File Creation Rules - New route -> handler + tests in dashboard/server package - New DB behavior -> store/cloudstore code + focused tests - New UI partial/page -> templ component + generated `_templ.go` - New contributor guidance -> update docs/catalog in same change --- ## Anti-Patterns - Do not mix SQL, HTML, and transport logic in one file. - Do not create utility packages for one-off helpers. - Do not add package layers unless they remove real coupling.
在 GitHub 查看