hive.terminal-tools-foundations
यह क्या करती है
यह स्किल बताती है कि AI आपके कंप्यूटर पर कमांड कैसे चलाता है, फ़ाइलें कैसे पढ़ता और बदलता है, और फ़ोल्डर कैसे खोजता है। यह उन लोगों के लिए है जो चाहते हैं कि उनका AI प्रोजेक्ट फ़ोल्डर में हाथ से काम करे।
कब इस्तेमाल करें
- ✓जब आपके AI को अपने कंप्यूटर पर कोई कमांड चलाना हो, जैसे build या test।
- ✓जब आप चाहते हैं कि AI प्रोजेक्ट में टेक्स्ट या फ़ाइल नाम खोजे।
- ✓जब किसी काम के लिए प्रोजेक्ट फ़ोल्डर में फ़ाइलें बदलनी हों।
Skill का लिंक
https://github.com/aden-hive/hive/blob/main/core/framework/skills/_preset_skills/terminal-tools-foundations/SKILL.mdइसे कॉपी करके अपने AI (Claude, ChatGPT या Cursor) में पेस्ट करें और निर्देशों का पालन करने को कहें।
कैसे इस्तेमाल करें
सबसे आसान तरीका: मैसेज कॉपी करके अपने AI में पेस्ट करें। वह skill पढ़कर निर्देशों का पालन करेगा।
पेस्ट करने के लिए तैयार मैसेज
Claude Code, Codex या Cursor के लिए: प्रोजेक्ट फ़ोल्डर में चलाएँ और skill इंस्टॉल हो जाएगी।
SKILL.md डाउनलोड करें और अपने एजेंट के skills फ़ोल्डर में रखें।
AI से क्या माँगें: उदाहरण
“मेरे प्रोजेक्ट फ़ोल्डर के टेस्ट चलाइए और बताइए कौन से टेस्ट विफल होते हैं।”
हर हफ़्ते 5 नई skills, 1 मिनट में पढ़ें।
यह कैसे काम करती है
AI आपके सिस्टम के अनुसार शेल में कमांड चलाता है, जैसे Git Bash या PowerShell, और नतीजा पढ़ता है। वह फ़ाइलें खोज सकता है और जिस फ़ोल्डर में काम कर रहा है उसमें बदलाव भी कर सकता है।
तकनीकी सामग्री (मूल SKILL.md)
लेखक का मूल टेक्स्ट, अंग्रेज़ी में, सीधे GitHub से।
terminal-tools — foundations
These tools provide command execution, background jobs, log streaming, filesystem search, and optional PTY sessions. POSIX uses bash for shell commands; Windows selects Git Bash, PowerShell, then cmd. Inspect shell_kind in results.
Tool preference (read first)
Use search_tools(query="inventory") before describing capabilities. It reports this session's loaded, searchable, disabled, and configured-but-unavailable tools. Load searchable tools by exact name. An absent schema alone does not prove a capability is missing; configuration does not prove credentials or connectivity work. Terminal tools and coding file tools default to the injected session workdir; an explicit absolute path overrides it.
- Reading files → use
read_filebeforeedit_filewhen the coding tools are enabled; it records file state for the stale-edit guard. Otherwise use a command appropriate toshell_kind. - Editing files → prefer
edit_filewhen enabled. Replacement mode requires a unique match unlessreplace_all=true; patch mode validates all operations before writing. Inspect its changed-file summary and diff. Re-read files after external changes. Terminal editing remains available when coding tools are disabled. - Writing files → heredoc:
terminal_exec("cat > PATH <<'EOF' ... EOF") - Searching →
terminal_rg(content / regex grep) andterminal_glob(find files by name) - Browser / web pages → call
browser_setup, read the browser skill, then runhive-browser <command> --jsonthroughterminal_exec. - Web search → check the inventory for
web_searchand load it if available; verify required credentials. Do not invent a callable tool name. - System operations (process exec, jobs, PTYs) → terminal-tools. This is its territory.
The standard envelope
Every spawn-style call (terminal_exec, the auto-promoted job state) returns this shape:
{
"exit_code": 0, // null when auto-backgrounded or pre-spawn error
"stdout": "...", // decoded, truncated to max_output_kb (default 256 KB)
"stderr": "...",
"stdout_truncated_bytes": 0, // > 0 means more is in output_handle
"stderr_truncated_bytes": 0,
"runtime_ms": 42,
"pid": 12345,
"output_handle": null, // "out_<hex>" when truncated — paginate with terminal_output_get
"timed_out": false,
"semantic_status": "ok", // "ok" | "signal" | "error" — read THIS, not just exit_code
"semantic_message": null, // e.g. "No matches found" for grep exit 1
"warning": null, // e.g. "may force-remove files" for rm -rf
"auto_backgrounded": false,
"job_id": null, // set when auto_backgrounded=true
"shell_kind": "bash" // interpreter that ran it: "bash" | "powershell" | "cmd" | "direct"
}
Auto-promotion (the core mental model)
The agent loop first waits up to five seconds for terminal_exec. A slower call returns a bg_* handle; redeem it with collect_result. The terminal's own promotion threshold defaults to 30 seconds. Past that threshold it transfers the process to its job manager and returns:
{ "auto_backgrounded": true, "exit_code": null, "job_id": "job_<hex>", ... }
When you see auto_backgrounded: true, pivot to polling. The job is still running:
terminal_job_logs(job_id, since_offset=0, wait_until_exit=true, wait_timeout_sec=30)
→ blocks server-side until the job exits or the timeout, returns logs + status
You're not failing — you're freed up to do other work while the long task runs.
collect_result does not redeem job_id: after collecting a promoted call, use terminal_job_logs until status is exited. Track separate stdout/stderr offsets; use terminal_job_manage(action="signal_term", job_id=...) to cancel. Poll waits are capped at 45 seconds and do not extend execution deadlines. Job retrieval/management ship with basic exec; explicit job creation and PTYs require the advanced category.
timeout_sec defaults to 60 seconds from command start, including time after promotion. Expiry terminates the owned process tree; final logs report timed_out=true. A deadline at or before promotion kills inline. Set timeout_sec=0 for unlimited execution with promotion enabled. To keep execution foreground, set auto_background_after_sec=0 and a finite timeout of at most 220 seconds (or less if the caller has a smaller b
अक्सर पूछे जाने वाले सवाल
Windows पर कौन सा शेल इस्तेमाल होता है?
यह पहले Git Bash चुनता है, फिर PowerShell, फिर cmd, और हर नतीजे में शेल का प्रकार देखता है।
क्या यह मेरे प्रोजेक्ट फ़ोल्डर के बाहर काम कर सकता है?
हाँ। स्पष्ट absolute path डिफ़ॉल्ट प्रोजेक्ट फ़ोल्डर की जगह ले लेता है।
क्या बदलने से पहले फ़ाइल जाँची जाती है?
हाँ। वह पहले फ़ाइल पढ़ता है, और edit चरण में जब तक अलग न कहा जाए, अनोखा मेल ज़रूरी होता है।
जानकारी
लेखक का मूल विवरण
Required when terminal_* tools are available. Explains foreground execution, outer collect_result handles, promoted job IDs and their retrieval/cancellation, deadlines, output retention, platform shell selection, and structured editing when enabled.
repo: aden-hive/hive
लोकप्रियता
- GitHub स्टार
- 11k
- रैंकिंग में स्थान
- #11812
- लाइसेंस
- Apache-2.0
- अपडेट की गई
- 2/11/2026
कमेंट
- …
इस repository की और skills
browser-edge-cases
11kयह आपके एजेंट को LinkedIn, X या भारी स्क्रिप्ट वाले पेजों जैसी जटिल साइटों पर विफल होने वाले ब्राउज़र ऑटोमेशन को ठीक करने में मदद करती है।
hive.browser-automation
11kयह आपके एजेंट को hive-browser टूल से और स्क्रीनशॉट व क्लिक के ज़रिए आपके अपने Chrome ब्राउज़र को नियंत्रित करना सिखाती है।
hive.colony-progress-tracker
11kयह आपके एजेंट को कार्य लेने और साझा डेटाबेस में अपने चरण व जाँच दर्ज करने में मदद करती है, ताकि काम चलते-चलते ट्रैक हो।
hive.context-preservation
11kयह आपके एजेंट को लंबे टूल नतीजों से ज़रूरी बातें नोट्स में सहेजने में मदद करती है, इससे पहले कि पुराने विवरण उसकी मेमोरी से हटें।
मिलती-जुलती skills
diffs
394kयह आपके एजेंट को बदलावों का असली diff बनाने देती है, जिसे व्यूअर लिंक या इमेज फ़ाइल के रूप में साझा किया जा सकता है, हाथ से लिखे सारांश के बजाय।
coding-agent
394kयह आपके एजेंट को बड़े कोडिंग काम Codex, Claude Code या OpenCode को बैकग्राउंड वर्कर के रूप में सौंपने, फिर उसकी प्रगति जांचने में मदद करती है।
gh-issues
394kयह आपके एजेंट को GitHub issues खोजने, उनमें से काम करने लायक चुनने, और सुधार के साथ pull requests खोलने में मदद करती है, जिसमें समीक्षा टिप्पणियों का फ़ॉलो-अप भी शामिल है।