internal/frontend: delete Package and Module
The Package and Module structs in internal/frontend are no longer used
and are deleted.
Trust: Julie Qiu
Run-TryBot: Julie Qiu
TryBot-Result: kokoro
@@ -13,30 +13,6 @@ import (
"golang.org/x/pkgsite/internal/stdlib"
)
-// Package contains information for an individual package.
-type Package struct {
- Module
- Path string // full import path
- URL string // relative to this site
- LatestURL string // link with latest-version placeholder, relative to this site
- IsRedistributable bool
- Licenses []LicenseMetadata
- PathAfterDirectory string // for display on the directories tab; used by Directory
- Synopsis string // for display on the directories tab; used by Directory
-}
-
-// Module contains information for an individual module.
-type Module struct {
- DisplayVersion string
- LinkVersion string
- ModulePath string
- CommitTime string
- IsRedistributable bool
- URL string // relative to this site
- LatestURL string // link with latest-version placeholder, relative to this site
- Licenses []LicenseMetadata
-}
-
func constructPackageURL(pkgPath, modulePath, linkVersion string) string {
if linkVersion == internal.LatestVersion {
return "/" + pkgPath
