Setting up a second Ubuntu or Debian box and wanting the same packages is a small chore. I’d let dpkg keep the list for me.
On the old machine, write the list of installed packages to a file:
dpkg --get-selections > packages.txt
Copy the file over. On the new machine, feed it back and let apt do the installing:
sudo apt-get update
sudo dpkg --set-selections < packages.txt
sudo apt-get dselect-upgrade
--set-selections only marks packages as wanted. apt-get dselect-upgrade then installs everything that is marked and not yet present, so you see the usual apt summary and a confirmation prompt before anything happens.
A caveat: the file lists every installed package, dependencies included, so the new machine ends up with all of them marked as manually installed. Removing an app later won’t clean up its dependencies automatically. If you want a shorter list of only what you chose yourself, apt-mark showmanual gives that, and you can install it with plain apt install.
Also check that both machines run the same release and have the same third-party sources enabled. Packages that don’t exist in the new machine’s repositories are simply skipped, which is easy to miss in a long output.
Further reading: dpkg man page