Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I get version information of a package which will be installed using apt on debian-based linux

I have a vim on my debian system. I want to update vim by apt-get install vim. But I'm not sure about the version which will be installed. If it is not the version I want, I will install by sources. How can I know what version will be installed? aptitude search or apt-cache search only gives me a short description, not the version. And aptitude show or apt-get show gives version information of installed packages. Thanks in advance.

like image 435
Tokubara Avatar asked Sep 20 '25 20:09

Tokubara


1 Answers

aptitude show or apt-cache show shows available versions in addition to installed versions. Unless you're doing something weird with pins, the highest available version is the one that will be installed.

Since you mention aptitude, you can also open up the aptitude TUI and navigate to the package in question. In the overview view, the second-to-last column shows the currently-installed version of the package, and the last column shows the version that will be installed if you use + to mark the package for installation. If you press Enter on the package, the detail page will show all available versions, at the bottom.

like image 50
hobbs Avatar answered Sep 22 '25 09:09

hobbs



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!