Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #list all installed packages with dpkg
- dpkg --get-selections| grep -v deinstall
- #get a count of installed packages
- dpkg --get-selections| grep -v deinstall|sc -l
- #list all installed with apt
- apt list --installed
- #get a count with apt
- apt list --installed|grep -v "^Listing"|sc -l
- ###backup list of installed packages###
- dpkg --get-selections | grep -v deinstall > packages.lst
- sudo apt-get install -y $(< packages.lst)
- sudo apt-get autoremove
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement