Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ( // Error when no RPM spec file or `rpmspec` command was found ErrNoSpec = fs.ErrNotExist )
Functions ¶
This section is empty.
Types ¶
type RPMSpec ¶
type RPMSpec struct {
// contains filtered or unexported fields
}
parser.VersionParser implementation rendering and parsing a RPM spec file
func New ¶
New creates a new parser.Parser instance using the provided RPM spec file. the rpmspec executable is invoked using the provided path.
func NewSystem ¶
NewSystem creates a new parser.Parser instance using the provided RPM spec file. the rpmspec executable is invoked as-is, relying on its presence in one of the PATH directories.
func TryParse ¶
TryParse attempts to parse the given directory for a RPM spec file. If no file was found or the given command was not found ErrNoRepository is returned. All other errors are a result of file access problems.
func TrySystemParse ¶
TrySystemParse calls TryParse using the rpmspec command found in the PATH
func (*RPMSpec) ParseVersionInfo ¶
func (s *RPMSpec) ParseVersionInfo() (*buildinfo.VersionInfo, error)
ParseVersionInfo implements the parser.VersionParser interface