@nolto/cli 0.12.0 → 0.13.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 +43 -3
- package/dist/index.js +648 -242
- package/dist/skill/roadmap-progress/SKILL.md +18 -2
- package/dist/skill/roadmap-progress/references/issue-cli.md +46 -0
- package/dist/skill/roadmap-progress/references/schema.md +4 -1
- package/dist/skill/roadmap-progress/scripts/roadmap.mjs +14 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -79,6 +79,8 @@ paths, and sends an idempotent full upsert to the bound project. A legacy
|
|
|
79
79
|
`.roadmap/roadmap.json` is migrated by `nolto sync` when no canonical roadmap
|
|
80
80
|
exists; `nolto watch` only warns and never migrates.
|
|
81
81
|
|
|
82
|
+
Optional task-only `issues` is an array of unique uppercase keys matching `^[A-Z][A-Z0-9]{1,9}-[1-9][0-9]{0,8}$` (for example `NOLTO-12`); empty arrays are allowed.
|
|
83
|
+
|
|
82
84
|
Timestamp fields (`updatedAt`, `startedAt`, and `completedAt`) must be RFC 3339 with a timezone offset (`2026-09-02T10:00:00+09:00` or `2026-09-02T01:00:00Z`); offset-less and date-only values are rejected. `dependsOn` items must be unique strings matching `^[a-z0-9][a-z0-9._-]*$`, and names, titles, and IDs must be actual strings.
|
|
83
85
|
|
|
84
86
|
The shared proxy rejects a sync request body over 10 MB with HTTP `413`. Free
|
|
@@ -91,7 +93,7 @@ CLI version; run `nolto init` in that repository to refresh it.
|
|
|
91
93
|
|
|
92
94
|
Use `nolto diff [slug]` before pushing to compare task status changes, added or
|
|
93
95
|
removed tasks and phases, and roadmap `updatedAt`, `currentTaskId`, and `summary`.
|
|
94
|
-
It does not compare `title`, `note`, `plan`, `dependsOn`, project metadata, or
|
|
96
|
+
It does not compare `title`, `note`, `plan`, `dependsOn`, `issues`, project metadata, or
|
|
95
97
|
ordering; use `git diff` for those. It exits with code 1 when differences are
|
|
96
98
|
found and does not change either side. `nolto pull [slug]` downloads all server
|
|
97
99
|
roadmaps, or one named roadmap, and intentionally overwrites the corresponding
|
|
@@ -99,6 +101,40 @@ local files after validation. It never deletes local-only roadmaps. Add `--merge
|
|
|
99
101
|
to preserve valid local changes using a deterministic structural merge, and review
|
|
100
102
|
the result with `git diff` before committing.
|
|
101
103
|
|
|
104
|
+
After roadmap sync, the CLI reads the latest 300 commits, extracts uppercase issue keys (for example `NOLTO-50`), and sends commit links. Subjects ending in `(#123)` or starting with `Merge pull request #123` also produce PR links. No issue key means no upload. Requests contain at most 500 links and 20 keys per link; longer sets are split without dropping associations. Titles and authors are capped at 500 characters. Repeated syncs are deduplicated on the server.
|
|
105
|
+
|
|
106
|
+
This requires `roadmap:sync` token permission and the project's `git_links` scope. Ingestion errors are warnings and do not fail roadmap sync. Disable with `nolto sync --no-git-links` or `NOLTO_GIT_LINKS=0` (also applies to watch). Watch collects at startup and on roadmap/plan changes, not on Git-only changes. Missing Git or a non-worktree is skipped. Counts distinguish newly linked rows, existing links, and unresolved keys (skipped). The log reads `git links: linked N (existing M, skipped K)`. JSON output includes `gitLinks: { linked, existing, skipped } | null`.
|
|
107
|
+
|
|
108
|
+
### Issues
|
|
109
|
+
|
|
110
|
+
All commands accept global `--project <id>`, `--json`, `--token <value>` and `--base-url <url>`.
|
|
111
|
+
Project priority: flag → NOLTO_PROJECT → nearest ancestor nolto.json → config defaultProjectId. Git is not required. An invalid nolto.json remains an error.
|
|
112
|
+
References accept a key (NOLTO-12) or number (12). Only the number is sent: a different key prefix does not protect against acting on the same number in the selected project.
|
|
113
|
+
|
|
114
|
+
| Command | Options |
|
|
115
|
+
|---|---|
|
|
116
|
+
| `issue list` | `--status <names...>`, `--assignee me/none/UUID`, `--closed exclude/include/only`, `--q`, `--sort updated/due/priority/number/created/assignee/status/type/subject`, `--order asc/desc`, `--page`, `--type`, `--priority high/normal/low`, `--category`, `--parent <ref-or-none>` |
|
|
117
|
+
| `issue view <ref>` | Global options |
|
|
118
|
+
| `issue create` | Required `--subject`; `--body` or `--body-file` (`-` for stdin); `--type`, `--status`, `--priority`, `--assignee`, `--due YYYY-MM-DD`, `--category <names...>`, `--parent <ref>`, `--phase <task-id>`, `--roadmap <slug>` |
|
|
119
|
+
| `issue update <ref>` | Same field options as create, subject optional; `--no-due`, `--no-parent`, `-m/--comment`; no phase/roadmap options |
|
|
120
|
+
| `issue comment <ref>` | `-m/--comment <text>` or `--body-file <path-or-dash>` |
|
|
121
|
+
| `issue close <ref>` | `--status <closed-name-or-UUID>`, `-m/--comment <text>` |
|
|
122
|
+
|
|
123
|
+
Status/type/category accept case-insensitive exact names or UUIDs from the project's settings. Unknown or ambiguous names list candidates. Create with `--type` and no body uses that type's body template. Update never inserts a template automatically. Close chooses the first closed status by sortOrder unless overridden; it fails if no matching closed status exists. `--assignee me` on writes resolves /api/me/profile; none clears the assignee.
|
|
124
|
+
|
|
125
|
+
List output is one line per issue plus `n / total (page p)`. View includes body and comments with API-token provenance. Writes print the issue key and URL. `--json` preserves API responses: list `{ issues, total, page, pageSize }`, view the full bundle, create `{ issue }`, update/close `{ issue, comment }`, comment `{ comment }`. Successful create with phase additionally returns `roadmap: { file, taskId }`. Human template creation adds `body: from template`. `whoami` adds scopes (null displayed as full) and project binding; JSON uses tokenScopes/tokenProject when introspection succeeds. Introspection failure is non-fatal and retains the old output.
|
|
126
|
+
|
|
127
|
+
`--phase` refers to a **task ID**, not a phase ID. It adds the issue key to task.issues in the selected local roadmap, avoids duplicates, upgrades legacy schema v1 to v2 on change and refreshes updatedAt with a local timezone offset. Run `nolto sync` afterward. If multiple roadmaps exist, use --roadmap (without .json). A local failure occurs after issue creation: the error includes the created key; repair the link instead of repeating create.
|
|
128
|
+
|
|
129
|
+
| Exit | Meaning |
|
|
130
|
+
|---|---|
|
|
131
|
+
| 0 | Success |
|
|
132
|
+
| 2 | Invalid input, recognized API 404, HTTP 422 (details shown), or local roadmap failure after creation |
|
|
133
|
+
| 3 | HTTP 401/403; token_scope/token_project includes a token settings hint |
|
|
134
|
+
| 4 | HTTP 402/429 (quota/rate limit). Token writes: 60/minute; wait Retry-After seconds before retrying. |
|
|
135
|
+
| 5 | Network/generic HTTP errors, including a 404 without an API error string |
|
|
136
|
+
|
|
137
|
+
|
|
102
138
|
## Merging roadmap conflicts
|
|
103
139
|
|
|
104
140
|
Roadmap files use Nolto's structural Git merge driver. The repository attribute
|
|
@@ -128,7 +164,7 @@ output fails validation, in which case it exits `1`. Resolution is deterministic
|
|
|
128
164
|
- Task status priority is `done` (with `completedAt`) > `blocked` >
|
|
129
165
|
`in-progress` > `todo`.
|
|
130
166
|
- `startedAt` keeps the earliest value, `completedAt` keeps the latest value,
|
|
131
|
-
and `dependsOn`
|
|
167
|
+
and `dependsOn` and `issues` are deduplicated unions (ours order, then new theirs entries).
|
|
132
168
|
- A deletion is honored only when both sides deleted the item.
|
|
133
169
|
- Phase order is ours first, followed by phases found only in theirs; phase
|
|
134
170
|
status is re-derived from the merged tasks.
|
|
@@ -182,6 +218,8 @@ Precedence: CLI flags > environment variables > `nolto.json` > config file > def
|
|
|
182
218
|
|
|
183
219
|
## JSON Output
|
|
184
220
|
|
|
221
|
+
`nolto issue … --json` returns the original API response; `create --phase` adds local `roadmap: { file, taskId }` metadata. `whoami` includes `tokenScopes` / `tokenProject` when token introspection succeeds.
|
|
222
|
+
|
|
185
223
|
Use the global `--json` option for machine-readable command output:
|
|
186
224
|
|
|
187
225
|
```bash
|
|
@@ -204,13 +242,15 @@ Errors are written to stderr:
|
|
|
204
242
|
|
|
205
243
|
## Exit Codes
|
|
206
244
|
|
|
245
|
+
Issue validation and API 404 with an error string exit 2; 422 includes details. Token scope/project denial exits 3 with a token-settings URL and whoami hint. A create/phase failure explicitly reports the already-created key.
|
|
246
|
+
|
|
207
247
|
| Code | Meaning |
|
|
208
248
|
|---|---|
|
|
209
249
|
| 0 | Success |
|
|
210
250
|
| 1 | Roadmap differences found (`nolto diff`) or unexpected command failure |
|
|
211
251
|
| 2 | Local input or file validation error |
|
|
212
252
|
| 3 | Authentication or authorization error |
|
|
213
|
-
| 4 | Rate limit response, or plan / quota limit (HTTP 402) |
|
|
253
|
+
| 4 | Rate limit response, or plan / quota limit (HTTP 402). API token writes: 60/minute; server message and Retry-After are displayed. |
|
|
214
254
|
| 5 | Network, DNS, or server error |
|
|
215
255
|
|
|
216
256
|
## License
|