Documentation
¶
Index ¶
- func CreateProjectManifest(sourceRoot string, explicitPath string, format string, valuesObj *ValuesObj, ...) (string, error)
- func GenerateGo(configObj GoConfigObj) ([]byte, error)
- func ValidateGoVersion(raw string) error
- func ValidateVersion(raw string) error
- type GoConfigObj
- type Obj
- func (obj *Obj) IncrementMajor() (string, error)
- func (obj *Obj) IncrementMinor() (string, error)
- func (obj *Obj) IncrementPatch() (string, error)
- func (obj *Obj) Manifest() (*ValuesObj, error)
- func (obj *Obj) ManifestPath() string
- func (obj *Obj) Name() (string, error)
- func (obj *Obj) PreMajor(preID string) (string, error)
- func (obj *Obj) PreMinor(preID string) (string, error)
- func (obj *Obj) PrePatch(preID string) (string, error)
- func (obj *Obj) Prerelease(preID string) (string, error)
- func (obj *Obj) SourcePath() string
- func (obj *Obj) Stat() (os.FileInfo, error)
- func (obj *Obj) Validate() error
- func (obj *Obj) Version() (*VersionObj, error)
- func (obj *Obj) VersionString() (string, error)
- func (obj *Obj) Write(valuesObj *ValuesObj, force bool) error
- type ValuesObj
- type VersionObj
- func (obj *VersionObj) IncrementMajor() error
- func (obj *VersionObj) IncrementMinor() error
- func (obj *VersionObj) IncrementPatch() error
- func (obj *VersionObj) IncrementPrerelease(preID string) error
- func (obj *VersionObj) PreMajor(preID string) error
- func (obj *VersionObj) PreMinor(preID string) error
- func (obj *VersionObj) PrePatch(preID string) error
- func (obj *VersionObj) String() string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CreateProjectManifest ¶
func GenerateGo ¶
func GenerateGo(configObj GoConfigObj) ([]byte, error)
GenerateGo renders the project metadata file (Name/Version/Hash/DateUpdate).
func ValidateGoVersion ¶
func ValidateVersion ¶
Types ¶
type GoConfigObj ¶
type Obj ¶
type Obj struct {
// contains filtered or unexported fields
}
func NewProject ¶
NewProject opens a project manifest (meta.*) by file or directory.
func (*Obj) IncrementMajor ¶
func (*Obj) IncrementMinor ¶
func (*Obj) IncrementPatch ¶
func (*Obj) ManifestPath ¶
func (*Obj) SourcePath ¶
func (*Obj) Version ¶
func (obj *Obj) Version() (*VersionObj, error)
func (*Obj) VersionString ¶
type ValuesObj ¶
type ValuesObj struct {
Name string `json:"name,omitempty" yaml:"name,omitempty"`
Ver string `json:"ver" yaml:"ver"`
Hash string `json:"hash,omitempty" yaml:"hash,omitempty"`
}
ValuesObj is shared by project meta.* files and self-version values.* files.
type VersionObj ¶
type VersionObj struct {
Raw string
Major string
Minor uint64
Patch uint64
Prerelease string
Build string
}
func ParseVersion ¶
func ParseVersion(raw string) (*VersionObj, error)
func (*VersionObj) IncrementMajor ¶
func (obj *VersionObj) IncrementMajor() error
func (*VersionObj) IncrementMinor ¶
func (obj *VersionObj) IncrementMinor() error
func (*VersionObj) IncrementPatch ¶
func (obj *VersionObj) IncrementPatch() error
func (*VersionObj) IncrementPrerelease ¶
func (obj *VersionObj) IncrementPrerelease(preID string) error
func (*VersionObj) PreMajor ¶
func (obj *VersionObj) PreMajor(preID string) error
func (*VersionObj) PreMinor ¶
func (obj *VersionObj) PreMinor(preID string) error
func (*VersionObj) PrePatch ¶
func (obj *VersionObj) PrePatch(preID string) error
func (*VersionObj) String ¶
func (obj *VersionObj) String() string
Click to show internal directories.
Click to hide internal directories.