#!/bin/sh
set -e

case "$1" in
  configure)
    if command -v plymouth-set-default-theme >/dev/null 2>&1; then
      # Set saikyo-boot as default theme for system boot
      plymouth-set-default-theme -R saikyo-boot >/dev/null 2>&1 || true
    fi
    # Update initramfs to include plymouth theme
    if command -v update-initramfs >/dev/null 2>&1; then
      update-initramfs -u >/dev/null 2>&1 || true
    fi
    ;;
esac

exit 0
