Ubuntu – Find Check package version without installation

We can install package easily in Ubuntu by the apt-get command. But sometimes we may want to find out what packages are available in the repositories as well as the package version.

To search a package, use the apt-cache search <name> command.
For example, apt-cache search nginx
ubuntu-find-and-search-package-1
 

Now we know that we could install the nginx or nginx-light package which has minimal set of core modules.

Next, we want to know the version number of the package which we are going to install. In this case, use the apt-get -s install <name> command.
For example, apt-get -s install nginx-light
ubuntu-find-and-search-package-2
 

It shows that the nginx-light is with version 1.1.19-1.

Done =)

Reference: StackExchange – Check package version using apt-get/aptitude?

Leave a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.