Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Search Tools

find_files

Find files matching a glob pattern.

Permission: Read

Parameters

NameTypeRequiredDescription
patternstringyesGlob pattern to match files against
pathstringnoDirectory to search in (defaults to current directory)
scratchpadstringnoSave output to the scratchpad under this name

Behavior

  • Results are limited to 200 matches.
  • Returns one file path per line.

Glob Patterns

PatternMatches
*.rsAll .rs files in the current directory
**/*.rsAll .rs files recursively
src/*.txtAll .txt files in src/
test_*All files starting with test_

search_contents

Search file contents using a regex pattern. Powered by the ripgrep library.

Permission: Read

Parameters

NameTypeRequiredDescription
patternstringyesRegex pattern to search for
pathstringnoFile or directory to search in (defaults to current directory)
globstringnoGlob pattern to filter which files are searched (e.g., *.rs)
scratchpadstringnoSave output to the scratchpad under this name

Behavior

  • Searches recursively through directories.
  • Skips hidden files (starting with .) and common non-text directories (target, node_modules).
  • Results are limited to 100 matches.
  • Each result includes the file path, line number, and matching line.