Question

In an .rpm file, there is an option to check whether the current install is the first version to be installed on the current system

i.e. %pre and %post scripts will be passed an argument equal to 1* also when the last version is erased %preun and %postun scripts will be passed an argument equal to 0*. ref:

Is there an equivalent thing in the installing of .deb files? This seems to be pretty obscure and my searches are turning up nothing to very little.

Was it helpful?

Solution

In .deb scripts, the current version of the package being installed is passed in as argument $2. If it's empty, that means there is no version of this package installed.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top