@workit-dev/cli 0.0.0-stage → 1.0.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/README.md +29 -2
- package/assets/templates/headers.md +3 -0
- package/assets/templates/hygiene/.editorconfig +8 -0
- package/assets/templates/hygiene/.gitattributes +3 -0
- package/assets/templates/hygiene/CHANGELOG.md +14 -0
- package/assets/templates/hygiene/CONTRIBUTING.md +3 -0
- package/assets/templates/hygiene/LICENSE +21 -0
- package/assets/templates/hygiene/README.md +3 -0
- package/assets/templates/issue-update.md +5 -0
- package/assets/templates/plan-template.md +26 -0
- package/assets/templates/spec-template.md +64 -0
- package/assets/templates/workit-contract.md +13 -0
- package/dist/index.js +122606 -0
- package/package.json +51 -4
package/README.md
CHANGED
|
@@ -1,3 +1,30 @@
|
|
|
1
|
-
#
|
|
1
|
+
# @workit-dev/cli
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
[](https://github.com/BrainerVirus/workit/actions/workflows/ci.yml)
|
|
4
|
+
[](https://www.npmjs.com/package/@workit-dev/cli)
|
|
5
|
+
[](https://github.com/BrainerVirus/workit/blob/main/LICENSE)
|
|
6
|
+
|
|
7
|
+
The `workit` command: setup wizard, doctor and upgrades, plus the delivery
|
|
8
|
+
verbs agents use (`check`, `ledger`, `git`, `pr`, `ci`, `stack`,
|
|
9
|
+
`verify-delivery`, `grant`, `task`, …). Requires Node.js 24+; the published
|
|
10
|
+
CLI is a self-contained Node bundle.
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
npm i -g @workit-dev/cli
|
|
14
|
+
workit init # interactive setup for Claude Code, OpenCode, Cursor, Codex and Pi
|
|
15
|
+
workit doctor # offline installation health
|
|
16
|
+
workit help # every verb; `workit help <verb>` for one
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
Or run once without installing: `npx @workit-dev/cli init`.
|
|
20
|
+
`workit upgrade` updates the CLI and every host together (`--preview` only
|
|
21
|
+
looks).
|
|
22
|
+
|
|
23
|
+
Agents and hooks call `workit` from PATH. `workit doctor` warns (`workit_on_path`)
|
|
24
|
+
when none is found, when it does not run, or when it is older than an installed
|
|
25
|
+
host plugin, and prints the `npm i -g` (or `npx`) command for the matching version.
|
|
26
|
+
|
|
27
|
+
See the root [README](https://github.com/BrainerVirus/workit) for concepts and the
|
|
28
|
+
[CLI reference](https://github.com/BrainerVirus/workit#cli-reference), and the
|
|
29
|
+
[guides](https://github.com/BrainerVirus/workit/tree/main/docs/guides) for verification, delivery, grants and
|
|
30
|
+
configuration.
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes to this project will be documented in this file.
|
|
4
|
+
|
|
5
|
+
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
|
+
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
7
|
+
|
|
8
|
+
## [Unreleased]
|
|
9
|
+
|
|
10
|
+
### Added
|
|
11
|
+
|
|
12
|
+
### Changed
|
|
13
|
+
|
|
14
|
+
### Fixed
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) <YEAR> <HOLDER>
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
# <Feature> plan
|
|
2
|
+
|
|
3
|
+
Spec: `docs/<slug>/spec.md` · Goal: <one sentence>
|
|
4
|
+
|
|
5
|
+
A plan records decisions, not code: per slice the branch, what it touches, its
|
|
6
|
+
acceptance, how it is verified, and what it depends on (workit-shape
|
|
7
|
+
`references/slicing.md`). Independent slices fan out (workit-fanout);
|
|
8
|
+
dependent ones stack (`workit stack plan <bottom> … <top>`).
|
|
9
|
+
|
|
10
|
+
## Global constraints
|
|
11
|
+
|
|
12
|
+
- <project-wide requirement, one line each>
|
|
13
|
+
|
|
14
|
+
---
|
|
15
|
+
|
|
16
|
+
### S1 <type>/<slug> (base: main)
|
|
17
|
+
|
|
18
|
+
Touches: <areas, not line numbers>
|
|
19
|
+
Acceptance:
|
|
20
|
+
- Given <state>, When <action>, Then <observable result>
|
|
21
|
+
Verify: `workit check test`; verify-<app> "<feature>"
|
|
22
|
+
Decisions: <ledger refs or one-line rulings>
|
|
23
|
+
|
|
24
|
+
| Slice | Branch | Depends on | Status |
|
|
25
|
+
| --- | --- | --- | --- |
|
|
26
|
+
| S1 | <type>/<slug> | — | pending |
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
# Spec: <feature>
|
|
2
|
+
|
|
3
|
+
**Branch:** `feature/<slug>`
|
|
4
|
+
|
|
5
|
+
**Change:** ADDED|MODIFIED|REMOVED — <one-sentence intent>. (Small work with
|
|
6
|
+
no durable agreement: `Spec: none (<reason>)`, no file.)
|
|
7
|
+
|
|
8
|
+
## Context
|
|
9
|
+
|
|
10
|
+
<!-- Why does this exist? What problem does it solve? 1-3 sentences. -->
|
|
11
|
+
|
|
12
|
+
## Goals
|
|
13
|
+
|
|
14
|
+
- <!-- measurable, one per bullet -->
|
|
15
|
+
|
|
16
|
+
## Non-goals
|
|
17
|
+
|
|
18
|
+
- <!-- explicitly out of scope -->
|
|
19
|
+
|
|
20
|
+
## Architecture
|
|
21
|
+
|
|
22
|
+
<!-- Optional: only when a diagram argues a decision (workit-shape
|
|
23
|
+
references/diagrams.md); otherwise delete this section. -->
|
|
24
|
+
```mermaid
|
|
25
|
+
flowchart TD
|
|
26
|
+
A[Start] --> B[Step]
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
<!-- Optional: a UI choice still open gets an ASCII sketch (workit-shape
|
|
30
|
+
references/mockups.md). -->
|
|
31
|
+
```text
|
|
32
|
+
┌──────────────┐
|
|
33
|
+
│ Header │
|
|
34
|
+
└──────────────┘
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
## Data flow / contracts
|
|
38
|
+
|
|
39
|
+
<!-- REQUIRED when there is a glossary, scope comparison, or contracts: use markdown tables. -->
|
|
40
|
+
| Term | Meaning |
|
|
41
|
+
| --- | --- |
|
|
42
|
+
| <term> | <meaning> |
|
|
43
|
+
|
|
44
|
+
## Acceptance criteria
|
|
45
|
+
|
|
46
|
+
<!-- REQUIRED: enumerable, each verifiable. Numbered CA-01, CA-02, ... -->
|
|
47
|
+
<!-- Requirements use SHALL/MUST (one per bullet, observable, no HOW); each
|
|
48
|
+
carries at least one GIVEN/WHEN/THEN, including the most-regretted edge. -->
|
|
49
|
+
- CA-01 …
|
|
50
|
+
|
|
51
|
+
## Review checklist
|
|
52
|
+
|
|
53
|
+
<!-- Before implementation: intent matches; nothing extra; each requirement
|
|
54
|
+
testable with an exercising scenario; most-cared case covered;
|
|
55
|
+
tasks trace to requirements; you would sign if built exactly as written. -->
|
|
56
|
+
- [ ] …
|
|
57
|
+
|
|
58
|
+
## Decisions
|
|
59
|
+
|
|
60
|
+
- D-01 …
|
|
61
|
+
|
|
62
|
+
## Future work
|
|
63
|
+
|
|
64
|
+
- …
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
# Workit contract
|
|
2
|
+
|
|
3
|
+
Workit keeps one accountable lead and one shared task state. Inspect current
|
|
4
|
+
task state before acting; use only the shared operations for task, policy,
|
|
5
|
+
evidence, finding, decision, worker, and state changes. Authority is
|
|
6
|
+
bounded by the requested scope, current revision, caller/session provenance, and
|
|
7
|
+
observed capabilities; delivery is bounded by the workspace autonomy grants
|
|
8
|
+
(`workit grant show`). Never claim host enforcement or evidence that the host
|
|
9
|
+
cannot provide. Preserve unresolved requirements, gaps, and uncertain workers.
|
|
10
|
+
|
|
11
|
+
Focused methods are loaded only when the resolved policy requires them. A method
|
|
12
|
+
must call the shared operations and must not create a second lifecycle, approval
|
|
13
|
+
chain, or task-state representation.
|