@eliya-oss/agent-diff 0.1.0-alpha.93 → 0.1.0-alpha.95

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.
Files changed (3) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/dist/main.js +222 -45
  3. package/package.json +1 -1
package/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # @eliya-oss/agent-diff
2
2
 
3
+ ## 0.1.0-alpha.95
4
+
5
+ ### Minor Changes
6
+
7
+ - adiff keeps preferences between sessions: wrapping, the sticky heading, the review panel, hiding files already reviewed, hiding settled threads, and the order the review reads in. `adiff config list`, `config get` and `config set` read and write them, and the review remembers a toggle made with a key.
8
+
9
+ ## 0.1.0-alpha.94
10
+
11
+ ### Patch Changes
12
+
13
+ - The worktrees are read together rather than one after another, taking about 290ms off opening a review on a machine holding thirteen of them.
14
+
3
15
  ## 0.1.0-alpha.93
4
16
 
5
17
  ### Patch Changes
package/dist/main.js CHANGED
@@ -8215,7 +8215,7 @@ var init_dist = __esmMin((() => {
8215
8215
  init_SubscriptionRef();
8216
8216
  init_Utils();
8217
8217
  })), lineOn;
8218
- var init_model$4 = __esmMin((() => {
8218
+ var init_model$5 = __esmMin((() => {
8219
8219
  init_dist();
8220
8220
  String$1.pipe(brand("@adiff/Blob"));
8221
8221
  String$1.pipe(brand("@adiff/FilePath"));
@@ -8226,7 +8226,7 @@ var init_model$4 = __esmMin((() => {
8226
8226
  var sideOf, linesOn, anchorFor;
8227
8227
  var init_anchor = __esmMin((() => {
8228
8228
  init_dist();
8229
- init_model$4();
8229
+ init_model$5();
8230
8230
  sideOf = (rows) => rows.some((row) => isSome(row.newLine)) ? "new" : "old";
8231
8231
  linesOn = (rows, side) => rows.flatMap((row) => match$3(lineOn(row, side), {
8232
8232
  onNone: () => [],
@@ -8345,7 +8345,7 @@ var init_parse$1 = __esmMin((() => {
8345
8345
  //#endregion
8346
8346
  //#region src/domain/patch/render.ts
8347
8347
  var init_render$1 = __esmMin((() => {
8348
- init_model$4();
8348
+ init_model$5();
8349
8349
  }));
8350
8350
  //#endregion
8351
8351
  //#region src/domain/patch/sticky.ts
@@ -8390,7 +8390,7 @@ var init_patch = __esmMin((() => {
8390
8390
  init_parse$1();
8391
8391
  init_render$1();
8392
8392
  init_sticky();
8393
- init_model$4();
8393
+ init_model$5();
8394
8394
  })), GitCommandFailed, FileUnreadable;
8395
8395
  var init_error$3 = __esmMin((() => {
8396
8396
  init_dist();
@@ -8426,12 +8426,13 @@ var init_run = __esmMin((() => {
8426
8426
  }));
8427
8427
  //#endregion
8428
8428
  //#region src/service/git/service.ts
8429
- var GREP_CONTEXT, DEFAULT_BRANCH_CANDIDATES, STAT, Git, parseStat, readEntries, baseNames, mergeBases, findDefaultBranch, defaultBranch, mergeBaseOf, toWorktree, branchTips, parents, parentOf, splitLines, absent, readText, settled, listWorktrees, readDiff, readStat, readSource, readBlob, readGrep, shape, GitLive;
8429
+ var GREP_CONTEXT, AT_ONCE$1, DEFAULT_BRANCH_CANDIDATES, STAT, Git, parseStat, readEntries, baseNames, mergeBases, findDefaultBranch, defaultBranch, mergeBaseOf, toWorktree, branchTips, parents, parentOf, splitLines, absent, readText, settled, seenAs, listWorktrees, readDiff, readStat, readSource, readBlob, readGrep, shape, GitLive;
8430
8430
  var init_service$2 = __esmMin((() => {
8431
8431
  init_dist();
8432
8432
  init_error$3();
8433
8433
  init_run();
8434
8434
  GREP_CONTEXT = 2;
8435
+ AT_ONCE$1 = 8;
8435
8436
  DEFAULT_BRANCH_CANDIDATES = [
8436
8437
  "origin/master",
8437
8438
  "origin/main",
@@ -8549,6 +8550,10 @@ var init_service$2 = __esmMin((() => {
8549
8550
  }).pipe(map(some), catchTag("FileUnreadable", () => absent));
8550
8551
  });
8551
8552
  settled = (path) => promise(() => realpath(path).catch(() => resolve(path)));
8553
+ seenAs = fn("Git.seenAs")(function* (entry, base, opened) {
8554
+ const path = yield* settled(entry.path);
8555
+ return yield* toWorktree(entry, base, path === opened);
8556
+ });
8552
8557
  listWorktrees = fn("Git.worktrees")(function* (repo) {
8553
8558
  const porcelain = yield* gitOrEmpty(repo, [
8554
8559
  "worktree",
@@ -8558,12 +8563,8 @@ var init_service$2 = __esmMin((() => {
8558
8563
  const base = yield* defaultBranch(repo);
8559
8564
  const entries = readEntries(porcelain);
8560
8565
  const opened = yield* settled(repo);
8561
- const found = [];
8562
- for (const entry of entries) {
8563
- const path = yield* settled(entry.path);
8564
- found.push(yield* toWorktree(entry, base, path === opened));
8565
- }
8566
- return found;
8566
+ const read = (entry) => seenAs(entry, base, opened);
8567
+ return yield* forEach(entries, read, { concurrency: AT_ONCE$1 });
8567
8568
  });
8568
8569
  readDiff = fn("Git.diff")(function* (worktree, context, only) {
8569
8570
  const target = worktree.base.length > 0 ? worktree.base : "HEAD";
@@ -8662,7 +8663,7 @@ var init_vouch = __esmMin((() => {
8662
8663
  };
8663
8664
  };
8664
8665
  }));
8665
- var init_model$3 = __esmMin((() => {
8666
+ var init_model$4 = __esmMin((() => {
8666
8667
  init_dist();
8667
8668
  String$1.pipe(brand("@adiff/CommentId"));
8668
8669
  }));
@@ -8671,7 +8672,7 @@ var init_model$3 = __esmMin((() => {
8671
8672
  var init_review = __esmMin((() => {
8672
8673
  init_dist();
8673
8674
  init_vouch();
8674
- init_model$3();
8675
+ init_model$4();
8675
8676
  }));
8676
8677
  //#endregion
8677
8678
  //#region src/service/store/error.ts
@@ -8684,7 +8685,7 @@ var init_error$2 = __esmMin((() => {
8684
8685
  //#endregion
8685
8686
  //#region src/service/store/model.ts
8686
8687
  var emptyBranchState;
8687
- var init_model$2 = __esmMin((() => {
8688
+ var init_model$3 = __esmMin((() => {
8688
8689
  emptyBranchState = {
8689
8690
  vouches: {},
8690
8691
  consumed: 0,
@@ -8737,7 +8738,12 @@ var init_schema = __esmMin((() => {
8737
8738
  });
8738
8739
  Settings = Struct({
8739
8740
  wrap: optionalKey(Boolean),
8740
- sticky: optionalKey(Boolean)
8741
+ sticky: optionalKey(Boolean),
8742
+ panel: optionalKey(Boolean),
8743
+ hideReviewed: optionalKey(Boolean),
8744
+ hideSettled: optionalKey(Boolean),
8745
+ newestFirst: optionalKey(Boolean),
8746
+ hold: optionalKey(Boolean)
8741
8747
  });
8742
8748
  UpgradeCheck = Struct({
8743
8749
  note: optionalKey(String$1),
@@ -8789,7 +8795,7 @@ var init_paths = __esmMin((() => {
8789
8795
  var init_service$1 = __esmMin((() => {
8790
8796
  init_dist();
8791
8797
  init_error$2();
8792
- init_model$2();
8798
+ init_model$3();
8793
8799
  init_schema();
8794
8800
  init_paths();
8795
8801
  Store = class extends Service()("adiff/Store") {};
@@ -9089,17 +9095,69 @@ var init_store = __esmMin((() => {
9089
9095
  init_service$1();
9090
9096
  init_error$2();
9091
9097
  init_paths();
9098
+ init_model$3();
9099
+ }));
9100
+ //#endregion
9101
+ //#region src/domain/preferences/model.ts
9102
+ var preferences, preferenceNames, preferenceNamed, heldValue, heldValues;
9103
+ var init_model$2 = __esmMin((() => {
9104
+ preferences = [
9105
+ {
9106
+ name: "wrap",
9107
+ about: "Wrap long lines instead of cutting them at the edge",
9108
+ byDefault: false
9109
+ },
9110
+ {
9111
+ name: "sticky",
9112
+ about: "Keep the heading of what you are reading in view while you scroll",
9113
+ byDefault: true
9114
+ },
9115
+ {
9116
+ name: "panel",
9117
+ about: "Show the review panel beside the diff",
9118
+ byDefault: true
9119
+ },
9120
+ {
9121
+ name: "hideReviewed",
9122
+ about: "Leave files you have marked reviewed out of the file list",
9123
+ byDefault: false
9124
+ },
9125
+ {
9126
+ name: "hideSettled",
9127
+ about: "Leave threads you have settled out of the review panel",
9128
+ byDefault: false
9129
+ },
9130
+ {
9131
+ name: "newestFirst",
9132
+ about: "Read the review newest first, rather than oldest first",
9133
+ byDefault: true
9134
+ },
9135
+ {
9136
+ name: "hold",
9137
+ about: "Hold comments until you send them together, rather than sending each as it is written",
9138
+ byDefault: false
9139
+ }
9140
+ ];
9141
+ preferenceNames = preferences.map((one) => one.name);
9142
+ preferenceNamed = (name) => preferences.find((one) => one.name === name);
9143
+ heldValue = (kept, name) => kept[name] ?? preferenceNamed(name)?.byDefault ?? false;
9144
+ heldValues = (kept) => Object.fromEntries(preferences.map((one) => [one.name, heldValue(kept, one.name)]));
9145
+ }));
9146
+ //#endregion
9147
+ //#region src/domain/preferences/index.ts
9148
+ var init_preferences = __esmMin((() => {
9092
9149
  init_model$2();
9093
9150
  }));
9094
9151
  //#endregion
9095
9152
  //#region src/cli/error.ts
9096
- var UnknownBranch, UnknownBase, UnknownFile, UnknownComment, UnselectableRange, UnknownCommand, MissingOption, UnknownWorktree, MalformedLayers, NoLayers, InitUnwritable;
9153
+ var UnknownBranch, UnknownBase, UnknownFile, UnknownComment, UnknownPreference, UnselectableRange, UnknownCommand, MissingOption, UnknownWorktree, MalformedLayers, NoLayers, InitUnwritable;
9097
9154
  var init_error$1 = __esmMin((() => {
9098
9155
  init_dist();
9099
9156
  UnknownBranch = class extends TaggedError("UnknownBranch") {};
9100
9157
  UnknownBase = class extends TaggedError("UnknownBase") {};
9101
9158
  UnknownFile = class extends TaggedError("UnknownFile") {};
9102
9159
  UnknownComment = class extends TaggedError("UnknownComment") {};
9160
+ UnknownPreference = class extends TaggedError("UnknownPreference") {};
9103
9161
  UnselectableRange = class extends TaggedError("UnselectableRange") {};
9104
9162
  UnknownCommand = class extends TaggedError("UnknownCommand") {};
9105
9163
  MissingOption = class extends TaggedError("MissingOption") {};
@@ -9107,16 +9165,14 @@ var init_error$1 = __esmMin((() => {
9107
9165
  MalformedLayers = class extends TaggedError("MalformedLayers") {};
9108
9166
  NoLayers = class extends TaggedError("NoLayers") {};
9109
9167
  InitUnwritable = class extends TaggedError("InitUnwritable") {};
9110
- }));
9111
- //#endregion
9112
- //#region src/cli/commands.ts
9113
- var CONTEXT, WHOLE_FILE$1, POLL, AUTO, askedFor, basedOn, worktreeNamed, findBranch, baseFor, patchesOf, findPatch, rowsCovering, waitingOn, AT_ONCE, summaryOf, summaryFor, listBranches, blobOf, vouchIn, toggleVouch, readingOf, progressIn, reviewProgress, bodyOf, saidTo, spunOf, sentOf, sentIn, listSent, commentIn, submitComment, without$1, submitReply, listPatches, patchIn, flatten, threadBefore, takeComments, repoOf$1, worktreeOf$1, branchAt, awaitComments, saveReport, fileSource, fileBefore, saveWrap, saveSticky, setBase, clearBase, markRead;
9168
+ })), CONTEXT, WHOLE_FILE$1, POLL, AUTO, askedFor, basedOn, worktreeNamed, findBranch, baseFor, patchesOf, findPatch, rowsCovering, waitingOn, AT_ONCE, summaryOf, summaryFor, listBranches, blobOf, vouchIn, toggleVouch, readingOf, progressIn, reviewProgress, bodyOf, saidTo, spunOf, sentOf, sentIn, listSent, commentIn, submitComment, without$1, submitReply, listPatches, patchIn, flatten, threadBefore, takeComments, repoOf$1, worktreeOf$1, branchAt, awaitComments, saveReport, fileSource, fileBefore, readPreferences, readPreference, savePreference, setBase, clearBase, markRead;
9114
9169
  var init_commands = __esmMin((() => {
9115
9170
  init_dist();
9116
9171
  init_patch();
9117
9172
  init_git();
9118
9173
  init_review();
9119
9174
  init_store();
9175
+ init_preferences();
9120
9176
  init_error$1();
9121
9177
  CONTEXT = 3;
9122
9178
  WHOLE_FILE$1 = 1e5;
@@ -9490,7 +9546,49 @@ var init_commands = __esmMin((() => {
9490
9546
  const found = yield* git.blob(worktree, file);
9491
9547
  return getOrElse(found, () => []);
9492
9548
  });
9493
- saveWrap = fn("Cli.saveWrap")(function* (wrap) {
9549
+ readPreferences = fn("Cli.readPreferences")(function* () {
9550
+ const kept = yield* (yield* Store).settings;
9551
+ return preferences.map((one) => ({
9552
+ name: one.name,
9553
+ about: one.about,
9554
+ value: heldValue(kept, one.name),
9555
+ byDefault: one.byDefault
9556
+ }));
9557
+ });
9558
+ readPreference = fn("Cli.readPreference")(function* (name) {
9559
+ const known = preferenceNamed(name);
9560
+ if (known === void 0) return yield* new UnknownPreference({
9561
+ name,
9562
+ known: preferenceNames
9563
+ });
9564
+ const kept = yield* (yield* Store).settings;
9565
+ return {
9566
+ name,
9567
+ about: known.about,
9568
+ value: heldValue(kept, name),
9569
+ byDefault: known.byDefault
9570
+ };
9571
+ });
9572
+ savePreference = fn("Cli.savePreference")(function* (name, value) {
9573
+ const known = preferenceNamed(name);
9574
+ if (known === void 0) return yield* new UnknownPreference({
9575
+ name,
9576
+ known: preferenceNames
9577
+ });
9578
+ const store = yield* Store;
9579
+ const current = yield* store.settings;
9580
+ yield* store.saveSettings({
9581
+ ...current,
9582
+ [name]: value
9583
+ });
9584
+ return {
9585
+ name,
9586
+ about: known.about,
9587
+ value,
9588
+ byDefault: known.byDefault
9589
+ };
9590
+ });
9591
+ fn("Cli.saveWrap")(function* (wrap) {
9494
9592
  const store = yield* Store;
9495
9593
  const current = yield* store.settings;
9496
9594
  yield* store.saveSettings({
@@ -9498,7 +9596,7 @@ var init_commands = __esmMin((() => {
9498
9596
  wrap
9499
9597
  });
9500
9598
  });
9501
- saveSticky = fn("Cli.saveSticky")(function* (sticky) {
9599
+ fn("Cli.saveSticky")(function* (sticky) {
9502
9600
  const store = yield* Store;
9503
9601
  const current = yield* store.settings;
9504
9602
  yield* store.saveSettings({
@@ -9815,7 +9913,7 @@ var init_pane = __esmMin((() => {
9815
9913
  init_commands();
9816
9914
  init_init();
9817
9915
  init_pane();
9818
- var version$1 = "0.1.0-alpha.93";
9916
+ var version$1 = "0.1.0-alpha.95";
9819
9917
  //#endregion
9820
9918
  //#region src/cli/upgrade.ts
9821
9919
  var PACKAGE, TAG, RELEASES, REGISTRY, ASK_MS, RUN_MS, CELLAR, COMPILED, INSTALLED, BUN_GLOBAL, routeOf, ROUTES, asRoute, checkoutOf, assetOf, commandFor, NOTES, RUNNABLE, NUMBERS, numbersIn, compare$1, partsOf, newer, tagIn, fetched, askLatest, here, findUpgrade, willUpgrade, runUpgrade, statusOf$1, sayFound, sayDone, attempted, REFRESH_MS, refreshSkills, updatedIn, sayRefreshed, upgradeReport;
@@ -10907,6 +11005,51 @@ var init_catalog = __esmMin((() => {
10907
11005
  dataKey: "restored",
10908
11006
  example: "adiff comment restore --repo . --branch cdr-1 --id c1"
10909
11007
  },
11008
+ {
11009
+ name: "config list",
11010
+ about: "Every preference adiff keeps, with its value and what it does",
11011
+ group: SET_UP,
11012
+ addresses: "none",
11013
+ safety: "read",
11014
+ options: [],
11015
+ dataKey: "preferences",
11016
+ example: "adiff config list"
11017
+ },
11018
+ {
11019
+ name: "config get",
11020
+ about: "What one preference is set to",
11021
+ group: SET_UP,
11022
+ addresses: "none",
11023
+ safety: "read",
11024
+ options: [{
11025
+ name: "name",
11026
+ required: true,
11027
+ value: "name",
11028
+ about: "The preference, as `config list` names it"
11029
+ }],
11030
+ dataKey: "preference",
11031
+ example: "adiff config get --name sticky"
11032
+ },
11033
+ {
11034
+ name: "config set",
11035
+ about: "Turn one preference on or off, for every repository on this machine",
11036
+ group: SET_UP,
11037
+ addresses: "none",
11038
+ safety: "write",
11039
+ options: [{
11040
+ name: "name",
11041
+ required: true,
11042
+ value: "name",
11043
+ about: "The preference, as `config list` names it"
11044
+ }, {
11045
+ name: "value",
11046
+ required: true,
11047
+ value: "on|off",
11048
+ about: "What to set it to"
11049
+ }],
11050
+ dataKey: "preference",
11051
+ example: "adiff config set --name hold --value on"
11052
+ },
10910
11053
  {
10911
11054
  name: "init",
10912
11055
  about: "Write the review loop into this repository's agent instructions, so an agent finds it unprompted",
@@ -11041,6 +11184,11 @@ var init_report$1 = __esmMin((() => {
11041
11184
  suggestion: "The error lists the files this branch changed. Use one of those paths.",
11042
11185
  retriable: false
11043
11186
  },
11187
+ UnknownPreference: {
11188
+ exit: 3,
11189
+ suggestion: "The error lists the preferences adiff knows. Run `adiff config list` to see them with their values.",
11190
+ retriable: false
11191
+ },
11044
11192
  UnknownWorktree: {
11045
11193
  exit: 3,
11046
11194
  suggestion: "--worktree takes the path of a worktree of the repository under review. The error lists the ones that exist; pass one of those, or run the command from inside it with `--worktree .`.",
@@ -11618,6 +11766,7 @@ var init_model = __esmMin((() => {
11618
11766
  hideSettled: false,
11619
11767
  picked: void 0,
11620
11768
  newestFirst: true,
11769
+ hold: false,
11621
11770
  tallest: 0,
11622
11771
  scroll: -1,
11623
11772
  railRows: 12,
@@ -15848,12 +15997,13 @@ var init_upgrade = __esmMin((() => {
15848
15997
  return due ? `adiff ${latest} is out · adiff upgrade` : "";
15849
15998
  }).pipe(withSpan("Tui.upgradeHint"));
15850
15999
  upgradeHint = worded.pipe(orElseSucceed(() => ""));
15851
- })), KEY_HISTORY, DRAIN_PASSES, TRAIL_HISTORY, clockOf, momentOf, noticeOf, COPIERS, wayland, handOver, throughMultiplexer, copyToClipboard, lineUnder, asKey, openedPull, LISTENS, WRITES, writesInto, listens, laidOut, ARROWS, keyName, App, turnedOver, settledPath, settingsHeld, firstBranches, missing, openingOn, launch, told, untilDestroyed, runOn, runTui;
16000
+ })), KEY_HISTORY, DRAIN_PASSES, TRAIL_HISTORY, clockOf, momentOf, noticeOf, COPIERS, wayland, handOver, throughMultiplexer, copyToClipboard, lineUnder, asKey, openedPull, LISTENS, WRITES, writesInto, listens, laidOut, ARROWS, keyName, App, turnedOver, settledPath, chosenIn, settingsHeld, firstBranches, missing, openingOn, launch, told, untilDestroyed, runOn, runTui;
15852
16001
  var init_app = __esmMin((() => {
15853
16002
  init_dist();
15854
16003
  init_report();
15855
16004
  init_patch();
15856
16005
  init_cli();
16006
+ init_preferences();
15857
16007
  init_store();
15858
16008
  init_watch();
15859
16009
  init_forge();
@@ -15962,8 +16112,7 @@ var init_app = __esmMin((() => {
15962
16112
  roomed = 0;
15963
16113
  sessionPath;
15964
16114
  remembered = "";
15965
- wrapKept = false;
15966
- stickyKept = true;
16115
+ chosen = {};
15967
16116
  grewWithShift = false;
15968
16117
  keys = [];
15969
16118
  trail = [];
@@ -15978,8 +16127,10 @@ var init_app = __esmMin((() => {
15978
16127
  this.repo = options.repo;
15979
16128
  this.noticeMs = options.noticeMs ?? 2200;
15980
16129
  this.sessionPath = options.sessionPath;
15981
- this.wrapKept = options.wrap === true;
15982
- this.stickyKept = options.sticky !== false;
16130
+ Object.assign(this.chosen, chosenIn({
16131
+ ...initialState([]),
16132
+ ...options.chosen
16133
+ }));
15983
16134
  this.held = options.state;
15984
16135
  this.display = options.display;
15985
16136
  this.painting = options.painting;
@@ -16080,15 +16231,12 @@ var init_app = __esmMin((() => {
16080
16231
  yield* this.loadSource();
16081
16232
  });
16082
16233
  }
16083
- rememberWrap(next) {
16084
- if (next.wrap === this.wrapKept) return;
16085
- this.wrapKept = next.wrap;
16086
- this.dispatchTask(asVoid(saveWrap(next.wrap)));
16087
- }
16088
- rememberSticky(next) {
16089
- if (next.sticky === this.stickyKept) return;
16090
- this.stickyKept = next.sticky;
16091
- this.dispatchTask(asVoid(saveSticky(next.sticky)));
16234
+ rememberChosen(next) {
16235
+ for (const [name, value] of Object.entries(chosenIn(next))) {
16236
+ if (this.chosen[name] === value) continue;
16237
+ this.chosen[name] = value;
16238
+ this.dispatchTask(savePreference(name, value).pipe(asVoid, orElseSucceed(() => void 0)));
16239
+ }
16092
16240
  }
16093
16241
  rememberPlace(next) {
16094
16242
  if (this.sessionPath === void 0 || next.screen !== "review") return;
@@ -16228,8 +16376,7 @@ var init_app = __esmMin((() => {
16228
16376
  const appeared = next.notice.length > 0 && next.notice !== this.state.notice;
16229
16377
  if (appeared) this.recordNotice(next.notice);
16230
16378
  this.rememberPlace(next);
16231
- this.rememberWrap(next);
16232
- this.rememberSticky(next);
16379
+ this.rememberChosen(next);
16233
16380
  this.write(next);
16234
16381
  if (appeared) this.fade();
16235
16382
  }
@@ -16929,11 +17076,27 @@ var init_app = __esmMin((() => {
16929
17076
  anchorRow: state.cursor
16930
17077
  });
16931
17078
  settledPath = (path) => promise(() => realpath(path).catch(() => resolve(path)));
17079
+ chosenIn = (state) => ({
17080
+ wrap: state.wrap,
17081
+ sticky: state.sticky,
17082
+ panel: state.panelOpen,
17083
+ hideReviewed: state.hideReviewed,
17084
+ hideSettled: state.hideSettled,
17085
+ newestFirst: state.newestFirst,
17086
+ hold: state.hold
17087
+ });
16932
17088
  settingsHeld = gen(function* () {
16933
- const settings = yield* (yield* Store).settings;
17089
+ const store = yield* Store;
17090
+ const kept = heldValues(yield* store.settings);
16934
17091
  return {
16935
- wrap: settings.wrap === true,
16936
- sticky: settings.sticky !== false
17092
+ wrap: kept["wrap"] === true,
17093
+ sticky: kept["sticky"] === true,
17094
+ panelOpen: kept["panel"] === true,
17095
+ panelWas: kept["panel"] === true,
17096
+ hideReviewed: kept["hideReviewed"] === true,
17097
+ hideSettled: kept["hideSettled"] === true,
17098
+ newestFirst: kept["newestFirst"] === true,
17099
+ hold: kept["hold"] === true
16937
17100
  };
16938
17101
  });
16939
17102
  firstBranches = fn("Tui.firstBranches")(function* (repo, branch) {
@@ -16977,8 +17140,7 @@ var init_app = __esmMin((() => {
16977
17140
  sessionPath,
16978
17141
  resume: getOrUndefined$1(resume),
16979
17142
  opensOn: getOrUndefined$1(asOpened),
16980
- wrap: kept.wrap,
16981
- sticky: kept.sticky,
17143
+ chosen: kept,
16982
17144
  partial,
16983
17145
  intents
16984
17146
  });
@@ -17180,6 +17342,18 @@ const skillRefresh = fn("Main.skillRefresh")(function* (options) {
17180
17342
  const report = yield* refreshSkill([process.cwd(), homedir()]);
17181
17343
  yield* answer(options, { changes: report.changes });
17182
17344
  });
17345
+ const configList = fn("Main.configList")(function* (options) {
17346
+ yield* answer(options, { preferences: yield* readPreferences() });
17347
+ });
17348
+ const configGet = fn("Main.configGet")(function* (options) {
17349
+ const preference = yield* readPreference(yield* required(options, "name"));
17350
+ yield* answer(options, { preference });
17351
+ });
17352
+ const configSet = fn("Main.configSet")(function* (options) {
17353
+ const wanted = yield* required(options, "value");
17354
+ const preference = yield* savePreference(yield* required(options, "name"), wanted === "on");
17355
+ yield* answer(options, { preference });
17356
+ });
17183
17357
  const reviewPane = fn("Main.reviewPane")(function* (options) {
17184
17358
  const report = yield* openPane(yield* required(options, "repo"), options["branch"]);
17185
17359
  yield* answer(options, {
@@ -17210,6 +17384,9 @@ const routes = {
17210
17384
  "comment resolve": commentResolve,
17211
17385
  "comment remove": commentRemove,
17212
17386
  "comment restore": commentRestore,
17387
+ "config list": configList,
17388
+ "config get": configGet,
17389
+ "config set": configSet,
17213
17390
  "review pane": reviewPane,
17214
17391
  "review progress": reviewStatus,
17215
17392
  "layers set": layersSet,
package/package.json CHANGED
@@ -23,7 +23,7 @@
23
23
  "bin": {
24
24
  "adiff": "./bin/adiff.js"
25
25
  },
26
- "version": "0.1.0-alpha.93",
26
+ "version": "0.1.0-alpha.95",
27
27
  "description": "Review the work an agent left you without losing the thread: comments live on the lines, the agent answers them, and each point stays open until you settle it.",
28
28
  "license": "MIT",
29
29
  "repository": {