Also have a look here: https://wiki.debian.org/Packaging
There is also http://codesearch.debian.net/ which let you search the packages.