0

Description:

This is somehow simple; I am migrating to an other computer.
I am going to take the opportunity to switch to the new 18.04 LTS from the 16.04 (on the old computer).

On the 16.04 I installed so many (!) libraries and packages manually using apt-get.

Question:

Is there a way to fetch these packages, in a text file for example, that I can copy and paste on the 18.04 to feed an apt-get command to install them back?

s.k
  • 1,280
  • I wrote a guide and made a video about this in 2014. I'm sure the same process still applies. See https://techedemic.com/2014/10/01/offline-package-installs-using-dpkg-and-apt-get-ubuntudebianetc/ – Techedemic Dec 05 '18 at 12:55

1 Answers1

0

You seem to be looking for the apt-mark command.

apt-mark showmanual will return a list of all packages marked manual.

There are two sets of manual packages, and they are all mixed together:

  1. Packages you specified to apt (sudo apt install foo or sudo apt-mark manual foo) These are the top-level packages in your system. Everything else is a dependency. Usually your desktop metapackage is among these.

  2. Packages installed by the Desktop installer during the initial installation of Ubuntu. This is a safety measure to prevent users from erroneously removing large slabs of their system when they remove their desktop metapackage.

user535733
  • 62,253