Pacmanfile is a bash script that lets you manage Arch declaratively. It creates a pacmanfile that has a list of packages that were installed explicitly. You can update this list and run a sync and that will get the system to match that list.
I've made some minor changes to the program. I've added in a new command called edit that will open the pacmanfile in an editor. I've also added a check for the file before doing a sync as syncing without the file would result in trying to remove everything.
The pacmanfile is a text file and so it has no natural syntax highlighting which is annoying as I can't tell what is commented out easily. I also would like to group my packages so that I can choose to install X stuff vs wayland stuff. I thought maybe it would be better to write my configuration in something like ini or json. ini would be better as it would be simpler. Then it dawned on my that I could parse the ini file and then sync the packages and also do stuff like enabling things on boot or even user creation. At this point I realized why Nix has it's own language and why configuration.nix is written in it.
There are other arch projects like pacdec and pacdef that expand on what pacmanfile does. Unfortunately they don't go as far as nix does.