Install
openclaw skills install snippets-syncSync code snippets and notes between machines via file sync. Organized by language, rendered in any Markdown viewer (Obsidian, VS Code, etc.).
openclaw skills install snippets-syncThe vault is a directory of .md files synced between machines (typically via Syncthing, but any file sync works). Anything written to the vault appears on all synced devices.
Primary use case: Sharing code snippets, notes, and structured content through Obsidian — persists across sessions, renders nicely in Obsidian, and is searchable.
Set SNIPPETS_VAULT_PATH to your vault directory. Defaults to ~/snippets-vault if unset. Point this at a dedicated directory — not your home dir or any folder containing secrets.
| Path | |
|---|---|
| Vault | $SNIPPETS_VAULT_PATH |
| Synced to | Your other machines via Syncthing/rsync/etc. |
Just read/write .md files in the vault directory. Obsidian picks up changes automatically via file sync.
Notes are plain Markdown with optional YAML frontmatter:
---
created: 2026-04-05
tags: [snippet, python]
---
# Note Title
Content here. Use standard Markdown formatting.
code_snippets/
├── python/
│ └── http-server.md
├── bash/
│ └── find-large-files.md
├── typescript/
│ └── debounce.md
├── docker/
│ └── healthcheck.md
└── _uncategorized/
└── random-thing.md
Rules:
python/, bash/, typescript/, docker/, sql/, lua/, gdscript/, etc.)json-parser.md, not snippet-001.md_uncategorized/ for anything that doesn't fit a clear bucket---
created: YYYY-MM-DD
language: <lang>
tags: [snippet, <lang>, <topic>]
---
# Descriptive Title
Description or context here.
\```<lang>
# code here
\```
Usage: `command to run if applicable`
Use Obsidian vault when:
Use chat directly when:
When dropping a snippet, send a brief heads-up in chat:
"Dropped snippet:
code_snippets/python/http-server.md"
These files render in Obsidian, not Discord/chat. Write standard CommonMark Markdown:
# / ## / ### — never **bold text** as a fake header```python) — never inline backticks for multi-line code> blockquotes for emphasis, no ~~strikethrough~~ abuse, no platform-specific formatting[[other-note]]) for internal references, standard [text](url) for external- or 1. with proper indentation*italic* and **bold** are fine — use sparingly, for actual emphasisThe goal: clean, readable notes that render well in Obsidian's reading view.
If obsidian-cli is installed and the vault is registered with Obsidian desktop:
obsidian-cli search "query" # search note names
obsidian-cli search-content "query" # search inside notes
obsidian-cli list # list files
Direct file I/O is the reliable path on headless Linux.
.md files in the vault directory.obsidian/ or other app config directoriesSNIPPETS_VAULT_PATH at a dedicated snippet/note directory — never at home, ~/.ssh, password stores, or credential-containing repos.obsidian/ — that's Obsidian's config[[other-note]] links between notes