@yanzc/claude-pro 0.4.5 → 0.4.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/package.json +1 -1
- package/src/ui/repl.js +6 -7
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@yanzc/claude-pro",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.6",
|
|
4
4
|
"description": "claude-pro: a self-implemented coding agent for Anthropic-compatible APIs or local Claude Code subscription login. Full access with no permission prompts; file edits are checkpointed and can be rewound.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"repository": {
|
package/src/ui/repl.js
CHANGED
|
@@ -17,7 +17,7 @@ import {
|
|
|
17
17
|
import { createRuntime } from '../runtime.js';
|
|
18
18
|
import { SessionStore, firstUserText } from '../session.js';
|
|
19
19
|
import { defaultEffort, effortSupported, effortToSend, quickQuery } from '../api.js';
|
|
20
|
-
import { CONFIG_DIR, VERSION, APP_NAME, INSTALL_DIR
|
|
20
|
+
import { CONFIG_DIR, VERSION, APP_NAME, INSTALL_DIR } from '../config.js';
|
|
21
21
|
import { readGatewayLogin } from '../gateway.js';
|
|
22
22
|
import { TOPIC_TITLE_SYSTEM, topicTitlePrompt } from '../prompts.js';
|
|
23
23
|
import { buildCommands } from '../commands.js';
|
|
@@ -463,14 +463,13 @@ export class App {
|
|
|
463
463
|
// In the process a restart started: take up the session where the one before it left it.
|
|
464
464
|
resumeAfterRestart(state, resumable) {
|
|
465
465
|
const cfg = this.config;
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
466
|
+
// The model and effort the session had, none chosen included: the remembered /model and /effort are shared by
|
|
467
|
+
// every window on this machine, and another one may have changed them since (an update restarts them all).
|
|
468
|
+
// A restart is not a choice either, so it leaves what is remembered as it is.
|
|
469
|
+
if ('modelOverride' in state) cfg.modelOverride = state.modelOverride || null;
|
|
470
|
+
if ('effortOverride' in state) cfg.effortOverride = state.effortOverride || null;
|
|
469
471
|
// The Effort tool's level holds for the request the restart continues, not for the user's next one.
|
|
470
472
|
if (state.effortBoost) { cfg.effortBoost = state.effortBoost; cfg.effortBoostKeepNext = Boolean(state.continueWith); }
|
|
471
|
-
// These were chosen with /model and /effort, which are kept for later sessions. One made by a version of
|
|
472
|
-
// the program that did not keep them yet is saved now.
|
|
473
|
-
try { rememberChoice(cfg.provider, kept); } catch { /* it still holds for this session */ }
|
|
474
473
|
if (state.mode === 'plan') this.runtime.modes.setMode('plan');
|
|
475
474
|
this.restarts = (Array.isArray(state.restarts) ? state.restarts : []).filter((t) => Number.isFinite(t));
|
|
476
475
|
if (resumable) {
|