5

Can I choose which packages I want to upgrade with apt?

Using apt-get upgrade upgrades all packages, not just some of them.

Using apt-get install package doesn't upgrade some by me required packages which are related to the specified package.

Example: When I type sudo apt-get install firefox, packages like firefox-locale-en still using previous package version.

BuZZ-dEE
  • 14,223
obysr
  • 780
  • Why do you want only upgrade some specified packages? – BuZZ-dEE Feb 22 '13 at 21:01
  • @obysr If there are no updates to any dependency, then the installed version will be kept when updating the main package. In fact, the new version of the package has that "old" version of a dependency as its own dependency. – carnendil Feb 22 '13 at 21:20
  • 1
    @BuZZ-dEE cause my connection has limited quota, so i just download that i think they're important. – obysr Feb 23 '13 at 10:27
  • 1
    @carnendil it means firefox-locale-en is not firefox's depencies? how does canonical manage its product? – obysr Feb 23 '13 at 10:28
  • 2
    @obysr firefox doesn't depend on firefox-locale-en. You can see it with: apt-cache depends firefox. – BuZZ-dEE Feb 23 '13 at 15:30

2 Answers2

5

Assuming you have old versions of the packages foo and bar, you can use apt-get install foo bar, which will install the latest versions of selected packages foo and bar, resulting in an upgrade.

BuZZ-dEE
  • 14,223
andol
  • 6,733
2

If there are specific packages that you don't want upgraded, you can lock them to the current version. There are instructions here: How to prevent updating of a specific package?

Then you can use apt-get upgrade to update the rest.