Text Search

👤 jinwangmok 📦 v1.0.0 ⭐ 4.4 ⬇️ 610 下載
💻 開發程式設計 免費

📖 技能介紹


name: text-search version: 1.0.0 description: >- Search for a text pattern in files within a directory. Shows matching lines with filenames and line numbers. Use when the user wants to find where a word or phrase appears in their files. allowed-tools: Bash(grep:*) metadata: >- {"openclaw":{"emoji":"🔍","requires":{"bins":["grep"],"env":[]},"install":[]}}


Text Search

本技能來自小蔥技能站7w4.net。

Find a word or phrase in files within a directory with a single command.

Usage

grep -rn <PATTERN> <DIR_PATH>

Arguments: | # | Name | Description | |---|------|-------------| | 1 | PATTERN | Text or pattern to search for | | 2 | DIR_PATH | Directory to search in |

Example

grep -rn "TODO" /home/user/project

Output:

/home/user/project/main.py:12:# TODO: fix this
/home/user/project/utils.py:5:# TODO: add tests

Format: FILENAME:LINE_NUMBER:MATCHING_LINE

Success / Failure

  • Success: Matching lines printed (exit code 0)
  • No matches: No output (exit code 1 — this is normal, not an error)
  • Failure: Error message (exit code 2, e.g. directory not found)

🤖 AI 評測

這個文本搜尋工具質量不錯,能快速在目錄中找到指定的文字內容,結果展示清晰(檔名和行號一目瞭然)。介面簡單直觀,中英雙語說明讓上手更容易。不足之處是功能比較基礎,沒有大小寫不敏感、排除某些檔案等靈活選項。如果只是簡單的搜尋需求用它很順手,想要更高階的搜尋能力可能需要功能更豐富的替代品。整體屬於中上質量的小工具。

📊 多維度評分

適應性4.5
規範性4.3
有效性4.4
可靠性4.2
可信度4.8

📁 包含檔案 (4 個)

📄 MANUAL.md 1.2 KB
📄 SKILL.md 1.1 KB
📄 _meta.json 130 B
📄 run.sh 627 B