Only check vignettes if checking a software package

or if we can't determine package type. Added an unexported function
getPkgType() and associated tests.