mirror of
https://github.com/Ark0N/Codeman.git
synced 2026-10-06 15:39:41 +02:00
fix: respect Claude CLI startup mode setting (#12)
The "Startup Mode" setting (normal/bypass/allowedTools) was saved to settings but never read when spawning sessions. All code paths had --dangerously-skip-permissions hardcoded. Now reads claudeMode from ~/.claudeman/settings.json and passes it through Session → TmuxManager. Closes #12 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
*/
|
||||
|
||||
import type { EventEmitter } from 'node:events';
|
||||
import type { ProcessStats, PersistedRespawnConfig, NiceConfig } from './types.js';
|
||||
import type { ProcessStats, PersistedRespawnConfig, NiceConfig, ClaudeMode } from './types.js';
|
||||
|
||||
/**
|
||||
* Multiplexer session metadata.
|
||||
@@ -71,6 +71,8 @@ export interface TerminalMultiplexer extends EventEmitter {
|
||||
name?: string,
|
||||
niceConfig?: NiceConfig,
|
||||
model?: string,
|
||||
claudeMode?: ClaudeMode,
|
||||
allowedTools?: string,
|
||||
): Promise<MuxSession>;
|
||||
|
||||
/**
|
||||
@@ -163,5 +165,5 @@ export interface TerminalMultiplexer extends EventEmitter {
|
||||
isPaneDead(muxName: string): boolean;
|
||||
|
||||
/** Respawn a dead pane with a fresh command. Returns the new PID or null on failure. */
|
||||
respawnPane(sessionId: string, workingDir: string, mode: 'claude' | 'shell', niceConfig?: NiceConfig, model?: string): Promise<number | null>;
|
||||
respawnPane(sessionId: string, workingDir: string, mode: 'claude' | 'shell', niceConfig?: NiceConfig, model?: string, claudeMode?: ClaudeMode, allowedTools?: string): Promise<number | null>;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user