Rebrand Ubuntu without breaking apt: os-release and dpkg-divert

HaltOS introduces itself as HaltOS 1.0 (SIGKILL) in lsb_release, fastfetch and the KDE About page, while apt, PPAs and vendor install scripts still see Ubuntu. Getting there takes a little care.
The fields that matter
/etc/os-release is where programs ask which system they run on. Some fields are for people, some for scripts:
PRETTY_NAME="HaltOS 1.0 (SIGKILL)"
NAME="HaltOS"
VERSION="1.0 (SIGKILL)"
VARIANT_ID=haltos
ID=ubuntu
ID_LIKE=debian
VERSION_CODENAME=resolute
NAME, PRETTY_NAME and VARIANT are what people see. ID, VERSION_ID and VERSION_CODENAME are what installers read to decide which packages to fetch. Change those and every script that checks for Ubuntu breaks. Keep them, and you can rename the system freely.
Do not just overwrite the file
/usr/lib/os-release, /etc/lsb-release and /etc/issue belong to the base-files package, and the next update would silently put Ubuntu's versions back. dpkg-divert tells dpkg to install its copy somewhere else instead:
cp -a /usr/lib/os-release /usr/lib/os-release.ubuntu
dpkg-divert --local --no-rename --divert /usr/lib/os-release.ubuntu --add /usr/lib/os-release
Copy first and divert with --no-rename: the essential file is never missing, not even for a moment, and package updates now land in the .ubuntu copy, which you can read the real version numbers from.
Everything else follows
Ubuntu's lsb_release reads os-release, so it follows automatically. The KDE About page takes a logo and website from /etc/xdg/kcm-about-distrc. fastfetch was the odd one out: it saw ID=ubuntu plus KDE and decided the system was Kubuntu, so HaltOS prints the OS line from os-release directly.
Undo
Reversing it is the same steps backwards: copy the diverted file back, remove the diversion, delete the copy. sudo haltos undo-system does exactly that.