obx search
The obx search command allows you to perform full-text searches across your Obsidian vault. It’s optimized for speed and provides output formats suitable for both human reading and scripting.
obx search <query> [flags] [vault_path]Or, if an active vault is configured:
obx search "machine learning"Options
Section titled “Options”| Flag | Shorthand | Description | Default |
|---|---|---|---|
--limit | -l | Maximum number of results to return | 10 |
--dir | -d | Restrict search to a specific directory inside the vault |
Examples
Section titled “Examples”Basic Search
Section titled “Basic Search”obx search "meeting notes"Output:
Found 3 results:- meetings/2023-10-25.md- meetings/2023-10-26.md- projects/website-redesign.mdSearching within a Directory
Section titled “Searching within a Directory”To limit your search to a specific folder (e.g., projects):
obx search "TODO" -d projectsLimiting Results
Section titled “Limiting Results”To get only the top 5 matches:
obx search "API key" -l 5