[Trigger]
Type = Package
Operation = Install
Operation = Upgrade
Operation = Remove
Target = *

[Action]
Description = Create a backup list of all installed packages
When = PostTransaction
Exec = /bin/sh -c "yay -Qqe > /home/matt/.config/pacman/packages.txt && sed -i '1d' /home/matt/.config/pacman/packages.txt"
