Is it safe to delete desktopfs-pkgs.txt and rootfs-pkgs.txt?

Hello,

I was wondering if anyone could tell me if it is safe to remove, or at least move to a different place, the files /desktopfs-pkgs.txt and /rootfs-pkgs.txt?
I like to keep my root directory clean, and I find having these files there is slightly annoying.
As far as I can tell, they seem to contain a list of packages/programs installed, but I do not see the use for this, so I would like to remove them. At the same time, I am slightly afraid that deleting files I do not understand from my root directory may break something, or that I may regret it later if they cannot be re-generated and there is a time when I will need them.
In addition, if they have been generated by a program (since I did not create them) will they just reappear if I delete them, and if so is there a way to change where they are created?

While on the topic, is there any use case for these files that Iā€™m overlooking?

Many thanks in advance.

The file content reflect the packages used to install your system - they are auto generated and there are purely informational.

Go ahead and remove them.

1 Like

I found that the files sometimes useful to understand the origin of a package: [Stable Update] 2021-12-10 - Kernels, Systemd, LibreOffice, Plasma, Browser, Thunderbird - #285 by alven
I saved mine just in any further case.