feat: Let agent level variables be defined to bypass guard protections for tool invocations

This commit is contained in:
2026-02-09 16:45:11 -07:00
parent b11797ea1c
commit 07f23bab5e
+2 -2
View File
@@ -507,7 +507,7 @@ open_link() {
guard_operation() {
if [[ -t 1 ]]; then
if [[ -z "$AUTO_CONFIRM" ]]; then
if [[ -z "$AUTO_CONFIRM" && -z "$LLM_AGENT_VAR_AUTO_CONFIRM" ]]; then
ans="$(confirm "${1:-Are you sure you want to continue?}")"
if [[ "$ans" == 0 ]]; then
@@ -659,7 +659,7 @@ guard_path() {
path="$(_to_real_path "$1")"
confirmation_prompt="$2"
if [[ ! "$path" == "$(pwd)"* && -z "$AUTO_CONFIRM" ]]; then
if [[ ! "$path" == "$(pwd)"* && -z "$AUTO_CONFIRM" && -z "$LLM_AGENT_VAR_AUTO_CONFIRM" ]]; then
ans="$(confirm "$confirmation_prompt")"
if [[ "$ans" == 0 ]]; then