@staff0rd/assist 0.461.3 → 0.462.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/dist/commands/sessions/web/bundle.js +418 -418
- package/dist/index.js +284 -52
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -6,7 +6,7 @@ import { Command } from "commander";
|
|
|
6
6
|
// package.json
|
|
7
7
|
var package_default = {
|
|
8
8
|
name: "@staff0rd/assist",
|
|
9
|
-
version: "0.
|
|
9
|
+
version: "0.462.0",
|
|
10
10
|
type: "module",
|
|
11
11
|
main: "dist/index.js",
|
|
12
12
|
bin: {
|
|
@@ -3365,7 +3365,7 @@ function collectHashComments(content, options2) {
|
|
|
3365
3365
|
function collectComments(sourceFile) {
|
|
3366
3366
|
const seen = /* @__PURE__ */ new Set();
|
|
3367
3367
|
const comments3 = [];
|
|
3368
|
-
const
|
|
3368
|
+
const collect5 = (node) => {
|
|
3369
3369
|
for (const range of [
|
|
3370
3370
|
...node.getLeadingCommentRanges(),
|
|
3371
3371
|
...node.getTrailingCommentRanges()
|
|
@@ -3376,8 +3376,8 @@ function collectComments(sourceFile) {
|
|
|
3376
3376
|
comments3.push({ pos, text: range.getText() });
|
|
3377
3377
|
}
|
|
3378
3378
|
};
|
|
3379
|
-
|
|
3380
|
-
sourceFile.forEachDescendant(
|
|
3379
|
+
collect5(sourceFile);
|
|
3380
|
+
sourceFile.forEachDescendant(collect5);
|
|
3381
3381
|
return comments3;
|
|
3382
3382
|
}
|
|
3383
3383
|
|
|
@@ -3596,16 +3596,19 @@ var WRAPPER_TYPES = /* @__PURE__ */ new Set([
|
|
|
3596
3596
|
"readonly",
|
|
3597
3597
|
"catch"
|
|
3598
3598
|
]);
|
|
3599
|
+
var OPTIONAL_TYPES = /* @__PURE__ */ new Set(["optional", "nullish"]);
|
|
3599
3600
|
function unwrapSchemaNode(node) {
|
|
3600
3601
|
let current = node;
|
|
3601
3602
|
let defaultValue;
|
|
3603
|
+
let optional = false;
|
|
3602
3604
|
while (current.def && WRAPPER_TYPES.has(current.def.type ?? "") && current.def.innerType) {
|
|
3603
3605
|
if (current.def.type === "default" && defaultValue === void 0) {
|
|
3604
3606
|
defaultValue = current.def.defaultValue;
|
|
3605
3607
|
}
|
|
3608
|
+
if (OPTIONAL_TYPES.has(current.def.type ?? "")) optional = true;
|
|
3606
3609
|
current = current.def.innerType;
|
|
3607
3610
|
}
|
|
3608
|
-
return { inner: current, defaultValue };
|
|
3611
|
+
return { inner: current, defaultValue, optional };
|
|
3609
3612
|
}
|
|
3610
3613
|
|
|
3611
3614
|
// src/shared/scalarUnionMembers.ts
|
|
@@ -3649,7 +3652,67 @@ function scalarArrayItemType(node) {
|
|
|
3649
3652
|
return isScalarLeafType(type) ? type : void 0;
|
|
3650
3653
|
}
|
|
3651
3654
|
|
|
3652
|
-
// src/shared/
|
|
3655
|
+
// src/shared/listConfigNode.ts
|
|
3656
|
+
function scalarListNode(inner, base, item) {
|
|
3657
|
+
const itemType = scalarArrayItemType(inner);
|
|
3658
|
+
if (!itemType || item.kind !== "scalar") return void 0;
|
|
3659
|
+
return { ...base, kind: "scalarList", itemType, item };
|
|
3660
|
+
}
|
|
3661
|
+
function objectListNode(base, item) {
|
|
3662
|
+
if (item.kind !== "object" && item.kind !== "unionOfObjects")
|
|
3663
|
+
return void 0;
|
|
3664
|
+
return { ...base, kind: "objectList", item };
|
|
3665
|
+
}
|
|
3666
|
+
function listConfigNode(inner, base, build2) {
|
|
3667
|
+
const element = inner.def?.element;
|
|
3668
|
+
if (inner.def?.type !== "array" || !element) return void 0;
|
|
3669
|
+
const item = build2(element, [...base.path, { kind: "item" }]);
|
|
3670
|
+
return scalarListNode(inner, base, item) ?? objectListNode(base, item);
|
|
3671
|
+
}
|
|
3672
|
+
|
|
3673
|
+
// src/shared/objectConfigNode.ts
|
|
3674
|
+
function objectConfigNode(inner, base, build2) {
|
|
3675
|
+
const shape = inner.def?.shape;
|
|
3676
|
+
if (inner.def?.type !== "object" || !shape) return void 0;
|
|
3677
|
+
const fields = Object.entries(shape).map(
|
|
3678
|
+
([name, child]) => build2(child, [...base.path, { kind: "key", name }])
|
|
3679
|
+
);
|
|
3680
|
+
return { ...base, kind: "object", fields };
|
|
3681
|
+
}
|
|
3682
|
+
function unionOfObjectsConfigNode(inner, base, build2) {
|
|
3683
|
+
const options2 = inner.def?.options;
|
|
3684
|
+
if (inner.def?.type !== "union" || !options2?.length) return void 0;
|
|
3685
|
+
const variants = [];
|
|
3686
|
+
for (const option of options2) {
|
|
3687
|
+
const variant = build2(option, base.path);
|
|
3688
|
+
if (variant.kind !== "object") return void 0;
|
|
3689
|
+
variants.push(variant);
|
|
3690
|
+
}
|
|
3691
|
+
return { ...base, kind: "unionOfObjects", variants };
|
|
3692
|
+
}
|
|
3693
|
+
|
|
3694
|
+
// src/shared/recordConfigNode.ts
|
|
3695
|
+
function recordConfigNode(inner, base, build2) {
|
|
3696
|
+
const valueType = inner.def?.valueType;
|
|
3697
|
+
if (inner.def?.type !== "record" || !valueType) return void 0;
|
|
3698
|
+
const value = build2(valueType, [...base.path, { kind: "entry" }]);
|
|
3699
|
+
return { ...base, kind: "record", value };
|
|
3700
|
+
}
|
|
3701
|
+
|
|
3702
|
+
// src/shared/scalarConfigNode.ts
|
|
3703
|
+
function scalarConfigNode(inner, base) {
|
|
3704
|
+
const unionTypes = scalarUnionMembers(inner);
|
|
3705
|
+
if (unionTypes) return { ...base, kind: "scalar", type: "union", unionTypes };
|
|
3706
|
+
const type = leafTypeOf(inner);
|
|
3707
|
+
if (!isScalarLeafType(type)) return void 0;
|
|
3708
|
+
const values = type === "enum" ? enumValues(inner) : void 0;
|
|
3709
|
+
return {
|
|
3710
|
+
...base,
|
|
3711
|
+
kind: "scalar",
|
|
3712
|
+
type,
|
|
3713
|
+
...values ? { enumValues: values } : {}
|
|
3714
|
+
};
|
|
3715
|
+
}
|
|
3653
3716
|
function enumValues(node) {
|
|
3654
3717
|
const entries = node.def?.entries;
|
|
3655
3718
|
if (!entries) return void 0;
|
|
@@ -3657,31 +3720,81 @@ function enumValues(node) {
|
|
|
3657
3720
|
(value) => typeof value === "string"
|
|
3658
3721
|
);
|
|
3659
3722
|
}
|
|
3660
|
-
|
|
3661
|
-
|
|
3662
|
-
|
|
3663
|
-
|
|
3664
|
-
|
|
3665
|
-
|
|
3666
|
-
const
|
|
3667
|
-
|
|
3668
|
-
|
|
3723
|
+
|
|
3724
|
+
// src/shared/describeConfigNode.ts
|
|
3725
|
+
function opaqueConfigNode(inner, base) {
|
|
3726
|
+
return { ...base, kind: "other", type: leafTypeOf(inner) };
|
|
3727
|
+
}
|
|
3728
|
+
function build(node, path71) {
|
|
3729
|
+
const { inner, defaultValue, optional } = unwrapSchemaNode(node);
|
|
3730
|
+
const base = {
|
|
3731
|
+
path: path71,
|
|
3732
|
+
...optional ? { optional: true } : {},
|
|
3733
|
+
...defaultValue === void 0 ? {} : { defaultValue }
|
|
3734
|
+
};
|
|
3735
|
+
return scalarConfigNode(inner, base) ?? objectConfigNode(inner, base, build) ?? listConfigNode(inner, base, build) ?? recordConfigNode(inner, base, build) ?? unionOfObjectsConfigNode(inner, base, build) ?? opaqueConfigNode(inner, base);
|
|
3736
|
+
}
|
|
3737
|
+
function describeConfigNode(schema2) {
|
|
3738
|
+
return build(schema2, []);
|
|
3739
|
+
}
|
|
3740
|
+
|
|
3741
|
+
// src/shared/formatConfigPath.ts
|
|
3742
|
+
var RECORD_ENTRY_TOKEN = "*";
|
|
3743
|
+
function segmentText(segment) {
|
|
3744
|
+
if (segment.kind === "key") return segment.name;
|
|
3745
|
+
if (segment.kind === "entry") return RECORD_ENTRY_TOKEN;
|
|
3746
|
+
if (segment.kind === "index") return `[${segment.index}]`;
|
|
3747
|
+
return "[]";
|
|
3748
|
+
}
|
|
3749
|
+
function formatConfigPath(path71) {
|
|
3750
|
+
let text17 = "";
|
|
3751
|
+
for (const segment of path71) {
|
|
3752
|
+
const dotted = segment.kind === "key" || segment.kind === "entry";
|
|
3753
|
+
const rendered = segmentText(segment);
|
|
3754
|
+
text17 += dotted && text17 ? `.${rendered}` : rendered;
|
|
3755
|
+
}
|
|
3756
|
+
return text17;
|
|
3757
|
+
}
|
|
3758
|
+
|
|
3759
|
+
// src/shared/describeConfigLeaves.ts
|
|
3760
|
+
function leafType(node) {
|
|
3761
|
+
switch (node.kind) {
|
|
3762
|
+
case "scalar":
|
|
3763
|
+
return node.type;
|
|
3764
|
+
case "scalarList":
|
|
3765
|
+
case "objectList":
|
|
3766
|
+
return "array";
|
|
3767
|
+
case "record":
|
|
3768
|
+
return "record";
|
|
3769
|
+
case "other":
|
|
3770
|
+
return node.type;
|
|
3771
|
+
default:
|
|
3772
|
+
return "other";
|
|
3773
|
+
}
|
|
3774
|
+
}
|
|
3775
|
+
function toLeaf(node) {
|
|
3776
|
+
const leaf = {
|
|
3777
|
+
key: formatConfigPath(node.path),
|
|
3778
|
+
type: leafType(node)
|
|
3779
|
+
};
|
|
3780
|
+
if (node.kind === "scalar") {
|
|
3781
|
+
if (node.enumValues) leaf.enumValues = node.enumValues;
|
|
3782
|
+
if (node.unionTypes) leaf.unionTypes = node.unionTypes;
|
|
3783
|
+
}
|
|
3784
|
+
if (node.kind === "scalarList") leaf.itemType = node.itemType;
|
|
3785
|
+
if (node.defaultValue !== void 0) leaf.defaultValue = node.defaultValue;
|
|
3669
3786
|
return leaf;
|
|
3670
3787
|
}
|
|
3671
|
-
function
|
|
3672
|
-
|
|
3673
|
-
|
|
3674
|
-
if (inner.def?.type === "object" && shape) {
|
|
3675
|
-
for (const [key, child] of Object.entries(shape)) {
|
|
3676
|
-
collect(child, prefix2 ? `${prefix2}.${key}` : key, out);
|
|
3677
|
-
}
|
|
3788
|
+
function flatten(node, out) {
|
|
3789
|
+
if (node.kind === "object") {
|
|
3790
|
+
for (const field of node.fields) flatten(field, out);
|
|
3678
3791
|
return;
|
|
3679
3792
|
}
|
|
3680
|
-
out.push(toLeaf(
|
|
3793
|
+
out.push(toLeaf(node));
|
|
3681
3794
|
}
|
|
3682
3795
|
function describeConfigLeaves(schema2) {
|
|
3683
3796
|
const out = [];
|
|
3684
|
-
|
|
3797
|
+
flatten(describeConfigNode(schema2), out);
|
|
3685
3798
|
return out.sort((a, b) => a.key < b.key ? -1 : a.key > b.key ? 1 : 0);
|
|
3686
3799
|
}
|
|
3687
3800
|
|
|
@@ -9224,16 +9337,104 @@ function resolveConfigSource(key, layers) {
|
|
|
9224
9337
|
return "default";
|
|
9225
9338
|
}
|
|
9226
9339
|
|
|
9340
|
+
// src/shared/configNodeFieldName.ts
|
|
9341
|
+
function configNodeFieldName(node) {
|
|
9342
|
+
const last = node.path.at(-1);
|
|
9343
|
+
return last?.kind === "key" ? last.name : void 0;
|
|
9344
|
+
}
|
|
9345
|
+
|
|
9346
|
+
// src/shared/findConfigNode.ts
|
|
9347
|
+
function objectField(node, segment) {
|
|
9348
|
+
if (segment.kind !== "key") return void 0;
|
|
9349
|
+
return node.fields.find(
|
|
9350
|
+
(field) => configNodeFieldName(field) === segment.name
|
|
9351
|
+
);
|
|
9352
|
+
}
|
|
9353
|
+
function variantField(node, segment) {
|
|
9354
|
+
for (const variant of node.variants) {
|
|
9355
|
+
const found = objectField(variant, segment);
|
|
9356
|
+
if (found) return found;
|
|
9357
|
+
}
|
|
9358
|
+
return void 0;
|
|
9359
|
+
}
|
|
9360
|
+
function step(node, segment) {
|
|
9361
|
+
const intoItem = segment.kind === "item" || segment.kind === "index";
|
|
9362
|
+
const intoEntry = segment.kind === "entry" || segment.kind === "key";
|
|
9363
|
+
switch (node.kind) {
|
|
9364
|
+
case "object":
|
|
9365
|
+
return objectField(node, segment);
|
|
9366
|
+
case "unionOfObjects":
|
|
9367
|
+
return variantField(node, segment);
|
|
9368
|
+
case "objectList":
|
|
9369
|
+
case "scalarList":
|
|
9370
|
+
return intoItem ? node.item : void 0;
|
|
9371
|
+
case "record":
|
|
9372
|
+
return intoEntry ? node.value : void 0;
|
|
9373
|
+
default:
|
|
9374
|
+
return void 0;
|
|
9375
|
+
}
|
|
9376
|
+
}
|
|
9377
|
+
function findConfigNode(root, path71) {
|
|
9378
|
+
let current = root;
|
|
9379
|
+
for (const segment of path71) {
|
|
9380
|
+
if (!current) return void 0;
|
|
9381
|
+
current = step(current, segment);
|
|
9382
|
+
}
|
|
9383
|
+
return current;
|
|
9384
|
+
}
|
|
9385
|
+
|
|
9386
|
+
// src/shared/parseConfigPath.ts
|
|
9387
|
+
var INDEX = /^\d+$/;
|
|
9388
|
+
function bracketSegment(inner) {
|
|
9389
|
+
if (inner === "") return { kind: "item" };
|
|
9390
|
+
return INDEX.test(inner) ? { kind: "index", index: Number(inner) } : void 0;
|
|
9391
|
+
}
|
|
9392
|
+
function nameSegment(name) {
|
|
9393
|
+
return name === RECORD_ENTRY_TOKEN ? { kind: "entry" } : { kind: "key", name };
|
|
9394
|
+
}
|
|
9395
|
+
function parseConfigPath(text17) {
|
|
9396
|
+
const path71 = [];
|
|
9397
|
+
let at2 = 0;
|
|
9398
|
+
while (at2 < text17.length) {
|
|
9399
|
+
if (text17[at2] === "[") {
|
|
9400
|
+
const close = text17.indexOf("]", at2);
|
|
9401
|
+
const segment = close === -1 ? void 0 : bracketSegment(text17.slice(at2 + 1, close));
|
|
9402
|
+
if (!segment) return void 0;
|
|
9403
|
+
path71.push(segment);
|
|
9404
|
+
at2 = close + 1;
|
|
9405
|
+
continue;
|
|
9406
|
+
}
|
|
9407
|
+
if (text17[at2] === ".") {
|
|
9408
|
+
if (path71.length === 0) return void 0;
|
|
9409
|
+
at2 += 1;
|
|
9410
|
+
}
|
|
9411
|
+
const start3 = at2;
|
|
9412
|
+
while (at2 < text17.length && text17[at2] !== "." && text17[at2] !== "[") at2 += 1;
|
|
9413
|
+
const name = text17.slice(start3, at2);
|
|
9414
|
+
if (!name) return void 0;
|
|
9415
|
+
path71.push(nameSegment(name));
|
|
9416
|
+
}
|
|
9417
|
+
return path71;
|
|
9418
|
+
}
|
|
9419
|
+
|
|
9420
|
+
// src/commands/config/configEntryNode.ts
|
|
9421
|
+
function configEntryNode(root, key) {
|
|
9422
|
+
const path71 = parseConfigPath(key);
|
|
9423
|
+
return path71 ? findConfigNode(root, path71) : void 0;
|
|
9424
|
+
}
|
|
9425
|
+
|
|
9227
9426
|
// src/commands/config/readConfigEntries.ts
|
|
9228
9427
|
var KEYS_STRIPPED_FROM_MERGED_CONFIG = /* @__PURE__ */ new Set(["repos"]);
|
|
9229
9428
|
function readConfigEntries(cwd) {
|
|
9230
9429
|
const config = loadConfigFrom(cwd);
|
|
9231
9430
|
const layers = readRawConfigLayers(cwd);
|
|
9431
|
+
const schema2 = describeConfigNode(assistConfigSchema);
|
|
9232
9432
|
return describeConfigLeaves(assistConfigSchema).filter((leaf) => !KEYS_STRIPPED_FROM_MERGED_CONFIG.has(leaf.key)).map((leaf) => ({
|
|
9233
9433
|
...leaf,
|
|
9234
9434
|
value: getNestedValue(config, leaf.key),
|
|
9235
9435
|
source: resolveConfigSource(leaf.key, layers),
|
|
9236
|
-
globalOnly: isGlobalOnlyConfigKey(leaf.key)
|
|
9436
|
+
globalOnly: isGlobalOnlyConfigKey(leaf.key),
|
|
9437
|
+
node: configEntryNode(schema2, leaf.key)
|
|
9237
9438
|
}));
|
|
9238
9439
|
}
|
|
9239
9440
|
|
|
@@ -10155,6 +10356,41 @@ function coerceString(key, raw) {
|
|
|
10155
10356
|
return { ok: false, error: `${key}: expected a string` };
|
|
10156
10357
|
}
|
|
10157
10358
|
|
|
10359
|
+
// src/shared/configLeafSchema.ts
|
|
10360
|
+
function configLeafSchema(schema2, key) {
|
|
10361
|
+
let current = schema2;
|
|
10362
|
+
for (const name of key.split(".")) {
|
|
10363
|
+
const { inner } = unwrapSchemaNode(current);
|
|
10364
|
+
const child = inner.def?.type === "object" ? inner.def.shape?.[name] : void 0;
|
|
10365
|
+
if (!child) return void 0;
|
|
10366
|
+
current = child;
|
|
10367
|
+
}
|
|
10368
|
+
return current;
|
|
10369
|
+
}
|
|
10370
|
+
|
|
10371
|
+
// src/commands/config/coerceStructuredConfigValue.ts
|
|
10372
|
+
function coerceStructuredConfigValue(key, raw) {
|
|
10373
|
+
const schema2 = configLeafSchema(assistConfigSchema, key);
|
|
10374
|
+
if (!schema2) return { ok: false, error: `Unknown config key "${key}"` };
|
|
10375
|
+
const parsed = schema2.safeParse(raw);
|
|
10376
|
+
if (parsed.success)
|
|
10377
|
+
return { ok: true, value: parsed.data };
|
|
10378
|
+
return {
|
|
10379
|
+
ok: false,
|
|
10380
|
+
error: parsed.error.issues.map((issue) => formatIssue2(key, issue)).join("\n")
|
|
10381
|
+
};
|
|
10382
|
+
}
|
|
10383
|
+
function formatIssue2(key, issue) {
|
|
10384
|
+
const path71 = formatConfigPath([
|
|
10385
|
+
{ kind: "key", name: key },
|
|
10386
|
+
...issue.path.map(toSegment)
|
|
10387
|
+
]);
|
|
10388
|
+
return `${path71}: ${issue.message}`;
|
|
10389
|
+
}
|
|
10390
|
+
function toSegment(part) {
|
|
10391
|
+
return typeof part === "number" ? { kind: "index", index: part } : { kind: "key", name: String(part) };
|
|
10392
|
+
}
|
|
10393
|
+
|
|
10158
10394
|
// src/commands/config/coerceConfigValue.ts
|
|
10159
10395
|
var EDITABLE_TYPES = /* @__PURE__ */ new Set([
|
|
10160
10396
|
"string",
|
|
@@ -10169,12 +10405,8 @@ function coerceConfigValue(key, raw) {
|
|
|
10169
10405
|
);
|
|
10170
10406
|
if (!leaf) return { ok: false, error: `Unknown config key "${key}"` };
|
|
10171
10407
|
if (leaf.itemType) return coerceScalarList(key, raw, leaf.itemType);
|
|
10172
|
-
if (!EDITABLE_TYPES.has(leaf.type))
|
|
10173
|
-
return
|
|
10174
|
-
ok: false,
|
|
10175
|
-
error: `"${key}" is a ${leaf.type} value and is read-only here`
|
|
10176
|
-
};
|
|
10177
|
-
}
|
|
10408
|
+
if (!EDITABLE_TYPES.has(leaf.type))
|
|
10409
|
+
return coerceStructuredConfigValue(key, raw);
|
|
10178
10410
|
if (leaf.type === "union")
|
|
10179
10411
|
return coerceUnion(key, raw, leaf.unionTypes ?? []);
|
|
10180
10412
|
return coerceConfigScalar(key, raw, leaf.type);
|
|
@@ -13137,14 +13369,14 @@ async function updatePhase(id, phase, options2) {
|
|
|
13137
13369
|
}
|
|
13138
13370
|
|
|
13139
13371
|
// src/commands/backlog/registerUpdatePhaseCommand.ts
|
|
13140
|
-
function
|
|
13372
|
+
function collect(value, previous) {
|
|
13141
13373
|
return [...previous, value];
|
|
13142
13374
|
}
|
|
13143
13375
|
function registerUpdatePhaseCommand(cmd) {
|
|
13144
|
-
cmd.command("update-phase <id> <phase>").alias("edit-phase").description("Modify a plan phase on a backlog item").option("--name <name>", "New phase name").option("--task <task...>", "Replace tasks (repeatable)").option("--manual-check <check...>", "Replace manual checks (repeatable)").option("--add-task <text>", "Append one task (repeatable)",
|
|
13376
|
+
cmd.command("update-phase <id> <phase>").alias("edit-phase").description("Modify a plan phase on a backlog item").option("--name <name>", "New phase name").option("--task <task...>", "Replace tasks (repeatable)").option("--manual-check <check...>", "Replace manual checks (repeatable)").option("--add-task <text>", "Append one task (repeatable)", collect, []).option("--edit-task <n> <text...>", "Replace task n (1-based) in place").option("--remove-task <n>", "Remove task n (1-based)").option(
|
|
13145
13377
|
"--add-check <text>",
|
|
13146
13378
|
"Append one manual check (repeatable)",
|
|
13147
|
-
|
|
13379
|
+
collect,
|
|
13148
13380
|
[]
|
|
13149
13381
|
).option(
|
|
13150
13382
|
"--edit-check <n> <text...>",
|
|
@@ -13294,7 +13526,7 @@ async function update(id, options2) {
|
|
|
13294
13526
|
}
|
|
13295
13527
|
|
|
13296
13528
|
// src/commands/backlog/registerUpdateCommands.ts
|
|
13297
|
-
function
|
|
13529
|
+
function collect2(value, previous) {
|
|
13298
13530
|
return [...previous, value];
|
|
13299
13531
|
}
|
|
13300
13532
|
function registerUpdateCommands(cmd) {
|
|
@@ -13304,7 +13536,7 @@ function registerUpdateCommands(cmd) {
|
|
|
13304
13536
|
).option("--type <type>", "New type (story or bug)").option("--ac <criterion...>", "Replace acceptance criteria (repeatable)").option(
|
|
13305
13537
|
"--add-ac <text>",
|
|
13306
13538
|
"Append one acceptance criterion (repeatable)",
|
|
13307
|
-
|
|
13539
|
+
collect2,
|
|
13308
13540
|
[]
|
|
13309
13541
|
).option(
|
|
13310
13542
|
"--edit-ac <n> <text...>",
|
|
@@ -13489,9 +13721,9 @@ var UNPARSEABLE = { ok: false, error: "unable to parse" };
|
|
|
13489
13721
|
function groupByOperator(tokens) {
|
|
13490
13722
|
const groups = [[]];
|
|
13491
13723
|
for (let i = 0; i < tokens.length; i++) {
|
|
13492
|
-
const
|
|
13493
|
-
if (!
|
|
13494
|
-
i =
|
|
13724
|
+
const step2 = handleToken(tokens, i, groups);
|
|
13725
|
+
if (!step2.ok) return step2;
|
|
13726
|
+
i = step2.nextIndex;
|
|
13495
13727
|
}
|
|
13496
13728
|
return { ok: true, groups };
|
|
13497
13729
|
}
|
|
@@ -17924,16 +18156,16 @@ function* durabilityProbes() {
|
|
|
17924
18156
|
async function checkDurability(cwd) {
|
|
17925
18157
|
if (!existsSync44(cwd)) return { durable: true };
|
|
17926
18158
|
const probes = durabilityProbes();
|
|
17927
|
-
let
|
|
17928
|
-
while (!
|
|
17929
|
-
return
|
|
18159
|
+
let step2 = probes.next();
|
|
18160
|
+
while (!step2.done) step2 = probes.next(await gitResult(cwd, step2.value));
|
|
18161
|
+
return step2.value;
|
|
17930
18162
|
}
|
|
17931
18163
|
function checkDurabilitySync(cwd) {
|
|
17932
18164
|
if (!existsSync44(cwd)) return { durable: true };
|
|
17933
18165
|
const probes = durabilityProbes();
|
|
17934
|
-
let
|
|
17935
|
-
while (!
|
|
17936
|
-
return
|
|
18166
|
+
let step2 = probes.next();
|
|
18167
|
+
while (!step2.done) step2 = probes.next(gitSyncResult(cwd, step2.value));
|
|
18168
|
+
return step2.value;
|
|
17937
18169
|
}
|
|
17938
18170
|
|
|
17939
18171
|
// src/commands/sessions/daemon/worktree/worktreeConfigFor.ts
|
|
@@ -20178,7 +20410,7 @@ var prsConfigHelp = [
|
|
|
20178
20410
|
];
|
|
20179
20411
|
|
|
20180
20412
|
// src/commands/registerPrsEdit.ts
|
|
20181
|
-
function
|
|
20413
|
+
function collect3(value, previous) {
|
|
20182
20414
|
return previous.concat([value]);
|
|
20183
20415
|
}
|
|
20184
20416
|
function registerPrsEdit(prsCommand) {
|
|
@@ -20187,7 +20419,7 @@ function registerPrsEdit(prsCommand) {
|
|
|
20187
20419
|
).option("-t, --title <title>", "New title for the pull request").option("--what <what>", "Replace the ## What section").option("--why <why>", "Replace the ## Why section").option("--how <how>", "Replace the ## How section").option(
|
|
20188
20420
|
"--resolves <key>",
|
|
20189
20421
|
"Jira issue key resolved by this PR, appended to ## Why (repeatable)",
|
|
20190
|
-
|
|
20422
|
+
collect3,
|
|
20191
20423
|
[]
|
|
20192
20424
|
).action(edit);
|
|
20193
20425
|
}
|
|
@@ -20288,7 +20520,7 @@ ${confirm}
|
|
|
20288
20520
|
}
|
|
20289
20521
|
|
|
20290
20522
|
// src/commands/registerPrsRaise.ts
|
|
20291
|
-
function
|
|
20523
|
+
function collect4(value, previous) {
|
|
20292
20524
|
return previous.concat([value]);
|
|
20293
20525
|
}
|
|
20294
20526
|
function registerPrsRaise(prsCommand) {
|
|
@@ -20297,20 +20529,20 @@ function registerPrsRaise(prsCommand) {
|
|
|
20297
20529
|
).option("-t, --title <title>", "Title for the pull request").option("--what <what>", "What the change does (## What section)").option("--why <why>", "Why the change is needed (## Why section)").option("--how <how>", "How the change works (optional ## How section)").option(
|
|
20298
20530
|
"--resolves <key>",
|
|
20299
20531
|
"Jira issue key resolved by this PR, appended to ## Why (repeatable)",
|
|
20300
|
-
|
|
20532
|
+
collect4,
|
|
20301
20533
|
[]
|
|
20302
20534
|
).option(
|
|
20303
20535
|
"--force",
|
|
20304
20536
|
"Overwrite the title and body of an existing pull request"
|
|
20305
|
-
).option("-B, --base <branch>", "Branch into which the pull request merges").option("-H, --head <branch>", "Branch that contains the commits").option("-d, --draft", "Mark the pull request as a draft").option("-w, --web", "Open the browser to create the pull request").option("-l, --label <label>", "Add a label (repeatable)",
|
|
20537
|
+
).option("-B, --base <branch>", "Branch into which the pull request merges").option("-H, --head <branch>", "Branch that contains the commits").option("-d, --draft", "Mark the pull request as a draft").option("-w, --web", "Open the browser to create the pull request").option("-l, --label <label>", "Add a label (repeatable)", collect4, []).option(
|
|
20306
20538
|
"-a, --assignee <login>",
|
|
20307
20539
|
"Assign a person by login (repeatable)",
|
|
20308
|
-
|
|
20540
|
+
collect4,
|
|
20309
20541
|
[]
|
|
20310
20542
|
).option(
|
|
20311
20543
|
"-r, --reviewer <handle>",
|
|
20312
20544
|
"Request a review (repeatable)",
|
|
20313
|
-
|
|
20545
|
+
collect4,
|
|
20314
20546
|
[]
|
|
20315
20547
|
).option("-m, --milestone <name>", "Add the pull request to a milestone").addHelpText("after", () => raiseHelpText()).action(raise);
|
|
20316
20548
|
}
|