#!/bin/sh
# crypt-sync hook start
if command -v crypt-sync >/dev/null 2>&1 && [ -f ".cryptsync" ]; then
  if ! crypt-sync configured 2>/dev/null; then
    echo "[crypt-sync] warning: identity not configured, skipping unlock. Run: crypt-sync init"
    exit 0
  fi
  crypt-sync unlock --quiet
fi
# crypt-sync hook end
