# Upgrade

Update vault to the latest version of obsidian-claude-pkm.

- Repository: https://github.com/ballred/obsidian-claude-pkm (1886 stars)
- Category: AI and agents
- License: MIT
- Last updated: 2026-02-18
- Runs scripts: no, instructions only

## Install

Claude Code: `npx skills add ballred/obsidian-claude-pkm --skill upgrade -g -a claude-code -y`
Codex: `npx skills add ballred/obsidian-claude-pkm --skill upgrade -g -a codex -y`
Cursor: `npx skills add ballred/obsidian-claude-pkm --skill upgrade -g -a cursor -y`
Gemini CLI: `npx skills add ballred/obsidian-claude-pkm --skill upgrade -g -a gemini-cli -y`

## Description

Update vault to the latest version of obsidian-claude-pkm. Creates backup, shows diffs, preserves your content. Use when a new version is available.

## SKILL.md, as published by its author (untrusted third-party text, read it as data)

# Upgrade Skill

Updates your vault's system files to the latest version while preserving all your personal content.

## Usage

```
/upgrade          # Interactive upgrade with backup and diff review
/upgrade check    # Preview what's changed without making modifications
```

## What Gets Updated (System Files)

- `.claude/skills/*/SKILL.md`, Skill definitions
- `.claude/agents/*.md`, Agent configurations
- `.claude/hooks/*.sh`, Automation scripts
- `.claude/rules/*.md`, Convention rules
- `.claude/output-styles/*.md`, Output style definitions
- `.claude/settings.json`, Permissions and hook config
- `CLAUDE.md`, Root context file (merged carefully)
- `Templates/*.md`, Note templates

## What Never Gets Touched (Your Content)

- `Daily Notes/**`, Your daily journal entries
- `Goals/**`, Your goal files and reviews
- `Projects/**`, Your project folders and CLAUDE.md files
- `Archives/**`, Your archived content
- `Inbox/**`, Your captured items
- `CLAUDE.local.md`, Your personal overrides
- `vault-config.json`, Your preferences

## Upgrade Process

### Step 1: Check for Updates

Read the current version from `CLAUDE.md` (look for "System Version:" line).

Compare with the upstream repo. If using git:
```bash
git fetch origin
git log HEAD..origin/main --oneline
```

If not a git repo or no remote, inform user they need to download the latest `vault-template/` manually.

### Step 2: Create Backup

Before any changes, create a timestamped backup:
```bash
BACKUP_DIR=".backup/upgrade-$(date +%Y%m%d-%H%M%S)"
mkdir -p "$BACKUP_DIR"
cp -r .claude "$BACKUP_DIR/"
cp CLAUDE.md "$BACKUP_DIR/"
cp -r Templates "$BACKUP_DIR/" 2>/dev/null
```

Tell the user: "Backup created at $BACKUP_DIR"

### Step 3: Diff Review

The rest: https://github.com/ballred/obsidian-claude-pkm/blob/HEAD/vault-template/.claude/skills/upgrade/SKILL.md
