Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
63 commits
Select commit Hold shift + click to select a range
e0fe4bc
Removed translations that are not available
csharpfritz Dec 3, 2024
d47a968
Updated favicon to be SharpSite S
csharpfritz Feb 17, 2025
885994c
Fix post date (#307)
csharpfritz Feb 18, 2025
f0c2391
Added test and delete button on post list (#308)
csharpfritz Feb 20, 2025
c682350
Update README.md - spelling & formatting
csharpfritz Feb 20, 2025
7e6ac63
Block duplicate plugin uploads (#310)
degenone Feb 27, 2025
cd08a93
Add a confirmation if script tag is in post/page (#311)
degenone Feb 27, 2025
7feac05
Updated to latest .NET stuff (#315)
csharpfritz Feb 27, 2025
ad0127c
Added a BlazorClick navigation tool for Playwright testing (#314)
csharpfritz Feb 27, 2025
30b97ba
Admin theme and initial out-of-the-box experience (#305)
csharpfritz Mar 6, 2025
5bdeef4
updated git describe to get most recent tag
csharpfritz Mar 11, 2025
8b528fc
Now loading defaultplugins on install
csharpfritz Apr 1, 2025
74b9fc5
Started injecting the ability to configure the database connectionstring
csharpfritz Apr 1, 2025
0ae747e
Added copilot instructions
csharpfritz Apr 3, 2025
0d1953b
Renamed ApplicationState
csharpfritz Apr 3, 2025
92b9294
Excluding the _plugins folder
csharpfritz Apr 3, 2025
65ced53
First pass at performing database migration
csharpfritz Apr 3, 2025
07a06be
Started working towards scaffolding methods
csharpfritz Apr 10, 2025
9b4cc8c
Started refactoring database configuration
csharpfritz Apr 10, 2025
6f7af93
Add SharpSite.Abstractions.DataStorage project to solution
csharpfritz Apr 11, 2025
c757d5d
Add project reference to SharpSite.Abstractions.Base in DataStorage p…
csharpfritz Apr 11, 2025
da157bc
Started on the Postgres storage plugin
csharpfritz Apr 24, 2025
0636735
WIP
csharpfritz Apr 24, 2025
9233194
Now configuring database plugin in Step 3
csharpfritz Apr 29, 2025
b07c6ce
Update README.md to enhance project description, system requirements,…
csharpfritz Jun 3, 2025
21a5b40
Enhance project documentation and UI for database configuration steps…
csharpfritz Jun 3, 2025
79810de
Add connection string parsing method and enhance database configurati…
csharpfritz Jun 3, 2025
3db7cac
Enhance database configuration UI by adding plugin selection and impr…
csharpfritz Jun 3, 2025
ad3886b
Moved SharpSite.Abstractions.Data into src folder
csharpfritz Jun 4, 2025
fcc1dd4
Fix project reference path in DataStorage project and remove commente…
csharpfritz Jun 4, 2025
278d525
Started migrating Security features into the database plugin
csharpfritz Jun 10, 2025
ad33f0e
Implement user management and sign-in functionality with plugin support
csharpfritz Jul 1, 2025
6633d15
Refactor security interfaces and implementations for improved plugin …
csharpfritz Jul 3, 2025
58d8c8f
docs(squad): Initialize SharpSite team Firefly cast
csharpfritz Mar 26, 2026
9f97b8c
docs(squad): Orchestration for Mal + River spawns
csharpfritz Mar 26, 2026
411b65a
Fix .NET 10/C# 14 breaking changes in plugin and src Security projects
csharpfritz Mar 26, 2026
a51d736
chore: Upgrade to .NET 10 and Aspire 13.2
csharpfritz Mar 26, 2026
401d856
Fix all build errors in SharpSite.sln
csharpfritz Mar 26, 2026
c2a8fd7
docs(squad): Add Squad infrastructure, skills, and GitHub workflows
csharpfritz Mar 26, 2026
91ee406
fix: pin port 5020 for Aspire web frontend in E2E test mode
csharpfritz Mar 26, 2026
fc733c4
docs: document Playwright CI fix and Aspire port learning
csharpfritz Mar 26, 2026
0d89583
fix: use unique endpoint name to avoid Aspire 'http' conflict
csharpfritz Mar 26, 2026
da67a1c
fix: use WithEndpoint callback to pin existing http endpoint to port …
csharpfritz Mar 26, 2026
8a7a4dd
Fix .NET 10 E2E test infrastructure
csharpfritz Mar 26, 2026
8556724
Fix EF Core 10 Claim binding, security DB creation, and middleware or…
csharpfritz Mar 27, 2026
6e6292b
docs(squad): Log issue triage session 6 issues routed
csharpfritz Mar 31, 2026
060fe20
fix: replace Newtonsoft.Json TypeNameHandling.Auto with System.Text.J…
csharpfritz Mar 31, 2026
1597cef
docs: add decision record for RCE fix (#346)
csharpfritz Mar 31, 2026
bc57137
docs(squad): Log River P0 RCE fix for #346
csharpfritz Mar 31, 2026
f98f520
fix: add ZIP bomb protection and path traversal prevention to plugin …
csharpfritz Mar 31, 2026
51097a0
docs(squad): Log #347 ZIP bomb fix and Kaylee security tests
csharpfritz Mar 31, 2026
d719ef9
fix: thread-safety for PluginManager, PluginAssemblyManager, Applicat…
csharpfritz Mar 31, 2026
3c1add7
docs(squad): Log #348 thread-safety fix
csharpfritz Mar 31, 2026
352ff8d
feat(security): Add assembly name validation and SHA-256 hash verific…
csharpfritz Mar 31, 2026
0d92576
docs: Record assembly validation decision and learnings
csharpfritz Mar 31, 2026
c52c02e
feat: add forced password reset after initial admin seed (#350)
csharpfritz Mar 31, 2026
7e1f212
docs(squad): Log #349 assembly validation + #350 password reset compl…
csharpfritz Mar 31, 2026
78272f4
fix(e2e): Handle ForceChangePassword flow and increase default timeouts
csharpfritz Mar 31, 2026
5ba02ad
fix(e2e): Set Playwright expect assertion timeout to 30s
csharpfritz Mar 31, 2026
d27182f
fix: Handle missing IPostRepository gracefully on home page
csharpfritz Mar 31, 2026
6bd5620
fix(e2e): Navigate to post via admin list instead of home page
csharpfritz Mar 31, 2026
8eeb1b9
fix(e2e): Verify post data via admin edit page instead of public display
csharpfritz Mar 31, 2026
02c20cd
merge: Resolve conflicts merging v0.7 into spike_DatabasePlugin
csharpfritz Mar 31, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
14 changes: 14 additions & 0 deletions .copilot/mcp-config.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"mcpServers": {
"EXAMPLE-github": {
"command": "npx",
"args": [
"-y",
"@anthropic/github-mcp-server"
],
"env": {
"GITHUB_TOKEN": "${GITHUB_TOKEN}"
}
}
}
}
42 changes: 42 additions & 0 deletions .copilot/skills/agent-collaboration/SKILL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
---
name: "agent-collaboration"
description: "Standard collaboration patterns for all squad agents — worktree awareness, decisions, cross-agent communication"
domain: "team-workflow"
confidence: "high"
source: "extracted from charter boilerplate — identical content in 18+ agent charters"
---

## Context

Every agent on the team follows identical collaboration patterns for worktree awareness, decision recording, and cross-agent communication. These were previously duplicated in every charter's Collaboration section (~300 bytes × 18 agents = ~5.4KB of redundant context). Now centralized here.

The coordinator's spawn prompt already instructs agents to read decisions.md and their history.md. This skill adds the patterns for WRITING decisions and requesting help.

## Patterns

### Worktree Awareness
Use the `TEAM ROOT` path provided in your spawn prompt. All `.squad/` paths are relative to this root. If TEAM ROOT is not provided (rare), run `git rev-parse --show-toplevel` as fallback. Never assume CWD is the repo root.

### Decision Recording
After making a decision that affects other team members, write it to:
`.squad/decisions/inbox/{your-name}-{brief-slug}.md`

Format:
```
### {date}: {decision title}
**By:** {Your Name}
**What:** {the decision}
**Why:** {rationale}
```

### Cross-Agent Communication
If you need another team member's input, say so in your response. The coordinator will bring them in. Don't try to do work outside your domain.

### Reviewer Protocol
If you have reviewer authority and reject work: the original author is locked out from revising that artifact. A different agent must own the revision. State who should revise in your rejection response.

## Anti-Patterns
- Don't read all agent charters — you only need your own context + decisions.md
- Don't write directly to `.squad/decisions.md` — always use the inbox drop-box
- Don't modify other agents' history.md files — that's Scribe's job
- Don't assume CWD is the repo root — always use TEAM ROOT
24 changes: 24 additions & 0 deletions .copilot/skills/agent-conduct/SKILL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
---
name: "agent-conduct"
description: "Shared hard rules enforced across all squad agents"
domain: "team-governance"
confidence: "high"
source: "reskill extraction — Product Isolation Rule and Peer Quality Check appeared in all 20 agent charters"
---

## Context

Every squad agent must follow these two hard rules. They were previously duplicated in every charter. Now they live here as a shared skill, loaded once.

## Patterns

### Product Isolation Rule (hard rule)
Tests, CI workflows, and product code must NEVER depend on specific agent names from any particular squad. "Our squad" must not impact "the squad." No hardcoded references to agent names (Flight, EECOM, FIDO, etc.) in test assertions, CI configs, or product logic. Use generic/parameterized values. If a test needs agent names, use obviously-fake test fixtures (e.g., "test-agent-1", "TestBot").

### Peer Quality Check (hard rule)
Before finishing work, verify your changes don't break existing tests. Run the test suite for files you touched. If CI has been failing, check your changes aren't contributing to the problem. When you learn from mistakes, update your history.md.

## Anti-Patterns
- Don't hardcode dev team agent names in product code or tests
- Don't skip test verification before declaring work done
- Don't ignore pre-existing CI failures that your changes may worsen
151 changes: 151 additions & 0 deletions .copilot/skills/architectural-proposals/SKILL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,151 @@
---
name: "architectural-proposals"
description: "How to write comprehensive architectural proposals that drive alignment before code is written"
domain: "architecture, product-direction"
confidence: "high"
source: "earned (2026-02-21 interactive shell proposal)"
tools:
- name: "view"
description: "Read existing codebase, prior decisions, and team context before proposing changes"
when: "Always read .squad/decisions.md, relevant PRDs, and current architecture docs before writing proposal"
- name: "create"
description: "Create proposal in docs/proposals/ with structured format"
when: "After gathering context, before any implementation work begins"
---

## Context

Proposals create alignment before code is written. Cheaper to change a doc than refactor code. Use this pattern when:
- Architecture shifts invalidate existing assumptions
- Product direction changes require new foundation
- Multiple waves/milestones will be affected by a decision
- External dependencies (Copilot CLI, SDK APIs) change

## Patterns

### Proposal Structure (docs/proposals/)

**Required sections:**
1. **Problem Statement** — Why current state is broken (specific, measurable evidence)
2. **Proposed Architecture** — Solution with technical specifics (not hand-waving)
3. **What Changes** — Impact on existing work (waves, milestones, modules)
4. **What Stays the Same** — Preserve existing functionality (no regression)
5. **Key Decisions Needed** — Explicit choices with recommendations
6. **Risks and Mitigations** — Likelihood + impact + mitigation strategy
7. **Scope** — What's in v1, what's deferred (timeline clarity)

**Optional sections:**
- Implementation Plan (high-level milestones)
- Success Criteria (measurable outcomes)
- Open Questions (unresolved items)
- Appendix (prior art, alternatives considered)

### Tone Ceiling Enforcement

**Always:**
- Cite specific evidence (user reports, performance data, failure modes)
- Justify recommendations with technical rationale
- Acknowledge trade-offs (no perfect solutions)
- Be specific about APIs, libraries, file paths

**Never:**
- Hype ("revolutionary", "game-changing")
- Hand-waving ("we'll figure it out later")
- Unsubstantiated claims ("users will love this")
- Vague timelines ("soon", "eventually")

### Wave Restructuring Pattern

When a proposal invalidates existing wave structure:
1. **Acknowledge the shift:** "This becomes Wave 0 (Foundation)"
2. **Cascade impacts:** Adjust downstream waves (Wave 1, Wave 2, Wave 3)
3. **Preserve non-blocking work:** Identify what can proceed in parallel
4. **Update dependencies:** Document new blocking relationships

**Example (Interactive Shell):**
- Wave 0 (NEW): Interactive Shell — blocks all other waves
- Wave 1 (ADJUSTED): npm Distribution — shell bundled in cli.js
- Wave 2 (DEFERRED): SquadUI — waits for shell foundation
- Wave 3 (ADJUSTED): Public Docs — now documents shell as primary interface

### Decision Framing

**Format:** "Recommendation: X (recommended) or alternatives?"

**Components:**
- Recommendation (pick one, justify)
- Alternatives (what else was considered)
- Decision rationale (why recommended option wins)
- Needs sign-off from (which agents/roles must approve)

**Example:**
```
### 1. Terminal UI Library: `ink` (recommended) or alternatives?

**Recommendation:** `ink`
**Alternatives:** `blessed`, raw readline
**Decision rationale:** Component model enables testable UI. Battle-tested ecosystem.

**Needs sign-off from:** Brady (product direction), Fortier (runtime performance)
```

### Risk Documentation

**Format per risk:**
- **Risk:** Specific failure mode
- **Likelihood:** Low / Medium / High (not percentages)
- **Impact:** Low / Medium / High
- **Mitigation:** Concrete actions (measurable)

**Example:**
```
### Risk 2: SDK Streaming Reliability

**Risk:** SDK streaming events might drop messages or arrive out of order.
**Likelihood:** Low (SDK is production-grade).
**Impact:** High — broken streaming makes shell unusable.

**Mitigation:**
- Add integration test: Send 1000-message stream, verify all deltas arrive in order
- Implement fallback: If streaming fails, fall back to polling session state
- Log all SDK events to `.squad/orchestration-log/sdk-events.jsonl` for debugging
```

## Examples

**File references from interactive shell proposal:**
- Full proposal: `docs/proposals/squad-interactive-shell.md`
- User directive: `.squad/decisions/inbox/copilot-directive-2026-02-21T202535Z.md`
- Team decisions: `.squad/decisions.md`
- Current architecture: `docs/architecture/module-map.md`, `docs/prd-23-release-readiness.md`

**Key patterns demonstrated:**
1. Read user directive first (understand the "why")
2. Survey current architecture (module map, existing waves)
3. Research SDK APIs (exploration task to validate feasibility)
4. Document problem with specific evidence (unreliable handoffs, zero visibility, UX mismatch)
5. Propose solution with technical specifics (ink components, SDK session management, spawn.ts module)
6. Restructure waves when foundation shifts (Wave 0 becomes blocker)
7. Preserve backward compatibility (squad.agent.md still works, VS Code mode unchanged)
8. Frame decisions explicitly (5 key decisions with recommendations)
9. Document risks with mitigations (5 risks, each with concrete actions)
10. Define scope (what's in v1 vs. deferred)

## Anti-Patterns

**Avoid:**
- ❌ Proposals without problem statements (solution-first thinking)
- ❌ Vague architecture ("we'll use a shell") — be specific (ink components, session registry, spawn.ts)
- ❌ Ignoring existing work — always document impact on waves/milestones
- ❌ No risk analysis — every architecture has risks, document them
- ❌ Unbounded scope — draw the v1 line explicitly
- ❌ Missing decision ownership — always say "needs sign-off from X"
- ❌ No backward compatibility plan — users don't care about your replatform
- ❌ Hand-waving timelines ("a few weeks") — be specific (2-3 weeks, 1 engineer full-time)

**Red flags in proposal reviews:**
- "Users will love this" (citation needed)
- "We'll figure out X later" (scope creep incoming)
- "This is revolutionary" (tone ceiling violation)
- No section on "What Stays the Same" (regression risk)
- No risks documented (wishful thinking)
84 changes: 84 additions & 0 deletions .copilot/skills/ci-validation-gates/SKILL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,84 @@
---
name: "ci-validation-gates"
description: "Defensive CI/CD patterns: semver validation, token checks, retry logic, draft detection — earned from v0.8.22"
domain: "ci-cd"
confidence: "high"
source: "extracted from Drucker and Trejo charters — earned knowledge from v0.8.22 release incident"
---

## Context

CI workflows must be defensive. These patterns were learned from the v0.8.22 release disaster where invalid semver, wrong token types, missing retry logic, and draft releases caused a multi-hour outage. Both Drucker (CI/CD) and Trejo (Release Manager) carried this knowledge in their charters — now centralized here.

## Patterns

### Semver Validation Gate
Every publish workflow MUST validate version format before `npm publish`. 4-part versions (e.g., 0.8.21.4) are NOT valid semver — npm mangles them.

```yaml
- name: Validate semver
run: |
VERSION="${{ github.event.release.tag_name }}"
VERSION="${VERSION#v}"
if ! npx semver "$VERSION" > /dev/null 2>&1; then
echo "❌ Invalid semver: $VERSION"
echo "Only 3-part versions (X.Y.Z) or prerelease (X.Y.Z-tag.N) are valid."
exit 1
fi
echo "✅ Valid semver: $VERSION"
```

### NPM Token Type Verification
NPM_TOKEN MUST be an Automation token, not a User token with 2FA:
- User tokens require OTP — CI can't provide it → EOTP error
- Create Automation tokens at npmjs.com → Settings → Access Tokens → Automation
- Verify before first publish in any workflow

### Retry Logic for npm Registry Propagation
npm registry uses eventual consistency. After `npm publish` succeeds, the package may not be immediately queryable.
- Propagation: typically 5-30s, up to 2min in rare cases
- All verify steps: 5 attempts, 15-second intervals
- Log each attempt: "Attempt 1/5: Checking package..."
- Exit loop on success, fail after max attempts

```yaml
- name: Verify package (with retry)
run: |
MAX_ATTEMPTS=5
WAIT_SECONDS=15
for attempt in $(seq 1 $MAX_ATTEMPTS); do
echo "Attempt $attempt/$MAX_ATTEMPTS: Checking $PACKAGE@$VERSION..."
if npm view "$PACKAGE@$VERSION" version > /dev/null 2>&1; then
echo "✅ Package verified"
exit 0
fi
[ $attempt -lt $MAX_ATTEMPTS ] && sleep $WAIT_SECONDS
done
echo "❌ Failed to verify after $MAX_ATTEMPTS attempts"
exit 1
```

### Draft Release Detection
Draft releases don't emit `release: published` event. Workflows MUST:
- Trigger on `release: published` (NOT `created`)
- If using workflow_dispatch: verify release is published via GitHub API before proceeding

### Build Script Protection
Set `SKIP_BUILD_BUMP=1` (or `$env:SKIP_BUILD_BUMP = "1"` on Windows) before ANY release build. bump-build.mjs is for dev builds ONLY — it silently mutates versions.

## Known Failure Modes (v0.8.22 Incident)

| # | What Happened | Root Cause | Prevention |
|---|---------------|-----------|------------|
| 1 | 4-part version published, npm mangled it | No semver validation gate | `npx semver` check before every publish |
| 2 | CI failed 5+ times with EOTP | User token with 2FA | Automation token only |
| 3 | Verify returned false 404 | No retry logic for propagation | 5 attempts, 15s intervals |
| 4 | Workflow never triggered | Draft release doesn't emit event | Never create draft releases |
| 5 | Version mutated during release | bump-build.mjs ran in release | SKIP_BUILD_BUMP=1 |

## Anti-Patterns
- ❌ Publishing without semver validation gate
- ❌ Single-shot verification without retry
- ❌ Hard-coded secrets in workflows
- ❌ Silent CI failures — every error needs actionable output with remediation
- ❌ Assuming npm publish is instantly queryable
47 changes: 47 additions & 0 deletions .copilot/skills/cli-wiring/SKILL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
# Skill: CLI Command Wiring

**Bug class:** Commands implemented in `packages/squad-cli/src/cli/commands/` but never routed in `cli-entry.ts`.

## Checklist — Adding a New CLI Command

1. **Create command file** in `packages/squad-cli/src/cli/commands/<name>.ts`
- Export a `run<Name>(cwd, options)` async function (or class with static methods for utility modules)

2. **Add routing block** in `packages/squad-cli/src/cli-entry.ts` inside `main()`:
```ts
if (cmd === '<name>') {
const { run<Name> } = await import('./cli/commands/<name>.js');
// parse args, call function
await run<Name>(process.cwd(), options);
return;
}
```

3. **Add help text** in the help section of `cli-entry.ts` (search for `Commands:`):
```ts
console.log(` ${BOLD}<name>${RESET} <description>`);
console.log(` Usage: <name> [flags]`);
```

4. **Verify both exist** — the recurring bug is doing step 1 but missing steps 2-3.

## Wiring Patterns by Command Type

| Type | Example | How to wire |
|------|---------|-------------|
| Standard command | `export.ts`, `build.ts` | `run*()` function, parse flags from `args` |
| Placeholder command | `loop`, `hire` | Inline in cli-entry.ts, prints pending message |
| Utility/check module | `rc-tunnel.ts`, `copilot-bridge.ts` | Wire as diagnostic check (e.g., `isDevtunnelAvailable()`) |
| Subcommand of another | `init-remote.ts` | Already used inside parent + standalone alias |

## Common Import Pattern

```ts
import { BOLD, RESET, DIM, RED, GREEN, YELLOW } from './cli/core/output.js';
```

Use dynamic `await import()` for command modules to keep startup fast (lazy loading).

## History

- **#237 / PR #244:** 4 commands wired (rc, copilot-bridge, init-remote, rc-tunnel). aspire, link, loop, hire were already present.
Loading
Loading