Preapprove agent tmp directory access (#25226)

This commit is contained in:
Dax
2026-04-30 23:47:15 -04:00
committed by GitHub
parent 7e72610ed0
commit 416952c089
4 changed files with 14 additions and 1 deletions
+2
View File
@@ -14,6 +14,7 @@ import { AppFileSystem } from "@opencode-ai/core/filesystem"
import { fileURLToPath } from "url"
import { Config } from "@/config/config"
import { Flag } from "@opencode-ai/core/flag/flag"
import { Global } from "@opencode-ai/core/global"
import { Shell } from "@/shell/shell"
import { BashArity } from "@/permission/arity"
@@ -587,6 +588,7 @@ export const BashTool = Tool.define(
return {
description: DESCRIPTION.replaceAll("${directory}", instance.directory)
.replaceAll("${tmp}", Global.Path.tmp)
.replaceAll("${os}", process.platform)
.replaceAll("${shell}", name)
.replaceAll("${chaining}", chain)