Expand description
Bash Tool Implementation
This module implements the BashTool for executing shell commands with:
- Cross-platform support (Windows PowerShell/CMD, macOS, Linux)
- Safety checks for dangerous commands
- Warning pattern detection
- Background task execution
- Configurable timeout
- Output truncation
Requirements: 3.1, 3.2, 3.3, 3.4, 3.5, 3.6, 3.7, 3.8, 3.9
Structs§
- Bash
Tool - Bash Tool for executing shell commands
- Safety
Check Result - Safety check result for command validation
- Sandbox
Config - Sandbox configuration for command execution
Constants§
- DEFAULT_
TIMEOUT_ SECS - Default timeout for command execution (5 minutes)
- MAX_
OUTPUT_ LENGTH - Maximum output length before truncation (128KB)
- MAX_
TIMEOUT_ SECS - Maximum timeout allowed (30 minutes)