obsidian-cli
Skill for the official Obsidian CLI (v1.12+). Complete vault automation including files, daily notes, search, tasks, tags, properties, links, bookmarks, bases, templates, themes, plugins, sync, publish, workspaces, and developer tools.
安装 / 下载方式
TotalClaw CLI推荐
totalclaw install github:LeoYeAI~openclaw-master-skills~obsidian-clicURL直接下载,无需登录
curl -fsSL https://skills.taituai.com/api/skills/github%3ALeoYeAI~openclaw-master-skills~obsidian-cli/file -o obsidian-cli.md# Obsidian CLI (Official, v1.12+) The official Obsidian CLI connects to a running Obsidian instance via IPC. Requires Obsidian 1.12+ with CLI enabled in Settings > General. ## Prerequisites - **Obsidian 1.12+** installed and running - CLI enabled: Settings > General > Enable CLI - The `obsidian` binary must be in your PATH **Important**: Obsidian must be running for CLI commands to work. The CLI communicates with the running instance via IPC. ### Platform Notes - **macOS/Windows**: The Obsidian installer typically places the CLI binary in PATH automatically. - **Linux**: You may need a wrapper script to avoid Electron flag injection that breaks CLI arg parsing. Ensure your wrapper is in PATH before the system `obsidian` binary. If running as a service, ensure `PrivateTmp=false` for IPC to work. ## Complete Command Reference ### Basics ```bash obsidian version # Show Obsidian version obsidian help # List all available commands obsidian vault # Show vault info (name, path, files, size) obsidian vault info=name # Just vault name obsidian vault info=path # Just vault path obsidian reload # Reload the vault obsidian restart # Restart the app ``` ### Daily Notes ```bash obsidian daily # Open today's daily note obsidian daily silent # Open without focusing obsidian daily:read # Read daily note contents obsidian daily:append content="- [ ] Task" # Append to daily note obsidian daily:prepend content="# Header" # Prepend to daily note obsidian daily paneType=tab # Open in new tab (tab|split|window) ``` ### Files ```bash obsidian read file=Recipe # Read by name (wikilink resolution) obsidian read path="Work/notes.md" # Read by exact path obsidian file file=Recipe # Show file info (path, size, dates) obsidian create name=Note content="Hello" # Create a new note obsidian create name=Note template=Travel # Create from template obsidian create path="Work/note.md" content="text" # Create at exact path obsidian create name=Note overwrite # Overwrite if exists obsidian create name=Note silent newtab # Create silently in new tab obsidian open file=Recipe # Open in Obsidian obsidian open file=Recipe newtab # Open in new tab obsidian delete file=Old # Delete (to trash) obsidian delete file=Old permanent # Delete permanently obsidian move file=Old to="Archive/Old.md" # Move/rename (include .md in target) obsidian append file=Log content="Entry" # Append to file obsidian append file=Log content="text" inline # Append inline (no newline) obsidian prepend file=Log content="Header" # Prepend to file obsidian unique name="Meeting" content="notes" # Create note with unique timestamp obsidian wordcount file=Note # Word and character count obsidian wordcount file=Note words # Words only obsidian wordcount file=Note characters # Characters only obsidian random # Open a random note obsidian random:read # Read a random note obsidian random folder="Work" # Random note from folder obsidian recents # List recently opened files obsidian recents total # Count of recent files ``` ### Search ```bash obsidian search query="meeting notes" # Search vault obsidian search query="TODO" matches # Show match context obsidian search query="project" path="Work" limit=10 # Scoped search obsidian search query="test" format=json # JSON output obsidian search query="Bug" case # Case-sensitive search obsidian search query="error" total # Count matches only obsidian search:open query="TODO" # Open search view in Obsidian ``` ### Tasks ```bash obsidian tasks daily # Tasks from daily note obsidian tasks daily todo # Incomplete daily tasks obsidian tasks daily done # Completed daily tasks obsidian tasks all todo # All incomplete tasks in vault obsidian tasks file=Recipe done # Completed tasks in file obsidian tasks verbose # Tasks with file paths + line numbers obsidian tasks total # Count of tasks obsidian tasks status="/" # Tasks with custom status character obsidian task daily line=3 toggle # Toggle task completion obsidian task daily line=3 done # Mark task done obsidian task daily line=3 todo # Mark task incomplete obsidian task ref="Work/todo.md:5" toggle # Toggle by file:line reference obsidian task daily line=3 status="/" # Set custom status ``` ### Tags & Properties ```bash # Tags obsidian tags all counts # All tags with counts obsidian tags all counts sort=count # Sorted by frequency obsidian tags file=Note # Tags in specific file obsidian tags total # Total tag count obsidian tag name=project verbose # Tag details with file list obsidian tag name=project total # Count of files with tag # Properties (frontmatter) obsidian properties all counts # All properties with counts obsidian properties all counts sort=count # Sorted by frequency obsidian properties file=Note # Properties of specific file obsidian properties name=status # Files with specific property obsidian properties format=yaml # YAML output obsidian properties format=tsv # TSV output obsidian property:read name=status file=Note # Read a property value obsidian property:set name=status value=done file=Note # Set a property obsidian property:set name=due value="2026-03-01" type=date file=Note # Set with type obsidian property:remove name=status file=Note # Remove a property # Aliases obsidian aliases # List all aliases in vault obsidian aliases all # Include files without aliases obsidian aliases file=Note # Aliases for specific file obsidian aliases total # Count of aliases obsidian aliases verbose # With file paths ``` ### Links & Structure ```bash obsidian backlinks file=Note # Files linking to Note obsidian backlinks file=Note counts # With link counts obsidian backlinks file=Note total # Count of backlinks obsidian links file=Note # Outgoing links from Note obsidian links file=Note total # Count of outgoing links obsidian orphans # Files with no incoming links obsidian orphans total # Count of orphans obsidian orphans all # Include non-markdown files obsidian deadends # Files with no outgoing links obsidian deadends total # Count of deadends obsidian unresolved # Broken/unresolved links obsidian unresolved total # Count of unresolved obsidian unresolved counts # With reference counts obsidian unresolved verbose # With source file details obsidian outline file=Note # Headings tree obsidian outline file=Note format=md # Headings as markdown obsidian outline file=Note total # Count of headings ``` ### Vault Info ```bash obsidian files total # File count obsidian files folder="Work" ext=md # Filter by folder and extension obsidian folders # List all folders obsidian folders total