Before I install a package I'd like to know what version i would get. How do I check the version before installing using
aptitude on debian or ubuntu?
You can run a simulation to see what would happen if you upgrade/install a package:
To see all possible upgrades, run a
If installed, shows version information about one or more packages:
The console GUI of
Or on the command-line:
Another option, if you don't know the full name of the package, is formatting aptitude's search output:
After running an update/upgrade you can always use, for instance :-
Now while the above is a bit different than your case as I have also used priority to keep unstable and experimental out but it would be something similar to this.
Even apt-show-versions -u is good enough for what you want as well.