I'm learning Debian's package management system and have read Chapter 2. Debian package management. But I have difficulty in understanding the concept of "selection", or maybe "package selection". More specifically:
- What exactly is a "package selection"?
- What does a "package selection" select?
- Under what circumstances do I need to care about a "package selection"?
For example, whenever I want to find whether I have a package installed on my system, I usually run dpkg --get-selections 'PACKAGE-NAME'
. Frankly speaking, I don't know exactly why the option is called get-selections
and why I should use it. I turned to dpkg
manpage, but it doesn't explain further. The chapter above doesn't seem to explain, either.
While I'm reading the Debian reference, I see another tool called dselect
which also helps manage the packages. I'm also curious why it is called "select", and this may be a hint to understanding the concept of "selection".
According to my current research, I have some guesses of what it is about:
- The "selection" may have something to do with multiple versions of the same package. I can install all the versions on my system, but the "selection" specifies which version is the active one.
- The "selection" may have something to do with alternative packages that serve the same purpose. For example, I may install
vi
,vim
, andnvi
on my system, and the "selection" specifies which one is the actively used one.
However, the understandings above don't look right because that seems to be solved by using the symbolic links.
Hope someone would explain it to me. Thanks for the help!