Greg Wooledge wrote: > On Thu, May 28, 2020 at 09:34:51PM +0700, Victor Sudakov wrote: > > > > > dpkg --get-selections > /root/initial-packages > > > > > > > > > > Just hold on to that file, and it will allow you to return to this > > > > > state on the same machine, or conceivably even a different machine. > > > > > > > > Out of itself, this file will not allow me anything. But Charles Curley > > > > has named the debfoster utility which seems to do the closest thing to > > > > what I wanted to achieve. > > > > > > What?! > > > > > > It does PRECISELY WHAT YOU STATED you wanted to do! > > > > Well, I wanted a degree of automation, not just a > > "dpkg --get-selections | diff /root/initial-packages -" for visual > > analysis and manual removal. > > The reverse of dpkg --get-selections is dpkg --set-selections, which > you run using the saved file as input instead of output. Then you > follow this with something like "apt-get dselect-upgrade" to install > the packages necessary to make the new system match the old system.
Sounds tricky (I've never used dselect and other low-level things before and don't know much of them) but I'll certainly save this paragraph for future reference. Thank you. -- Victor Sudakov, VAS4-RIPE, VAS47-RIPN 2:5005/49@fidonet http://vas.tomsk.ru/