Documentation
¶
Index ¶
Constants ¶
View Source
const ( KclGoModulePath = "kcl-lang.io/kcl-go" KclPluginModulePath = "kcl-lang.io/kcl-plugin" )
Variables ¶
This section is empty.
Functions ¶
func ReleaseVersion ¶
func ReleaseVersion() string
Types ¶
type BuildInfo ¶
type BuildInfo struct {
GoVersion string `json:"goVersion,omitempty" yaml:"goVersion,omitempty"`
GOOS string `json:"GOOS,omitempty" yaml:"GOOS,omitempty"`
GOARCH string `json:"GOARCH,omitempty" yaml:"GOARCH,omitempty"`
NumCPU int `json:"numCPU,omitempty" yaml:"numCPU,omitempty"`
Compiler string `json:"compiler,omitempty" yaml:"compiler,omitempty"`
BuildTime string `json:"buildTime,omitempty" yaml:"buildTime,omitempty"` // Such as "2021-10-20 18:24:03"
}
type GitInfo ¶
type GitInfo struct {
LatestTag string `json:"latestTag,omitempty" yaml:"latestTag,omitempty"` // Such as "v1.2.3"
Commit string `json:"commit,omitempty" yaml:"commit,omitempty"` // Such as "3836f8770ab8f488356b2129f42f2ae5c1134bb0"
TreeState string `json:"treeState,omitempty" yaml:"treeState,omitempty"` // Such as "clean", "dirty"
}
GitInfo contains git information. following attributes:
LatestTag - "vX.Y.Z" used to indicate the last git tag. Commit - The git commit id corresponding to this source code. TreeState - "clean" indicates no changes since the git commit id, "dirty" indicates source code changes after the git commit id
type Info ¶
type Info struct {
ReleaseVersion string `json:"releaseVersion" yaml:"releaseVersion"` // Such as "1.2.3-3836f877"
GitInfo *GitInfo `json:"gitInfo,omitempty" yaml:"gitInfo,omitempty"`
BuildInfo *BuildInfo `json:"buildInfo,omitempty" yaml:"buildInfo,omitempty"`
}
Info contains versioning information. following attributes:
ReleaseVersion - "X.Y.Z-00000000" used to indicate the last release version, containing GitVersion and GitCommitShort.
func NewDefaultVersionInfo ¶
func NewDefaultVersionInfo() *Info
func NewMainOrDefaultVersionInfo ¶
func NewMainOrDefaultVersionInfo() *Info
Click to show internal directories.
Click to hide internal directories.