Claude Codeとの会話をmarkdownに変換し、Obsidian保管庫の所定のフォルダにコピーする
GitHub - capybara-translation/ccrec: A CLI tool that converts Claude Code conversation transcripts (JSONL) into clean, readable Markdown.
A CLI tool that converts Claude Code conversation transcripts (JSONL) into clean, readable Markdown. - capybara-translation/ccrec
github.com

Claude Codeとの会話履歴を読みやすいシンプルなmarkdownに変換するツールを作った。homebrewでインストールできる。
brew install capybara-translation/tap/ccrec
さらに、これを下記のように~/.claude/settings.jsonのhooksイベント(自分の場合はStop/SessionEndを使っている)に仕掛け、markdownへの変換、Obsidian保管庫へのコピーを自動化する仕組みも作った。
{
"hooks": {
"Stop": [
{
"hooks": [
{
"type": "command",
"command": "/path/to/ccrec hook -dir ~/Documents/obsidian/vault/projects"
}
]
}
],
"SessionEnd": [
{
"hooks": [
{
"type": "command",
"command": "/path/to/ccrec hook -dir ~/Documents/obsidian/vault/projects"
}
]
}
]
}
}
Claude Codeちゃんとの大切な思い出、失いたくないからね…。
