Documentation ¶
Overview ¶
Package maven provides bare-bones utilities for analysing maven projects.
Some functions in this package assume mvn to be in your PATH.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EffectiveModule ¶
An EffectiveModule contains the interesting parts of the mvn help:effective-pom output for a single-module project.
type EffectivePom ¶
type EffectivePom struct {
Projects []EffectiveModule `xml:"project"`
}
An EffectivePom contains the interesting parts of the mvn help:effective-pom output for a multi-module project.
func ParseEffectivePom ¶
func ParseEffectivePom(r io.Reader) (EffectivePom, error)
type Header ¶
A Header corresponds to the parts of a POM that determine the identity of a maven module.
func (Header) EffectiveArtifactID ¶
EffectiveArtifactID is the artifactId of a POM. If an artifactId was not specified explicitly, the parent one is used.
func (Header) EffectiveGroupID ¶
EffectiveGroupID is the groupId of a POM. If a groupId was not specified explicitly, the parent one is used.
func (Header) EffectiveIdentity ¶
EffectiveIdentity calculates the effective identity of a module based on it's Header.
func (Header) EffectiveVersion ¶
EffectiveVersion is the version of a POM. If a version was not specified explicitly, the parent one is used.
type Identity ¶
type Identity struct { GroupID string `xml:"groupId"` ArtifactID string `xml:"artifactId"` Version string `xml:"version"` }
An Identity of a maven module.
type Project ¶
type Project struct {
// contains filtered or unexported fields
}
A Project that is built using maven.
func NewProject ¶
NewProject attempts to create a maven project given a locally cloned repository.
func (Project) Builds ¶
func (prj Project) Builds() []unibuild.RequirementVersion
func (Project) Info ¶
func (prj Project) Info() unibuild.ProjectInfo
func (Project) Uses ¶
func (prj Project) Uses() []unibuild.Requirement
type Requirement ¶
type Requirement struct {
// contains filtered or unexported fields
}
func NewRequirement ¶
func NewRequirement(id Identity) Requirement
func (Requirement) ID ¶
func (req Requirement) ID() unibuild.RequirementIdentity