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.

This question already has an answer here:

As you've probably noticed - I am a Ubuntu noob (I just got it yesterday.)

I have installed some programs through Terminal before, about 5-10 - so using Terminal doesn't scare me. But, I'm getting a new computer soon (yes, yes, I know I should've waited and did this on the new computer instead, but I was so excited! I'm sure you can relate ;A;) and I've heard it's hard and time consuming to move apps over to another hard disk, and it would be easier just to install them again. So, I will... but I don't really remember what I have installed and want an easy way to do this.

Is there any way to have a list of installed programs in Terminal or somewhere - and possibly even the apt-get commands to reinstall?

share|improve this question
1  
wow, from a noon to semi expert. Now you have got 1k++ points. Very nice. How's your way thru ubunto now? I find it difficult to migrate from windows, but what can I do, still trying. –  Joraid Mar 23 at 5:12
    
Haha indeed. It's been good so far. Now I'm using only Ubuntu and not Windows. Try your best, there are many willing people here to help you :) Good luck. –  Mochan Mar 25 at 6:00
add comment

marked as duplicate by Gilles, Mik, Thomas W., vasa1, Eliah Kagan Mar 21 '13 at 2:09

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

3 Answers

up vote 2 down vote accepted

The magic keyword you are looking for is migration. You have the same question as someone who wants to move his current installation to a new computer.

Here is a quick explanation how to do it: http://eggsonbread.com/2010/01/28/move-ubuntu-to-another-computer-in-3-simple-steps/

If you just want to get the list of currently installed programs, you just need the first command:

sudo dpkg --get-selections | sed "s/.*deinstall//" | sed "s/install$//g" > ~/pkglist

This will store your currently installed packages in the file ~/pkglist (~ stands for your home directory). You can open and review it with any text editor or in the terminal with

cat ~/pkglist
share|improve this answer
    
Btw, if you want to paste the command in your terminal, you have to use ctrl+shift+v –  Martin Betz Jul 21 '12 at 9:07
    
Oh ok, thanks. I usually Right-Click > Paste while in Terminal, but I didn't know that, thanks! And thank you so much for the link! If I had reputation I'd vote you up... but well, I'm still a noob ^^'' –  Mochan Jul 22 '12 at 0:07
    
Thanks so much again! :D –  Mochan Jul 22 '12 at 0:08
add comment

Open the dash, select the apps lens, and click on the installed section to see them all.

Also, reading your question more carefully, to get a text list, try dpkg --get-selections.

share|improve this answer
    
Great answer, thanks so much. Also, is there any way to transfer packages, or would that be another question? Thanks guys! –  Mochan Jul 22 '12 at 0:05
1  
See asymptotically's suggestion about re-installing the package list. –  Jazz Jul 22 '12 at 22:05
add comment

All you have to do is

dpkg --get-selections > list.txt

If you're trying to reinstall all these packages in another computer, just do

sudo dpkg --set-selections < list.txt && sudo apt-get -u dselect-upgrade
share|improve this answer
    
I tried this, and it just upgraded a python package. Is that what the second one was supposed to do? But great answer, thanks! –  Mochan Jul 22 '12 at 0:03
    
After you save the package list, if you enter the second command, it will install all the packages in list.txt that are not currently in your computer. So, if you start with computer with newly-installed Ubuntu, and type the second commadn (and, of course, have a copy of list.txt), all the packages you had previously installed will be installed. –  asymptotically Jul 22 '12 at 3:43
    
Oh! Of COURSE! Thanks so much! –  Mochan Jul 24 '12 at 10:33
add comment

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