Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // By convention, modules with a major version equal to or above v2 // have it as suffix in their module path. VCSUrlMajorVersionSuffixRegex = regexp.MustCompile(`(/v[\d]+)$`) // gopkg.in/user/pkg.v -> github.com/user/pkg VCSUrlGoPkgInRegexWithUser = regexp.MustCompile(`^gopkg\.in/([^/]+)/([^.]+)\..*$`) // gopkg.in without user segment // Example: gopkg.in/pkg.v3 -> github.com/go-pkg/pkg VCSUrlGoPkgInRegexWithoutUser = regexp.MustCompile(`^gopkg\.in/([^.]+)\..*$`) )
Functions ¶
Types ¶
type Parser ¶
type Parser struct {
// contains filtered or unexported fields
}
func (*Parser) GetExternalRefs ¶
func (p *Parser) GetExternalRefs(path string) []types.ExternalRef
func (*Parser) Parse ¶
func (p *Parser) Parse(r types.ReadSeekerAt) ([]types.Library, []types.Dependency, error)
Parse parses a go.mod file
Click to show internal directories.
Click to hide internal directories.