Dpkg
commands
check if {packagename} is installed :
dpkg -s <packagename>
dpkg-query has a neater output , and accepts wild cards :
dpkg-query -l <packagename>
To find what package owns the command :
dpkg -S `which <command>`
to examine archive files
dpkg --info {.deb filename}
dpkg-deb --info {.deb filename}
```
find out which repository a package comes from
apt-cache policy
```