obsidian-git-backup/README.md

1.1 KiB

Obsidian Git Backup

This script automates the process of backing up your Obsidian vault to a Git repository. It ensures that all changes are tracked automatically and can be easily restored if needed.

Features

  • Trigger backup after file changes with delay
  • Maintain git repo in a seperate folder to not have the repo synced by syncthing (copy changed files over)
  • Push changes to remote repository
  • Tray Menu
    • Exit
    • Backup now
    • See current changed files
    • See time after last file change
  • Easy configuration of paths and delay

Installation

  • Create target repo folder and initialize an empty git repository
  • Set up git lfs for attachments
    • $ git lfs install
    • .gitattributes
      *.pdf filter=lfs diff=lfs merge=lfs -text
      *.png filter=lfs diff=lfs merge=lfs -text
      *.jpg filter=lfs diff=lfs merge=lfs -text
      *.jpeg filter=lfs diff=lfs merge=lfs -text
      *.webp filter=lfs diff=lfs merge=lfs -text
      *.avif filter=lfs diff=lfs merge=lfs -text
      *.svg filter=lfs diff=lfs merge=lfs -text
      
  • Link repository to origin as remote