post_upgrade() {
  # 3 adds sd-btrfs-overlayfs to the initramfs: build it again now, so that snapshots taken
  # from here on start from the boot menu (each keeps the initramfs it was taken with).
  if (( $(vercmp "$2" 3) < 0 )); then
    limine-update
  fi
}

post_remove() {
  # /etc/os-release back to Arch's own (a link to /usr/lib/os-release, as Arch makes it).
  ln -sfn ../usr/lib/os-release /etc/os-release
}
