obsidian-cli

작성자: kepano

Obsidian CLI를 사용해 노트, 작업, 속성 등을 읽고, 생성하고, 검색하며 관리할 수 있습니다. 또한 플러그인과 테마 개발을 지원하며, 플러그인 리로드, JavaScript 실행, 오류 캡처, 스크린샷 촬영, DOM 검사 등의 명령어를 제공합니다. 사용자가 Obsidian 저장소와 상호작용하거나, 노트를 관리하고, 저장소 내용을 검색하거나, 명령줄에서 저장소 작업을 수행하거나, Obsidian 플러그인 및 테마를 개발 및 디버깅할 때 사용하세요.

npx skills add https://github.com/kepano/obsidian-skills --skill obsidian-cli

Obsidian CLI

Use the obsidian CLI to interact with a running Obsidian instance. Requires Obsidian to be open.

Command reference

Run obsidian help to see all available commands. This is always up to date. Full docs: https://help.obsidian.md/cli

Syntax

Parameters take a value with =. Quote values with spaces:

obsidian create name="My Note" content="Hello world"

Flags are boolean switches with no value:

obsidian create name="My Note" silent overwrite

For multiline content use \n for newline and \t for tab.

File targeting

Many commands accept file or path to target a file. Without either, the active file is used.

  • file=<name> — resolves like a wikilink (name only, no path or extension needed)
  • path=<path> — exact path from vault root, e.g. folder/note.md

Vault targeting

Commands target the most recently focused vault by default. Use vault=<name> as the first parameter to target a specific vault:

obsidian vault="My Vault" search query="test"

Common patterns

obsidian read file="My Note"
obsidian create name="New Note" content="# Hello" template="Template" silent
obsidian append file="My Note" content="New line"
obsidian search query="search term" limit=10
obsidian daily:read
obsidian daily:append content="- [ ] New task"
obsidian property:set name="status" value="done" file="My Note"
obsidian tasks daily todo
obsidian tags sort=count counts
obsidian backlinks file="My Note"

Use --copy on any command to copy output to clipboard. Use silent to prevent files from opening. Use total on list commands to get a count.

Plugin development

Develop/test cycle

After making code changes to a plugin or theme, follow this workflow:

  1. Reload the plugin to pick up changes:
    obsidian plugin:reload id=my-plugin
    
  2. Check for errors — if errors appear, fix and repeat from step 1:
    obsidian dev:errors
    
  3. Verify visually with a screenshot or DOM inspection:
    obsidian dev:screenshot path=screenshot.png
    obsidian dev:dom selector=".workspace-leaf" text
    
  4. Check console output for warnings or unexpected logs:
    obsidian dev:console level=error
    

Additional developer commands

Run JavaScript in the app context:

obsidian eval code="app.vault.getFiles().length"

Inspect CSS values:

obsidian dev:css selector=".workspace-leaf" prop=background-color

Toggle mobile emulation:

obsidian dev:mobile on

Run obsidian help to see additional developer commands including CDP and debugger controls.

kepano의 다른 스킬

obsidian-markdown
kepano
Obsidian Flavored Markdown을 생성하고 편집합니다. 위키링크, 임베드, 콜아웃, 속성 및 기타 Obsidian特有 구문을 포함합니다. .md 파일을 Obsidian에서 작업하거나 사용자가 위키링크, 콜아웃, 프론트매터, 태그, 임베드 또는 Obsidian 노트를 언급할 때 사용하세요.
documentproductivitycreative
defuddle
kepano
Defuddle CLI를 사용해 웹페이지에서 깔끔한 마크다운 콘텐츠를 추출하여, 불필요한 요소와 내비게이션을 제거하고 토큰을 절약합니다. 사용자가 읽거나 분석할 URL을 제공하거나, 온라인 문서, 기사, 블로그 게시물 또는 일반 웹페이지에 대해 WebFetch 대신 사용하세요. .md로 끝나는 URL에는 사용하지 마세요. 해당 URL은 이미 마크다운이므로 WebFetch를 직접 사용하세요.
web-scrapingresearchdocument
json-canvas
kepano
JSON Canvas 파일(.canvas)을 생성 및 편집하며, 노드, 엣지, 그룹, 연결을 포함합니다. .canvas 파일 작업, 시각적 캔버스, 마인드맵, 순서도 생성 시, 또는 사용자가 Obsidian에서 Canvas 파일을 언급할 때 사용하세요.
developmentdesigndocument
obsidian-bases
kepano
Obsidian Bases(.base 파일)를 생성하고 편집하며, 뷰, 필터, 수식, 요약을 포함합니다. .base 파일 작업 시, 노트의 데이터베이스 형태 뷰를 만들 때, 또는 사용자가 Obsidian에서 Bases, 테이블 뷰, 카드 뷰, 필터, 수식을 언급할 때 사용하세요.
databaseproductivitydata-analysis