Simple tool to match installed packages and configs on *Nix

Hello. I like to have an uniform installation across personal devices, that is, I like to have the same packages, configurations, wallpapers and so on on my laptop and desktop computers even if they do not use the same OS version. I already use a git repo to keep track of most dot files.

I’m mostly interested in having a way to sync installed packages on both desktop and laptop. Of course some software doesn’t make sense on every system and sometimes it won’t be Linux. Extra functionalities like syncing conda environments would be nice. I don’t want over engineered tools that require server and agents. I was considering using ansible and keeping the formula within my dot file repo but I would like to know if there are better options to do this. Something that runs from a single static binary like terraform would be superb.

Any suggestions? Do you have a working setup you want to show?

Thanks.