文档办公

wiki-switch

ar9av/obsidian-wiki

List, create, or switch named Obsidian wiki vault profiles under the global config directory. Use when changing the active vault, checking which vault is active, or managing multi-vault profiles.

  • 2089 次安装
  • 3600 星标
  • 收录于

安装命令

npx skills add https://github.com/ar9av/obsidian-wiki --skill wiki-switch

SKILL.md

Wiki Switch — Manage Multiple Vault Profiles

Global config dir. Every path below is relative to the global config dir, resolved per the Config Resolution Protocol in llm-wiki/SKILL.md: $XDG_CONFIG_HOME/obsidian-wiki (default ~/.config/obsidian-wiki), or the legacy ~/.obsidian-wiki if that already exists on disk. Resolve it once per invocation with:

CONFIG_DIR="$( [[ -d "$HOME/.obsidian-wiki" && ! -e "${XDG_CONFIG_HOME:-$HOME/.config}/obsidian-wiki" ]] && echo "$HOME/.obsidian-wiki" || echo "${XDG_CONFIG_HOME:-$HOME/.config}/obsidian-wiki" )"

Each vault is a complete config file at $CONFIG_DIR/config.<name>. The active vault is whichever file $CONFIG_DIR/config symlinks to. Switching vaults means re-pointing that symlink.