@taskset/cli 4.0.0 → 5.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +22 -0
- package/README.md +6 -2
- package/dist/cli.d.ts.map +1 -1
- package/dist/cli.js +510 -63
- package/docs/_meta.ts +8 -0
- package/docs/cli-reference.md +461 -0
- package/docs/configuration.md +61 -0
- package/docs/document-types.md +100 -0
- package/docs/getting-started.md +99 -0
- package/docs/index.md +37 -0
- package/docs/maintainers/_meta.ts +7 -0
- package/docs/maintainers/architecture/_meta.ts +5 -0
- package/docs/maintainers/architecture/decisions/0001-documentation-platform.md +70 -0
- package/docs/maintainers/architecture/decisions/0002-code-architecture.md +31 -0
- package/docs/maintainers/architecture/decisions/0003-snapshot-policy.md +31 -0
- package/docs/maintainers/architecture/decisions/_meta.ts +5 -0
- package/docs/maintainers/architecture/overview.md +111 -0
- package/docs/maintainers/architecture/synchronization.md +56 -0
- package/docs/maintainers/development/_meta.ts +6 -0
- package/docs/maintainers/development/contributing.md +59 -0
- package/docs/maintainers/development/documentation.md +69 -0
- package/docs/maintainers/development/engineering.md +59 -0
- package/docs/maintainers/development/testing.md +89 -0
- package/docs/maintainers/index.md +22 -0
- package/docs/maintainers/product/_meta.ts +3 -0
- package/docs/maintainers/product/vision.md +76 -0
- package/docs/maintainers/technology.md +55 -0
- package/docs/task-files.md +174 -0
- package/package.json +7 -5
- package/skills/taskset/SKILL.md +227 -0
- package/skills/taskset/references/changesets-examples.md +97 -0
- package/skills/taskset/references/document-modeling-examples.md +63 -0
- package/skills/taskset/references/monorepo-task-modeling.md +125 -0
- package/skills/taskset/references/task-modeling-examples.md +249 -0
- package/skills/taskset-implement/SKILL.md +234 -0
- package/skills/taskset-implement/agents/openai.yaml +4 -0
- package/skills/taskset-implement/references/architecture/client-and-server.md +69 -0
- package/skills/taskset-implement/references/architecture/documentation-and-generated.md +70 -0
- package/skills/taskset-implement/references/architecture/ownership-and-dependencies.md +107 -0
- package/skills/taskset-implement/references/architecture/product-and-source.md +80 -0
- package/skills/taskset-implement/references/architecture/storage-and-snapshots.md +45 -0
- package/skills/taskset-implement/references/architecture.md +34 -0
- package/skills/taskset-implement/references/conventions/backend-and-tooling.md +33 -0
- package/skills/taskset-implement/references/conventions/design.md +38 -0
- package/skills/taskset-implement/references/conventions/interfaces-and-ui.md +50 -0
- package/skills/taskset-implement/references/conventions/naming-and-packages.md +64 -0
- package/skills/taskset-implement/references/conventions/task-files.md +89 -0
- package/skills/taskset-implement/references/conventions/tests-and-docs.md +55 -0
- package/skills/taskset-implement/references/conventions/typescript-and-exports.md +41 -0
- package/skills/taskset-implement/references/conventions.md +40 -0
- package/skills/taskset-implement/references/release.md +135 -0
- package/skills/taskset-implement/references/workflows/dependencies-and-docs-site.md +54 -0
- package/skills/taskset-implement/references/workflows/environment-and-pnpm.md +108 -0
- package/skills/taskset-implement/references/workflows/persisted-data-and-git.md +30 -0
- package/skills/taskset-implement/references/workflows/validation.md +34 -0
- package/skills/taskset-implement/references/workflows/vitest-and-test-strategy.md +82 -0
- package/skills/taskset-implement/references/workflows.md +33 -0
- package/src/cli.ts +611 -77
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# Conventions
|
|
2
|
+
|
|
3
|
+
Use this file as the routing map for implementation conventions. Load only the
|
|
4
|
+
topic file needed for the change, then load additional files when the work
|
|
5
|
+
crosses that boundary.
|
|
6
|
+
|
|
7
|
+
## Routing
|
|
8
|
+
|
|
9
|
+
- [design.md](conventions/design.md): general design heuristics, SOLID,
|
|
10
|
+
clean architecture, DDD, feature-based architecture, comments, and diff scope
|
|
11
|
+
- [naming-and-packages.md](conventions/naming-and-packages.md): file, symbol,
|
|
12
|
+
command, package, and configuration naming
|
|
13
|
+
- [typescript-and-exports.md](conventions/typescript-and-exports.md):
|
|
14
|
+
TypeScript style, package exports, import boundaries, dependency declarations,
|
|
15
|
+
and shared configuration
|
|
16
|
+
- [task-files.md](conventions/task-files.md): canonical Taskset entity
|
|
17
|
+
frontmatter, Markdown body, validation, relationship, timestamp, and
|
|
18
|
+
serialization rules
|
|
19
|
+
- [interfaces-and-ui.md](conventions/interfaces-and-ui.md): CLI behavior,
|
|
20
|
+
client ownership, React/TanStack preferences, Kanban, and Office UI rules
|
|
21
|
+
- [backend-and-tooling.md](conventions/backend-and-tooling.md): backend
|
|
22
|
+
technology choices, database policy, shell scripts, and automation ownership
|
|
23
|
+
- [tests-and-docs.md](conventions/tests-and-docs.md): testing conventions,
|
|
24
|
+
documentation ownership, docs site content rules, README rules, and completion
|
|
25
|
+
documentation expectations
|
|
26
|
+
|
|
27
|
+
## Loading Guidance
|
|
28
|
+
|
|
29
|
+
- For new or renamed files, packages, exports, commands, or public types, load
|
|
30
|
+
`naming-and-packages.md` and `typescript-and-exports.md`.
|
|
31
|
+
- For task metadata, canonical Markdown entity files, parsers, serialization,
|
|
32
|
+
or validation, load `task-files.md`.
|
|
33
|
+
- For CLI, UI, website client, Kanban, Office, extension, TUI, or MCP behavior,
|
|
34
|
+
load `interfaces-and-ui.md`.
|
|
35
|
+
- For scripts, backend/server technology, or dependency/tooling decisions, load
|
|
36
|
+
`backend-and-tooling.md`.
|
|
37
|
+
- For tests, READMEs, docs, posts, or completion documentation updates, load
|
|
38
|
+
`tests-and-docs.md`.
|
|
39
|
+
- For broad design or architecture-sensitive implementation, load `design.md`
|
|
40
|
+
first, then the specific owner file.
|
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
# Release and Completion
|
|
2
|
+
|
|
3
|
+
## Changesets
|
|
4
|
+
|
|
5
|
+
The consumer-facing npm package is `@taskset/cli`. It exposes the `taskset`
|
|
6
|
+
executable, re-exports `defineConfig` for `taskset.config.ts`, and ships the
|
|
7
|
+
repository `docs/` and `skills/` trees in the published tarball (copied beside
|
|
8
|
+
the package during `pnpm --filter @taskset/cli build`).
|
|
9
|
+
|
|
10
|
+
The public runtime package set is:
|
|
11
|
+
|
|
12
|
+
```text
|
|
13
|
+
@taskset/cli
|
|
14
|
+
@taskset/core
|
|
15
|
+
@taskset/contracts
|
|
16
|
+
@taskset/utils
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
The CLI depends on the other public packages, so they must remain publishable
|
|
20
|
+
unless the CLI is deliberately changed to bundle them. Configs, unfinished
|
|
21
|
+
interfaces, and apps remain private.
|
|
22
|
+
|
|
23
|
+
`.github/workflows/publish-npm.yml` runs repository validation and then uses
|
|
24
|
+
`pnpm --recursive publish --access public --no-git-checks` when a GitHub Release
|
|
25
|
+
is published. pnpm skips private workspaces and publishes the public dependency
|
|
26
|
+
chain. The workflow requires the `NPM_TOKEN` repository secret and enables npm
|
|
27
|
+
provenance through GitHub's OIDC permission.
|
|
28
|
+
|
|
29
|
+
The npm account used by CI must control the `@taskset` scope.
|
|
30
|
+
|
|
31
|
+
Once configured, create a Changeset when a versioned package's behavior,
|
|
32
|
+
contract, build, persisted format, or user-visible tooling changes:
|
|
33
|
+
|
|
34
|
+
```bash
|
|
35
|
+
pnpm changeset
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
Select the exact current manifest names for changed public packages:
|
|
39
|
+
|
|
40
|
+
```text
|
|
41
|
+
@taskset/contracts
|
|
42
|
+
@taskset/utils
|
|
43
|
+
@taskset/core
|
|
44
|
+
@taskset/cli
|
|
45
|
+
```
|
|
46
|
+
|
|
47
|
+
Do not add Changesets for private packages or select a duplicate or misplaced
|
|
48
|
+
scaffold name. Correct package identity first.
|
|
49
|
+
|
|
50
|
+
Choose the bump by impact:
|
|
51
|
+
|
|
52
|
+
- `patch`: compatible fix or internal correction
|
|
53
|
+
- `minor`: compatible feature, command, field, tool, or public behavior
|
|
54
|
+
- `major`: breaking API, package identity, command contract, persisted schema,
|
|
55
|
+
migration requirement, or workflow change
|
|
56
|
+
|
|
57
|
+
Persisted Markdown compatibility is a public contract. A parser change that
|
|
58
|
+
makes existing repositories unreadable is breaking.
|
|
59
|
+
|
|
60
|
+
Write summaries for users:
|
|
61
|
+
|
|
62
|
+
- lead with behavior
|
|
63
|
+
- state compatibility and migration consequences
|
|
64
|
+
- avoid raw file lists and implementation diaries
|
|
65
|
+
|
|
66
|
+
Do not create a Changeset for:
|
|
67
|
+
|
|
68
|
+
- `skills/` instructions
|
|
69
|
+
- tests-only changes
|
|
70
|
+
- internal documentation corrections
|
|
71
|
+
- formatting-only changes
|
|
72
|
+
- repository notes that do not alter supported behavior
|
|
73
|
+
|
|
74
|
+
Use these only during explicit release work:
|
|
75
|
+
|
|
76
|
+
```bash
|
|
77
|
+
pnpm changeset status
|
|
78
|
+
pnpm changeset version
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
Do not manually edit package versions or generated changelogs during ordinary
|
|
82
|
+
feature work.
|
|
83
|
+
|
|
84
|
+
## Commit Language
|
|
85
|
+
|
|
86
|
+
Prefer concise conventional subjects:
|
|
87
|
+
|
|
88
|
+
```text
|
|
89
|
+
feat(core): add deterministic task parsing
|
|
90
|
+
fix(cli): report malformed frontmatter
|
|
91
|
+
refactor(types): unify relationship contracts
|
|
92
|
+
chore(tooling): align workspace package names
|
|
93
|
+
docs(standards): migrate repository guidance to Taskset
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
Use an imperative, behavior-focused subject. Add a body when architecture,
|
|
97
|
+
compatibility, migration, or verification needs explanation.
|
|
98
|
+
|
|
99
|
+
## Compatibility Review
|
|
100
|
+
|
|
101
|
+
Review these surfaces before release:
|
|
102
|
+
|
|
103
|
+
- Markdown and frontmatter read compatibility
|
|
104
|
+
- defaults, enums, and validation strictness
|
|
105
|
+
- generated filenames and entity IDs
|
|
106
|
+
- CLI command names, flags, output, and exit codes
|
|
107
|
+
- MCP tool names, input schemas, and result shapes
|
|
108
|
+
- package exports and runtime requirements
|
|
109
|
+
- configuration file names and defaults
|
|
110
|
+
- relationship and graph semantics
|
|
111
|
+
- snapshot creation and restore semantics
|
|
112
|
+
- documentation routes and public examples
|
|
113
|
+
|
|
114
|
+
Do not call a change internal merely because only one current interface uses it.
|
|
115
|
+
If it affects canonical repository data, it affects every future interface.
|
|
116
|
+
|
|
117
|
+
## Definition of Done
|
|
118
|
+
|
|
119
|
+
A change is complete when:
|
|
120
|
+
|
|
121
|
+
- the requested outcome is correct, not merely implemented literally
|
|
122
|
+
- canonical `.taskset/` data remains the persistent authority
|
|
123
|
+
- all affected schemas, core operations, clients, tests, and docs agree
|
|
124
|
+
- no interface-specific duplicate of domain behavior was introduced
|
|
125
|
+
- package names, exports, and dependencies match ownership
|
|
126
|
+
- user-owned worktree changes remain intact
|
|
127
|
+
- focused tests cover new or corrected behavior
|
|
128
|
+
- broader checks match the blast radius
|
|
129
|
+
- persisted format changes include compatibility and migration handling
|
|
130
|
+
- generated outputs were regenerated rather than hand-edited
|
|
131
|
+
- a Changeset exists when release policy requires one
|
|
132
|
+
- documentation uses current paths, commands, and package names
|
|
133
|
+
- `skills/taskset-implement/` was updated when repository rules or workflows changed
|
|
134
|
+
- the final report distinguishes passed checks, skipped checks, prerequisites,
|
|
135
|
+
and pre-existing failures
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
# Dependencies And Docs Site
|
|
2
|
+
|
|
3
|
+
Dependency management, website workflow, publishing pages, and backend dependency choices.
|
|
4
|
+
|
|
5
|
+
## Dependency Management
|
|
6
|
+
|
|
7
|
+
Add dependencies to the package that imports them:
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
pnpm --filter <package-name> add <runtime-package>
|
|
11
|
+
pnpm --filter <package-name> add --save-dev <tooling-package>
|
|
12
|
+
pnpm --filter <package-name> add @taskset/core@workspace:*
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
Rules:
|
|
16
|
+
|
|
17
|
+
- Do not add a root dependency to make a child package compile.
|
|
18
|
+
- Do not rely on root hoisting, transitive dependencies, or another package's
|
|
19
|
+
`node_modules`.
|
|
20
|
+
- Keep browser and React dependencies out of core, types, and domain-light
|
|
21
|
+
utilities.
|
|
22
|
+
- Prefer one parser, validator, and serialization stack for the canonical file
|
|
23
|
+
format.
|
|
24
|
+
- Review license, runtime support, ESM compatibility, maintenance, and bundle
|
|
25
|
+
impact before adding foundational dependencies.
|
|
26
|
+
- Keep lockfile changes scoped to the dependency operation.
|
|
27
|
+
|
|
28
|
+
Frontend packages should follow the TanStack preference in
|
|
29
|
+
`docs/maintainers/technology.md`, but only install Query, Form, Table, Hotkeys,
|
|
30
|
+
Pacer, Virtual, DB, or their devtools when the owning feature uses them.
|
|
31
|
+
|
|
32
|
+
`@taskset/www` uses Next.js webpack mode for development and production because
|
|
33
|
+
Turbopack does not reliably discover new files through the external `docs/`
|
|
34
|
+
content symlink.
|
|
35
|
+
|
|
36
|
+
The website renders canonical documentation from the `apps/www/content`
|
|
37
|
+
symlink and canonical blog posts from `apps/www/posts/`. Top-level usage docs
|
|
38
|
+
and `docs/maintainers/` use separate route layouts and page maps; keep
|
|
39
|
+
maintainer material out of the primary usage-docs navigation. Add each post to
|
|
40
|
+
`apps/www/src/blog/posts.ts` so `/posts/[slug]` remains statically enumerable.
|
|
41
|
+
Docs and blog routes use separate Nextra theme wrappers.
|
|
42
|
+
|
|
43
|
+
`.github/workflows/publish-pages.yml` builds `@taskset/www` as a static export
|
|
44
|
+
and deploys `apps/www/out` to GitHub Pages on pushes to `main` or manual
|
|
45
|
+
dispatch. The workflow supplies the Pages base path through `STATIC_EXPORT` so
|
|
46
|
+
project sites work below the repository subpath; `/` represents a root site.
|
|
47
|
+
Local development and server builds keep their normal Next.js configuration.
|
|
48
|
+
|
|
49
|
+
For backend work, prefer TypeScript first. Add NestJS,
|
|
50
|
+
`class-transformer`, `class-validator`, and TypeORM only in the owning server
|
|
51
|
+
application when its architecture needs them. Use Rust for a clearly bounded
|
|
52
|
+
systems-level component, not as an incidental second implementation of core
|
|
53
|
+
domain behavior. Choose MariaDB for smaller hosted applications and PostgreSQL
|
|
54
|
+
for larger or more advanced relational workloads.
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
# Environment And Pnpm
|
|
2
|
+
|
|
3
|
+
Pinned environment, pnpm, Turbo, Taskset dogfooding, and package scripts.
|
|
4
|
+
|
|
5
|
+
## Environment and Setup
|
|
6
|
+
|
|
7
|
+
Use the versions pinned by the repository:
|
|
8
|
+
|
|
9
|
+
- Node `24.16.0` from `.nvmrc`
|
|
10
|
+
- pnpm `11.5.2` from `packageManager`
|
|
11
|
+
- TypeScript and other tools from the lockfile
|
|
12
|
+
|
|
13
|
+
Initial setup:
|
|
14
|
+
|
|
15
|
+
```bash
|
|
16
|
+
pnpm install --frozen-lockfile
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
Do not replace pnpm with npm, Yarn, or Bun for workspace operations. Update
|
|
20
|
+
`.nvmrc`, `engines`, `packageManager`, and the lockfile together when changing
|
|
21
|
+
the supported toolchain.
|
|
22
|
+
|
|
23
|
+
## pnpm and Turbo
|
|
24
|
+
|
|
25
|
+
`pnpm-workspace.yaml` recursively includes `apps/**` and `packages/**`.
|
|
26
|
+
|
|
27
|
+
Current root commands:
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
pnpm dev
|
|
31
|
+
pnpm build
|
|
32
|
+
pnpm test
|
|
33
|
+
pnpm test:watch
|
|
34
|
+
pnpm lint
|
|
35
|
+
pnpm format
|
|
36
|
+
pnpm check
|
|
37
|
+
pnpm clean
|
|
38
|
+
pnpm taskset
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
Current behavior:
|
|
42
|
+
|
|
43
|
+
- `dev` runs `turbo dev`.
|
|
44
|
+
- `build` runs dependency builds first through Turbo.
|
|
45
|
+
- `test` uses Turbo to run package-local Vitest suites plus the root workspace
|
|
46
|
+
architecture suite exposed as `test:architecture`.
|
|
47
|
+
- `test:watch` uses Turbo to start package-local Vitest watch tasks.
|
|
48
|
+
- `check` runs lint, tests, and the build in sequence.
|
|
49
|
+
- `lint` runs `biome check .` without writing fixes.
|
|
50
|
+
- `format` runs `biome format --write .`.
|
|
51
|
+
- `clean` runs the Turbo clean task.
|
|
52
|
+
- `taskset` runs the built entrypoint from the root workspace-installed
|
|
53
|
+
`@taskset/cli` package. Build first when generated `dist/` output is absent.
|
|
54
|
+
|
|
55
|
+
`@taskset/contracts`, `@taskset/utils`, `@taskset/core`, and `@taskset/cli`
|
|
56
|
+
currently define `build` and `test`. Their builds run strict TypeScript
|
|
57
|
+
compilation into disposable `dist/` output, and their tests run the owning
|
|
58
|
+
source tests through the root Vitest config. Other packages remain scaffolds,
|
|
59
|
+
so inspect each affected manifest before assuming it defines `build`, `test`,
|
|
60
|
+
`typecheck`, or `dev`.
|
|
61
|
+
|
|
62
|
+
Those four packages form the public npm runtime and are published recursively.
|
|
63
|
+
Keep their runtime dependency chain public and keep package tarballs restricted
|
|
64
|
+
to built output, runtime source used by workspace development conditions,
|
|
65
|
+
package documentation, and—for `@taskset/cli`—the copied repository `docs/` and
|
|
66
|
+
`skills/` trees. Exclude tests, local build caches, and tool configs.
|
|
67
|
+
Their builds clean `dist/` before TypeScript emits so renamed files cannot leak
|
|
68
|
+
into published tarballs. The CLI build also refreshes `packages/cli/docs` and
|
|
69
|
+
`packages/cli/skills` from the repository root; those copies are gitignored and
|
|
70
|
+
must be present in the tarball listed by the CLI `files` field.
|
|
71
|
+
|
|
72
|
+
Use exact package names:
|
|
73
|
+
|
|
74
|
+
```bash
|
|
75
|
+
pnpm --filter @taskset/core test
|
|
76
|
+
pnpm --filter @taskset/cli build
|
|
77
|
+
pnpm --filter @taskset/mcp dev
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
The repository dogfoods Taskset through:
|
|
81
|
+
|
|
82
|
+
```bash
|
|
83
|
+
pnpm build
|
|
84
|
+
pnpm taskset config --json
|
|
85
|
+
pnpm taskset task list
|
|
86
|
+
pnpm taskset task create --title "Describe the work"
|
|
87
|
+
pnpm taskset task list --file packages/core --impact
|
|
88
|
+
pnpm taskset task status <task-id> doing
|
|
89
|
+
pnpm taskset snapshot create
|
|
90
|
+
pnpm taskset doctor
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
Package-local `test` and `test:watch` scripts are required because Turbo
|
|
94
|
+
orchestrates scripts declared by each workspace and filtered package commands
|
|
95
|
+
must remain available. Root-only architecture tests run once after Turbo rather
|
|
96
|
+
than being duplicated inside every package. There is no `transit` script;
|
|
97
|
+
Turbo's dependency traversal is orchestration, not another test suite.
|
|
98
|
+
|
|
99
|
+
`taskset.config.ts` is loaded as trusted project code using Node's native
|
|
100
|
+
erasable TypeScript support. Keep it free of syntax that requires TypeScript
|
|
101
|
+
code generation.
|
|
102
|
+
|
|
103
|
+
If Turbo reports duplicate workspace names, fix the incorrect package manifest.
|
|
104
|
+
Do not work around the graph with directory filters or aliases.
|
|
105
|
+
|
|
106
|
+
`pnpm update-deps` performs broad recursive upgrades, deduplication, and audit
|
|
107
|
+
mutation. Run it only for an explicit dependency-update task and review the
|
|
108
|
+
lockfile and compatibility impact.
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
# Persisted Data And Git Workflows
|
|
2
|
+
|
|
3
|
+
Persisted format, generated view, Git, and concurrency-sensitive workflow rules.
|
|
4
|
+
|
|
5
|
+
## Persisted Data and Git Workflows
|
|
6
|
+
|
|
7
|
+
Use temporary fixture repositories for tests that invoke Git. Configure test
|
|
8
|
+
identity locally inside the fixture; never depend on the developer's global Git
|
|
9
|
+
configuration.
|
|
10
|
+
|
|
11
|
+
For persisted format changes:
|
|
12
|
+
|
|
13
|
+
1. Add old-format fixtures.
|
|
14
|
+
2. Define read compatibility and write behavior.
|
|
15
|
+
3. Implement an explicit compatibility path when rewriting is required.
|
|
16
|
+
4. Verify compatibility behavior and rollback safety.
|
|
17
|
+
5. Preserve a recoverable backup or fail before mutation.
|
|
18
|
+
6. Document user-visible consequences.
|
|
19
|
+
|
|
20
|
+
For generated indexes and views:
|
|
21
|
+
|
|
22
|
+
1. Delete the derived state under each entity folder's `.generated/` directory.
|
|
23
|
+
2. Rebuild it from canonical entities in that folder's scope.
|
|
24
|
+
3. Verify equivalent observable output and stale-file removal.
|
|
25
|
+
4. Confirm `.taskset/.gitignore` ignores `**/.generated/` and staging
|
|
26
|
+
`**/.generated.*/` paths; do not revive a global `.taskset/generated/`.
|
|
27
|
+
|
|
28
|
+
For concurrency-sensitive writes, test stale reads, competing updates, and
|
|
29
|
+
partial failures. Do not imply database-style transaction guarantees that the
|
|
30
|
+
filesystem and Git do not provide.
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
# Validation Workflow
|
|
2
|
+
|
|
3
|
+
Validation command order, root checks, and handling unrelated failures.
|
|
4
|
+
|
|
5
|
+
## Validation
|
|
6
|
+
|
|
7
|
+
Start narrow:
|
|
8
|
+
|
|
9
|
+
```bash
|
|
10
|
+
pnpm --filter <package-name> test
|
|
11
|
+
pnpm --filter <package-name> build
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
Then run relevant root checks:
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
pnpm lint
|
|
18
|
+
pnpm test
|
|
19
|
+
pnpm build
|
|
20
|
+
git diff --check
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
Use `pnpm format` only when formatting changes are intended, then inspect the
|
|
24
|
+
diff. Biome is authoritative; do not introduce ESLint or Prettier to solve a
|
|
25
|
+
local issue.
|
|
26
|
+
|
|
27
|
+
When a root check fails because of pre-existing scaffold state:
|
|
28
|
+
|
|
29
|
+
1. Confirm the failure is unrelated to the current change.
|
|
30
|
+
2. Run the narrowest check that validates the changed owner.
|
|
31
|
+
3. Report the exact blocker.
|
|
32
|
+
4. Fix it only when it belongs to the request or prevents reliable validation.
|
|
33
|
+
|
|
34
|
+
Never claim an unrun or failed check passed.
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
# Vitest And Test Strategy
|
|
2
|
+
|
|
3
|
+
Vitest workflow and Taskset-specific test coverage strategy.
|
|
4
|
+
|
|
5
|
+
## Vitest and Test-Driven Development
|
|
6
|
+
|
|
7
|
+
Vitest is the default runner for TypeScript domain, filesystem, CLI adapter, and
|
|
8
|
+
integration tests. Use the root `vitest.config.ts` until a package needs a
|
|
9
|
+
distinct runtime such as browser mode. Add Vitest `projects` only when separate
|
|
10
|
+
Node, browser, or extension environments provide real value.
|
|
11
|
+
Vitest already uses Vite internally. Do not add a standalone Vite build to
|
|
12
|
+
Node-focused libraries or the CLI unless a concrete bundling requirement
|
|
13
|
+
appears; use the owning UI application's build tool for browser products.
|
|
14
|
+
|
|
15
|
+
Compile Node libraries and the CLI to `dist/` and keep the runtime `import`
|
|
16
|
+
export pointed at emitted JavaScript. Source exports may serve types and
|
|
17
|
+
development tooling, but source-only runtime exports are not a substitute for
|
|
18
|
+
verifying executable build artifacts.
|
|
19
|
+
|
|
20
|
+
Use this loop for domain behavior and bug fixes:
|
|
21
|
+
|
|
22
|
+
1. Write or update the smallest failing test that describes observable
|
|
23
|
+
behavior.
|
|
24
|
+
2. Implement the minimum coherent behavior.
|
|
25
|
+
3. Refactor with tests green.
|
|
26
|
+
4. Add boundary and failure cases proportional to risk.
|
|
27
|
+
5. Run the owning suite, then broader repository checks.
|
|
28
|
+
|
|
29
|
+
TDD is a feedback technique, not a coverage quota. Avoid testing private helper
|
|
30
|
+
shape, reproducing the implementation in mocks, or creating snapshots that
|
|
31
|
+
hide meaningful behavioral assertions.
|
|
32
|
+
|
|
33
|
+
Vitest snapshots are acceptable for stable serialized output, diagnostics, and
|
|
34
|
+
small renderer fragments when review remains readable. They are unrelated to
|
|
35
|
+
Taskset repository safety snapshots.
|
|
36
|
+
|
|
37
|
+
## Taskset Test Strategy
|
|
38
|
+
|
|
39
|
+
### Types and schema
|
|
40
|
+
|
|
41
|
+
- valid and invalid enum values
|
|
42
|
+
- required and optional fields
|
|
43
|
+
- defaults and versionless task reads/writes
|
|
44
|
+
- forward and backward compatibility fixtures
|
|
45
|
+
|
|
46
|
+
### Parsing and serialization
|
|
47
|
+
|
|
48
|
+
- YAML frontmatter and Markdown body separation
|
|
49
|
+
- deterministic key ordering and final newlines
|
|
50
|
+
- parse/serialize round-trip stability
|
|
51
|
+
- Unicode and CRLF input
|
|
52
|
+
- unknown, malformed, and duplicate fields
|
|
53
|
+
- preservation of human-authored Markdown
|
|
54
|
+
|
|
55
|
+
### Storage and CRUD
|
|
56
|
+
|
|
57
|
+
- repository discovery
|
|
58
|
+
- create, read, update, move, and delete
|
|
59
|
+
- atomic replacement and cleanup after failure
|
|
60
|
+
- duplicate IDs and filename collisions
|
|
61
|
+
- path traversal and symlink boundaries
|
|
62
|
+
- explicit timestamps through a test clock
|
|
63
|
+
- restore previews and atomic apply
|
|
64
|
+
|
|
65
|
+
### Graph and search
|
|
66
|
+
|
|
67
|
+
- missing references and cycles
|
|
68
|
+
- canonical versus derived relationships
|
|
69
|
+
- stable traversal and query ordering
|
|
70
|
+
- project, package, file, and directory matching
|
|
71
|
+
- monorepo impact analysis fixtures
|
|
72
|
+
|
|
73
|
+
### Interfaces
|
|
74
|
+
|
|
75
|
+
- CLI exit codes, stdout, stderr, and structured output
|
|
76
|
+
- MCP tool schemas and error mapping
|
|
77
|
+
- TUI keyboard behavior
|
|
78
|
+
- extension lifecycle and repository switching
|
|
79
|
+
- Kanban and Office loading, stale, conflict, and failure states
|
|
80
|
+
|
|
81
|
+
Prefer realistic fixture repositories over mocks for filesystem and Git
|
|
82
|
+
behavior. Keep unit-level domain logic pure where possible.
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
# Workflows
|
|
2
|
+
|
|
3
|
+
Use this file as the routing map for repository workflows. Load only the topic
|
|
4
|
+
file needed for the change, then load additional files when the work crosses
|
|
5
|
+
that boundary.
|
|
6
|
+
|
|
7
|
+
## Routing
|
|
8
|
+
|
|
9
|
+
- [environment-and-pnpm.md](workflows/environment-and-pnpm.md): pinned Node and
|
|
10
|
+
pnpm versions, root commands, Turbo behavior, package scripts, Taskset
|
|
11
|
+
dogfooding, and dependency update caveats
|
|
12
|
+
- [dependencies-and-docs-site.md](workflows/dependencies-and-docs-site.md):
|
|
13
|
+
dependency installation rules, docs website workflow, GitHub Pages static
|
|
14
|
+
export, and backend dependency preferences
|
|
15
|
+
- [validation.md](workflows/validation.md): validation command order, root
|
|
16
|
+
checks, formatting, and handling unrelated scaffold failures
|
|
17
|
+
- [vitest-and-test-strategy.md](workflows/vitest-and-test-strategy.md): Vitest
|
|
18
|
+
workflow, TDD guidance, and Taskset test coverage strategy
|
|
19
|
+
- [persisted-data-and-git.md](workflows/persisted-data-and-git.md): persisted
|
|
20
|
+
data, generated view, Git fixture, compatibility, and concurrency workflows
|
|
21
|
+
|
|
22
|
+
## Loading Guidance
|
|
23
|
+
|
|
24
|
+
- For setup, root commands, package scripts, Turbo behavior, or Taskset
|
|
25
|
+
dogfooding, load `environment-and-pnpm.md`.
|
|
26
|
+
- For adding dependencies, website/docs builds, static export, or backend
|
|
27
|
+
dependency choices, load `dependencies-and-docs-site.md`.
|
|
28
|
+
- For any implementation or documentation change that needs verification, load
|
|
29
|
+
`validation.md`.
|
|
30
|
+
- For tests, bug fixes, parser behavior, CLI behavior, or domain changes, load
|
|
31
|
+
`vitest-and-test-strategy.md`.
|
|
32
|
+
- For persisted format changes, generated views, snapshots, Git fixture tests,
|
|
33
|
+
or concurrency-sensitive writes, load `persisted-data-and-git.md`.
|