tuna-agent 0.1.109 → 0.1.110

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.
@@ -227,6 +227,7 @@ export class ClaudeCodeAdapter {
227
227
  includePartialMessages: true,
228
228
  maxTurns: 200,
229
229
  resumeSessionId: round > 0 ? sessionId : undefined,
230
+ forkSession: round > 0 ? true : undefined,
230
231
  signal,
231
232
  inputFiles: currentInputFiles,
232
233
  agentTeam: useAgentTeam,
@@ -825,6 +825,7 @@ ${skillContent.slice(0, 15000)}`;
825
825
  includePartialMessages: true,
826
826
  agentTeam: true,
827
827
  dangerouslySkipPermissions: true,
828
+ forkSession: true,
828
829
  maxTurns: 200,
829
830
  resumeSessionId: sessionId,
830
831
  signal: abort.signal,
@@ -18,6 +18,8 @@ export interface ClaudeCliOptions {
18
18
  permissionMode?: 'default' | 'plan' | 'bypassPermissions';
19
19
  /** Use --dangerously-skip-permissions to fully bypass all permission checks */
20
20
  dangerouslySkipPermissions?: boolean;
21
+ /** Use --fork-session with --resume to create a new session with fresh permission mode */
22
+ forkSession?: boolean;
21
23
  /** Callback invoked when Claude Code asks for tool approval. Return true to allow, false to deny. */
22
24
  onPermissionRequest?: (tool: string, detail: string) => Promise<boolean>;
23
25
  /** Local file paths to pass as input (e.g., images) via --input-file flags */
@@ -118,6 +118,9 @@ export function runClaude(options) {
118
118
  }
119
119
  if (options.resumeSessionId) {
120
120
  args.push('--resume', options.resumeSessionId);
121
+ if (options.forkSession) {
122
+ args.push('--fork-session');
123
+ }
121
124
  }
122
125
  if (options.lightweight) {
123
126
  args.push('--strict-mcp-config'); // skip all MCP servers
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "tuna-agent",
3
- "version": "0.1.109",
3
+ "version": "0.1.110",
4
4
  "description": "Tuna Agent - Run AI coding tasks on your machine",
5
5
  "bin": {
6
6
  "tuna-agent": "dist/cli/index.js"