Skip to content

Commit e7cddc3

Browse files
authored
Merge pull request #11 from nirukk52/chore/remove-demo-scaffold
chore(scaffold): remove demo feature and sample package [cost:0]
2 parents d777115 + 65b36b4 commit e7cddc3

File tree

14 files changed

+1221
-10
lines changed

14 files changed

+1221
-10
lines changed

.github/CODEOWNERS

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
# Default owners
2+
* @priyankalalge
3+
4+
# Packages
5+
/packages/** @priyankalalge
6+
7+
# Features
8+
/packages/features/** @priyankalalge
9+
10+
# Apps
11+
/apps/** @priyankalalge
12+
13+

.github/PULL_REQUEST_TEMPLATE.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
## Summary
2+
3+
- What changed and why?
4+
5+
## Checklist
6+
7+
- [ ] Conventional Commit in PR title
8+
- [ ] Boundaries respected (no cross-feature imports; contracts→domain→application→infra only)
9+
- [ ] No exported string literals outside contracts/tests
10+
- [ ] All external inputs validated (zod) and unknowns normalized
11+
- [ ] Unit tests for logic branches; integration tests for routes/workers
12+
- [ ] Updated claude.md (Purpose, Inputs, Outputs, Ports, Adapters, Memory Hooks)
13+
- [ ] ADR added/updated if ports/adapters or boundaries changed
14+
- [ ] Diagrams align with docs/architecture/flow.md (canonical)
15+
16+
## Links
17+
18+
- ADR:
19+
- Issue:
20+
- Diagram:
21+
22+

.husky/commit-msg

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
#!/bin/sh
2+
. "$(dirname "$0")/_/husky.sh"
3+
4+
npx --yes commitlint --edit "$1"
5+
16
#!/bin/sh
27

38
commit_msg_file="$1"

commitlint.config.cjs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
module.exports = {
2+
extends: ["@commitlint/config-conventional"],
3+
};

docs/adr/0000-template.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# ADR-YYYYMMDD-xxxxxxxx — <Title>
2+
3+
Date: YYYY-MM-DD
4+
Status: proposed | accepted | superseded: ADR-<id>
5+
Trace: adr-fixed-trace-id
6+
7+
## Context (≤80 words)
8+
Briefly describe the problem, constraints, and relevant background.
9+
10+
## Options
11+
- A) <Option A>
12+
- Pros: <≤3>
13+
- Cons: <≤3>
14+
- B) <Option B>
15+
- Pros: <≤3>
16+
- Cons: <≤3>
17+
- C) <Option C>
18+
- Pros: <≤3>
19+
- Cons: <≤3>
20+
21+
## Decision
22+
What we chose and why.
23+
24+
## Rationale (exactly 3 bullets)
25+
- Reason 1
26+
- Reason 2
27+
- Reason 3
28+
29+
## Consequences / Next Steps (3–5 bullets)
30+
- Step 1
31+
- Step 2
32+
- Step 3
33+
34+
## Cross-module impact
35+
- :data
36+
- :backend
37+
- :ui
38+
- :agent
39+
- :infra
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# Contract Source of Truth
2+
3+
- `docs/architecture/flow.md` is the canonical diagram source.
4+
- All events, enums, and DTOs must be defined in `packages/agents-contracts`.
5+
- If a value is not in `agents-contracts`, it does not exist. Avoid string literals at application/infra edges.
6+
- UI and API must only consume contracts from `agents-contracts`.

docs/retro/milestone-1.md

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
# Milestone 1 — Scaffolding and Boundaries (Retro)
2+
3+
## Planned
4+
- Scaffold CLI and templates (packages/features) with runnable harness stub
5+
- Boundary metadata via sg:layer/scope + architecture checks
6+
- ESLint/size/literal guardrails; commitlint + PR template; CODEOWNERS
7+
- Docs: ADR template; contract source-of-truth; canonical diagrams note
8+
9+
## Delivered
10+
- Scaffold CLI: `tooling/scripts/scaffold/index.ts`
11+
- Arch checks: `tooling/arch/check-arch.js`, `check-sizes.js`, `check-literals.js`
12+
- Scripts: `lint:arch`, `scaffold` in root package.json
13+
- Git hygiene: commitlint, Husky commit-msg, PR template, CODEOWNERS
14+
- Docs: `docs/adr/0000-template.md`, `docs/architecture/contract-source-of-truth.md`
15+
16+
## What went well
17+
- Metadata-based boundaries enable refactors without path-coupling
18+
- Zero-dep scripts keep CI fast and portable
19+
- Templates standardize src layout across all modules
20+
21+
## What didn’t
22+
- Function size detection is heuristic; may false-positive on complex syntax
23+
- `ts-node` dependency added for scaffold; acceptable trade-off
24+
25+
## Risks discovered
26+
- Mis-tagged sg:layer/scope can block builds; added clear error messages
27+
- Over-restrictive rules can slow iteration; rules can be relaxed per PR via ADR
28+
29+
## Follow-ups
30+
- Add ESLint switch-exhaustiveness or TS exhaustive switch helper
31+
- Provide sample feature creation walkthrough in docs
32+
- Add CI job to run `pnpm lint:arch` on PRs affecting `packages/**` or `apps/**`
33+
34+
## Links
35+
- PR: (fill after merge)
36+
- CI: (fill after merge)
37+
- Diagrams: `docs/architecture/flow.md`
38+
- ADR: `docs/adr/0000-template.md`

package.json

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,9 @@
1010
"clean": "turbo clean",
1111
"format": "biome format . --write",
1212
"test": "pnpm -r --if-present test",
13-
"prepare": "husky"
13+
"prepare": "husky",
14+
"lint:arch": "node tooling/arch/check-arch.js && node tooling/arch/check-sizes.js && node tooling/arch/check-literals.js",
15+
"scaffold": "ts-node tooling/scripts/scaffold/index.ts"
1416
},
1517
"engines": {
1618
"node": ">=20"
@@ -22,6 +24,9 @@
2224
"@types/node": "^24.7.2",
2325
"dotenv-cli": "^10.0.0",
2426
"husky": "^9.1.7",
27+
"@commitlint/cli": "^19.5.0",
28+
"@commitlint/config-conventional": "^19.5.0",
29+
"ts-node": "^10.9.2",
2530
"turbo": "^2.5.8",
2631
"typescript": "5.9.3"
2732
},
Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,12 @@
11
{
2-
"version": "1.0",
3-
"generatorVersion": "0.0.0",
4-
"generatedAt": "2025-10-12T21:35:32.241Z",
5-
"outputPath": "/Users/priyankalalge/RealSaas/Screengraph/supastarter-nextjs/packages/database/prisma/zod",
6-
"files": ["index.ts"],
7-
"directories": [],
8-
"singleFileMode": true,
9-
"singleFileName": "index.ts"
10-
}
2+
"version": "1.0",
3+
"generatorVersion": "0.0.0",
4+
"generatedAt": "2025-10-13T00:42:10.181Z",
5+
"outputPath": "/Users/priyankalalge/RealSaas/Screengraph/supastarter-nextjs/packages/database/prisma/zod",
6+
"files": [
7+
"index.ts"
8+
],
9+
"directories": [],
10+
"singleFileMode": true,
11+
"singleFileName": "index.ts"
12+
}

0 commit comments

Comments
 (0)