Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

Does the Ubuntu Software Center keep a log of everything it has installed? So I could just parse this log to convert it into a script full of 'sudo apt-get instals' or something. And then the next time I install Ubuntu I could just this script to re-install everything.

share|improve this question
add comment

4 Answers 4

up vote 3 down vote accepted

Yes, It maintains a log in /var/log/apt/history.log. Older histories gets compressed as .gz files. It contains installation, upgrade and removal logs.
For keeping existing software backups you can use dpkg-repack to make .deb files out of installed files. Here.

share|improve this answer
add comment

Yes it does. You're looking for the file:

~/.cache/software-center/apthistory.p

I have no idea how to parse it or how to understand the format it's in, but that's not the question you asked.

share|improve this answer
add comment

If this is for personal use, there is a way to sync programs built in to the software center. If you just click File -> "Sync Between Computers". You just have to create an Ubuntu Software Center account. Here is a how-to with more information which may be relevant, http://www.howtogeek.com/111989/how-to-sync-quickly-reinstall-applications-on-ubuntu/.

share|improve this answer
add comment

You can also get a list of all manually installed packages which are not a dependency of another package by running this command:

$ deborphan -a | awk '{print $2}' | sort > packages.list

For reinstalling these packages, use:

$ sudo apt-get install $(cat packages.list | tr '\n' ' ')
share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.