Commit Graph

14 Commits

Author SHA1 Message Date
typebasedio d3e20821d7 feat(v0.3): add seed dir and project root resolvers in config
ResolveSeedDir, ResolveProjectSeedDir, and ResolveProjectRoot read
the v0.3 environment variables (CTASK_SEED_DIR,
CTASK_SEED_PROJECT_DIR, CTASK_PROJECT_ROOT) and fall back to
platform defaults under %APPDATA%\ctask or ~/.config/ctask. The
expandPath helper handles tilde expansion + abs-path resolution
once for all resolvers.
2026-04-10 14:32:46 -04:00
typebasedio ced0d276b4 feat(v0.3): add built-in project CLAUDE.md template
ClaudeMDProject returns the project-oriented default used when
--project is passed (and no project seed overrides it). Adds tests
asserting required v0.3 spec sections and ASCII-only content.
2026-04-10 14:31:39 -04:00
typebasedio 0439702833 feat(v0.3): replace built-in task CLAUDE.md with v0.3 default content
Replaces the v0.2 task-scoped template with the v0.3 workspace
guidelines (file placement conventions + session handoff).
ClaudeMD signature is preserved for API compatibility; the
parameters are no longer interpolated.
2026-04-10 14:30:54 -04:00
typebasedio 2a606053dd docs: anti-guessing guardrails in project CLAUDE.md and seeded workspace template
Add "Repository and Package Identity" rule to both the project-level CLAUDE.md
and the seeded CLAUDE.md template (internal/seed/templates.go). Every new ctask
workspace now inherits guidance against fabricating repo URLs, module paths,
GitHub identities, or remote install commands.

Also adds local-only build/install instructions and data safety invariant
documentation to the project-level CLAUDE.md.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-06 16:09:29 -04:00
typebasedio 75911faeeb fix: replace all non-ASCII characters with safe ASCII equivalents
Replace box-drawing characters (U+2500) in session log with ASCII dashes.
Replace em dashes (U+2014) in CLAUDE.md template with double hyphens.
Remove em dash from comment in run.go.
Add ASCII-guard tests for session log output and seed templates.
Prevents mojibake on Windows terminals that misinterpret UTF-8 as CP1252.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-06 10:15:02 -04:00
typebasedio 69c487cf79 feat: v0.2 tests for manifest capture, diff, ignore rules, and session log
11 new tests covering manifest capture/exclusion, roundtrip, diff logic, ignore rules (task.yaml, sessions.log, .ctask/), notes updated detection, session log formatting, append-only behavior, short session detection. Fix cross-platform ignore rule for logs/sessions.log.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-06 10:01:31 -04:00
typebasedio aba4a645b1 feat: add session handoff guidance to seeded CLAUDE.md template
Advisory instructions to append a brief summary to notes.md before ending a session. Also update logs/ description from "reserved" to "automatic session snapshots".

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-06 09:56:55 -04:00
typebasedio 10ab9efc80 feat: session lifecycle wrapper with manifest capture and session logging
Refactor new/resume/open to use session.Run() which wraps child process launch with pre/post manifest capture and append-only session logging to logs/sessions.log. Bump version to 0.2.0.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-06 09:56:21 -04:00
typebasedio afd594ed6c feat: platform-specific shell and agent launch helpers
DefaultShell, ExecAgent, ExecShell with prompt prefix. Banner, container notice. Tests for all helpers.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-05 18:32:55 -04:00
typebasedio 6740c3835e feat: query resolution and workspace listing
5-step query resolution (exact dir, exact slug, substring), archived exclusion. Listing with category filter, limit, reverse-chronological sort.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-05 18:32:12 -04:00
typebasedio 17789e4b9f feat: workspace creation with seed files and collision handling
Create function produces full workspace layout (task.yaml, CLAUDE.md, notes.md, context/, output/, logs/). Seed files only written if missing. Collision suffixing tested.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-05 18:30:59 -04:00
typebasedio 7b75cb5f3d feat: slug generation and directory collision resolution
Slugify, AutoTitle, DirName, ResolveDir with -2, -3 suffixing. Full test coverage.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-05 18:30:06 -04:00
typebasedio 514f2d8233 feat: workspace metadata model with YAML read/write
TaskMeta struct matching task.yaml schema exactly. Tests for roundtrip, field presence, and archive state.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-05 18:29:26 -04:00
typebasedio ab56ddfff0 feat: project init with config package and root command
Go module, cobra root command, config resolution (CTASK_ROOT, CTASK_AGENT, EnvVars) with tests.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-05 18:28:24 -04:00