I want to format my system, but I don’t want to lose my updates and installed packages. I also want the same packages on other systems as well.
Asked
Active
Viewed 80 times
1 Answers
0
Backing up should be:
dpkg --get-selections > ~/Package.list
sudo cp /etc/apt/sources.list ~/sources.list
sudo apt-key exportall > ~/Repo.keys
and restoring should be
sudo apt-key add ~/Repo.keys
sudo cp ~/sources.list /etc/apt/sources.list
sudo apt-get update
sudo apt-get install dselect
sudo dpkg --set-selections < ~/Package.list
sudo apt-get dselect-upgrade -y
...If I'm not mistaken.