@imagile-dev/toil 0.1.0-beta.5 → 0.1.0-beta.6
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 +11 -0
- package/dist/api.d.ts +80 -3
- package/dist/toil-lib.js +30927 -16929
- package/package.json +16 -13
package/README.md
CHANGED
|
@@ -189,6 +189,8 @@ Code the clone is also a plugin marketplace: `claude plugin marketplace add
|
|
|
189
189
|
| [`db`](https://imagile-dev.github.io/toil/connect/db/) | SQLite, PostgreSQL, MySQL / MariaDB, SQL Server, Oracle, Teradata, Hive and Impala: list schemas and tables, describe a table, preview rows, read-only queries with paging |
|
|
190
190
|
| [`util`](https://imagile-dev.github.io/toil/docs/utilities/) | Local commands with no connection or network: JWTs, dependency inventories, encodings and hashes, certificates, test and coverage reports, logs, secret scans, time and versions, Jira and Confluence markup, OpenAPI |
|
|
191
191
|
| [`skills`](https://imagile-dev.github.io/toil/docs/skills/) | Add a git-hosted skills marketplace, install its plugins for Codex, GitHub Copilot or Claude Code, switch them on and off |
|
|
192
|
+
| [`classify`](https://imagile-dev.github.io/toil/docs/classify/) | Sort a backlog into keep-the-lights-on and feature work, write the category back as a label or field, and count the mix |
|
|
193
|
+
| [`sample`](https://imagile-dev.github.io/toil/docs/sample/) | A generated sample team to try toil and Toil UI on before any connection |
|
|
192
194
|
| [The toil skill](https://imagile-dev.github.io/toil/docs/) | toil's own command reference for agents, one file per area |
|
|
193
195
|
| [Work tracking](https://imagile-dev.github.io/toil/connect/#trackers) (2) | Jira (Data Center and Cloud), Azure DevOps Server and Services |
|
|
194
196
|
| [Source and review](https://imagile-dev.github.io/toil/connect/#source) (3) | GitHub & GitHub Enterprise, Bitbucket (Data Center and Cloud), local git |
|
|
@@ -222,6 +224,15 @@ the gate and how review works. Questions and bug reports go through
|
|
|
222
224
|
[SUPPORT.md](.github/SUPPORT.md), and security reports through
|
|
223
225
|
[SECURITY.md](.github/SECURITY.md), never a public issue.
|
|
224
226
|
|
|
227
|
+
### From your clone
|
|
228
|
+
|
|
229
|
+
You don't need to be a maintainer to send a fix. Fork
|
|
230
|
+
[imagile-dev/toil](https://github.com/imagile-dev/toil), push a branch to your fork
|
|
231
|
+
and open a pull request against `main`, following CLAUDE.md. A maintainer reviews it
|
|
232
|
+
and merges it. An agent
|
|
233
|
+
working in your clone asks you before it forks or opens anything for you
|
|
234
|
+
([`skills/toil/install.md`](skills/toil/install.md), **Sending a fix back**).
|
|
235
|
+
|
|
225
236
|
## License
|
|
226
237
|
|
|
227
238
|
Apache License 2.0 © Imagile. See [LICENSE](LICENSE) and [NOTICE](NOTICE).
|
package/dist/api.d.ts
CHANGED
|
@@ -340,6 +340,35 @@ interface History {
|
|
|
340
340
|
transitions: Transition[];
|
|
341
341
|
iterations: IterationChange[];
|
|
342
342
|
}
|
|
343
|
+
/**
|
|
344
|
+
* A release, or a version an item affects: Jira's fix and affects versions,
|
|
345
|
+
* a GitHub milestone, and a field an Azure DevOps toil project names.
|
|
346
|
+
* `released` is null where the source can't say (a text field), and `date` is
|
|
347
|
+
* the day the release is due or went out, null when it has none.
|
|
348
|
+
*/
|
|
349
|
+
interface Release {
|
|
350
|
+
id: string | null;
|
|
351
|
+
name: string;
|
|
352
|
+
released: boolean | null;
|
|
353
|
+
date: string | null;
|
|
354
|
+
/**
|
|
355
|
+
* Optional. The day (`YYYY-MM-DD`) work on the release started, where the source says
|
|
356
|
+
* (Jira's version `startDate`); null when the source carries the field but it is empty.
|
|
357
|
+
* Absent: the source has no such field, or the read never fetched it.
|
|
358
|
+
*/
|
|
359
|
+
start?: string | null;
|
|
360
|
+
}
|
|
361
|
+
/** One level of an item's parent chain, as `ancestors` holds it, nearest parent first. */
|
|
362
|
+
interface Ancestor {
|
|
363
|
+
id: string;
|
|
364
|
+
type: WorkItemType;
|
|
365
|
+
typeName: string | null;
|
|
366
|
+
title: string;
|
|
367
|
+
}
|
|
368
|
+
/** An Azure DevOps area path (`Imagile\Payments\Web`), kept whole so a split can cut it at any depth. */
|
|
369
|
+
interface AreaPath {
|
|
370
|
+
path: string;
|
|
371
|
+
}
|
|
343
372
|
interface Unmapped {
|
|
344
373
|
field: string;
|
|
345
374
|
reason: string;
|
|
@@ -348,6 +377,17 @@ interface Body {
|
|
|
348
377
|
format: 'markdown' | 'wiki' | 'adf' | 'html';
|
|
349
378
|
content: string | Record<string, unknown>;
|
|
350
379
|
}
|
|
380
|
+
/** One comment on a work item, as a stand-up reads it: who wrote it, when, and its text as plain text on one line. */
|
|
381
|
+
interface Comment {
|
|
382
|
+
id: string;
|
|
383
|
+
author: Person | null;
|
|
384
|
+
/** UTC, as `toISOString` writes it. */
|
|
385
|
+
at: string;
|
|
386
|
+
/** Plain text, markup taken out, capped; never HTML. */
|
|
387
|
+
text: string;
|
|
388
|
+
/** A link to the comment where the tracker gives one, else null. */
|
|
389
|
+
url: string | null;
|
|
390
|
+
}
|
|
351
391
|
interface WorkItem {
|
|
352
392
|
owi: typeof OWI_VERSION;
|
|
353
393
|
id: string;
|
|
@@ -383,6 +423,22 @@ interface WorkItem {
|
|
|
383
423
|
history: History | null;
|
|
384
424
|
unmapped: Unmapped[];
|
|
385
425
|
native: Record<string, unknown>;
|
|
426
|
+
/** Fix versions (Jira), the milestone (GitHub), or the field `fields release` names (Azure DevOps). */
|
|
427
|
+
releases?: Release[];
|
|
428
|
+
/** Affected versions: Jira's `versions`, or the field `fields affects` names (Azure DevOps). */
|
|
429
|
+
affects?: Release[];
|
|
430
|
+
/** Jira components, by name. */
|
|
431
|
+
components?: string[];
|
|
432
|
+
/** Azure DevOps' area path; null when the record carries none. */
|
|
433
|
+
area?: AreaPath | null;
|
|
434
|
+
/** Every sprint or iteration the item has been in, where the source lists them; `iteration` stays the current one. */
|
|
435
|
+
sprints?: Iteration[];
|
|
436
|
+
/** The values of each dimension a toil project names, by dimension name; a value is always a list, since a field may hold several. */
|
|
437
|
+
dims?: Record<string, string[]>;
|
|
438
|
+
/** The parent chain among the records mapped together, nearest first. It ends where a parent isn't in the input. */
|
|
439
|
+
ancestors?: Ancestor[];
|
|
440
|
+
/** The comments the read returned, oldest first, the newest 20 at most. Absent: not read (a Jira search that didn't ask for `comment`). []: read, none. */
|
|
441
|
+
comments?: Comment[];
|
|
386
442
|
}
|
|
387
443
|
/** A history mapped for an item that wasn't in the same input. */
|
|
388
444
|
interface OrphanHistory {
|
|
@@ -395,7 +451,7 @@ interface OrphanHistory {
|
|
|
395
451
|
* the label pattern that holds an estimate (`points: {n}`), and
|
|
396
452
|
* `iterationDays`, how long a milestone's sprint runs.
|
|
397
453
|
*/
|
|
398
|
-
declare const OVERRIDABLE: readonly ["estimate", "estimateUnit", "priority", "type", "team", "dueDate", "iteration", "estimateLabel", "iterationDays"];
|
|
454
|
+
declare const OVERRIDABLE: readonly ["estimate", "estimateUnit", "priority", "type", "team", "dueDate", "iteration", "release", "affects", "estimateLabel", "iterationDays"];
|
|
399
455
|
type Overridable = (typeof OVERRIDABLE)[number];
|
|
400
456
|
type FieldOverrides = Partial<Record<Overridable, string>>;
|
|
401
457
|
type ChangeState = 'OPEN' | 'MERGED' | 'DECLINED' | 'DRAFT';
|
|
@@ -855,6 +911,21 @@ interface ConnectionField {
|
|
|
855
911
|
appliesTo?: readonly string[];
|
|
856
912
|
/** The variants whose connections can't do without it, though it isn't required of every one. */
|
|
857
913
|
requiredFor?: readonly string[];
|
|
914
|
+
/**
|
|
915
|
+
* On a pairing setting (`apiTokenFrom`): the secret it borrows from another
|
|
916
|
+
* area's connection, and when `connections add` and `login` offer that
|
|
917
|
+
* instead of asking for the secret (as the question `borrow:<key>`, `y` or
|
|
918
|
+
* `n`): both connections hold every value in `when`, share a host if
|
|
919
|
+
* `sameHost`, and the lender's secret resolves; `match` names the settings
|
|
920
|
+
* the borrowed secret only works with. Left out where nothing is offered.
|
|
921
|
+
*/
|
|
922
|
+
borrows?: {
|
|
923
|
+
area: string;
|
|
924
|
+
key: string;
|
|
925
|
+
when?: Readonly<Record<string, string>>;
|
|
926
|
+
sameHost?: boolean;
|
|
927
|
+
match?: readonly string[];
|
|
928
|
+
};
|
|
858
929
|
}
|
|
859
930
|
/**
|
|
860
931
|
* The commands and areas this toil has. `commands` is what `execute()`
|
|
@@ -876,7 +947,10 @@ interface Registry {
|
|
|
876
947
|
* `confirm-name` (type the connection's name to turn writes on), `unwrap:<key>`
|
|
877
948
|
* (the secret for `<key>` is in quotes or starts with `Bearer ` or `token `:
|
|
878
949
|
* `y` stores it without them, `n` as entered; `checkSecret` says which before
|
|
879
|
-
* the call, so a host can ask its person first),
|
|
950
|
+
* the call, so a host can ask its person first), `borrow:<key>` (use the
|
|
951
|
+
* secret for `<key>` from the other area's connection the question names
|
|
952
|
+
* instead of entering one: `y` or `n`; `ConnectionField.borrows` says when it
|
|
953
|
+
* is asked), for `toil projects onboard`
|
|
880
954
|
* `create:<section>` (add a connection that toil project section needs: `y` or `n`),
|
|
881
955
|
* `name:<section>` (the new connection's name) and `pin:<section>` (which
|
|
882
956
|
* matching connection the person's own copy uses), and `consent`
|
|
@@ -987,6 +1061,8 @@ interface OwiMapOptions {
|
|
|
987
1061
|
keyPatterns?: Array<string | KeyPattern>;
|
|
988
1062
|
/** Pull request author kinds set by hand, by author id: `{ "release-bot": "BOT" }`, or `id=KIND` strings. */
|
|
989
1063
|
authorKinds?: Record<string, string> | string[];
|
|
1064
|
+
/** The toil project's `dimensions`: each dimension's name to the field that holds it per area. Copied onto each item's `dims`. */
|
|
1065
|
+
dimensions?: Record<string, Record<string, string>>;
|
|
990
1066
|
}
|
|
991
1067
|
/**
|
|
992
1068
|
* Likely duplicates among OWI records you already hold, scored the way
|
|
@@ -1016,4 +1092,5 @@ declare const owiSchema: Record<string, unknown>;
|
|
|
1016
1092
|
*/
|
|
1017
1093
|
declare function checkSecret(raw: string, rules: SecretRules): SecretCheck;
|
|
1018
1094
|
|
|
1019
|
-
export {
|
|
1095
|
+
export { checkSecret, contractVersion, execute, findSimilar, mapOwi, owiSchema, owiVersion, registry, version };
|
|
1096
|
+
export type { ApiAnswer, AreaSummary, AuthorKind, AuthorKindSource, Body, Change, ChangeSize, ChangeState, ChecksState, CommandInfo, CommandKind, ConnectionChoices, ConnectionField, ContextReport, ContextSource, ContextValue, Envelope, ErrorBody, ErrorCode, Estimate, EstimateUnit, ExecuteOptions, ExecutePerson, FieldOverrides, History, Iteration, IterationChange, KeyPattern, Link, LinkType, Meta, OrphanHistory, OwiMapOptions, OwiResult, OwiSkipped, Page, PageProgress, PairSearch, Person, ProgressEvent, Question, Registry, RequestProgress, RetryProgress, Review, ReviewState, Reviewer, ReviewerState, SecretCheck, SecretRules, SecretWrapper, SimilarField, SimilarItem, SimilarMatch, SimilarOptions, SimilarPair, SimilarParts, SimilarRef, SimilarRequest, SimilarResult, SimilarWhy, StatusCategory, ToilProjectReport, Transition, Unmapped, Warning, WorkItem, WorkItemType };
|