Okay any time I mention this product I get roasted but I don't care because I like it. There is a program called aptik and basically it backs up all your settings and home folder and then can be restored if you need to reinstall. https://store.teejeetech.com/product/aptik/
It's a one time purchase. I bought my copy like maybe almost 10 years ago and still use it. I used to have a script that I would maintain manually for this sort of thing but this is much easier. I also like that it will update strings and stuff for you when going from one version of a distro to another or between distros. You can also easily go in and uncheck things if you don't want them or only revert certain parts of the backup and not others. it has 100% saved my butt a few times especially where I had some weird config on a piece of software and after a restore it worked just like before. In my opinion this is also a better option than a diskimage because of the customization of the restore and the fact that you can do it I guess my biggest issue with it is it's not free software which is kind of annoying however it's just one dude and the license is very bare bones so it's not like he is trying to get away with anything with this tool.