Versions in this module Expand all Collapse all v0 v0.0.1 May 8, 2022 Changes in this version + const Version + var ErrNoConfidentLicense = fmt.Errorf("no confident license found in file") + var ErrNoLicenseFile = fmt.Errorf("no license file found") + type Dependency struct + Module string + Version string + func ParseDependency(modline []byte) (Dependency, error) + func (d *Dependency) UnmarshalJSON(b []byte) error + func (d Dependency) GetLicense() (License, error) + func (d Dependency) MarshalJSON() ([]byte, error) + func (d Dependency) String() string + type License string + type ModLicenses struct + Licenses map[Dependency]License + func FromDir(dir string) (ModLicenses, error) + func FromModFilePath(modpath string) (ModLicenses, error) + func FromModfile(r io.Reader) (ModLicenses, error) + func FromWD() (ModLicenses, error) + func (ml *ModLicenses) UnmarshalJSON(in []byte) error + func (ml ModLicenses) MarshalJSON() ([]byte, error)