Documentation
¶
Index ¶
Constants ¶
View Source
const ( Filename = "scribe.lock" ProjectFilename = "scribe.lock" ProjectKind = "ProjectLock" SchemaVersion = 1 )
View Source
const ContentHashFilename = ".scribe-content-hash"
Variables ¶
This section is empty.
Functions ¶
func CommandHash ¶
Types ¶
type Entry ¶
type Entry struct {
Name string `yaml:"name" json:"name"`
SourceRegistry string `yaml:"source_registry" json:"source_registry"`
CommitSHA string `yaml:"commit_sha" json:"commit_sha"`
ContentHash string `yaml:"content_hash" json:"content_hash"`
InstallCommandHash string `yaml:"install_command_hash,omitempty" json:"install_command_hash,omitempty"`
SourceKey string `yaml:"source_key,omitempty" json:"source_key,omitempty"`
Source *source.SourceSpec `yaml:"source,omitempty" json:"source,omitempty"`
ResolvedRev string `yaml:"resolved_rev,omitempty" json:"resolved_rev,omitempty"`
}
type Lockfile ¶
type ProjectEntry ¶
type ProjectEntry struct {
Entry `yaml:",inline"`
SourceRepo string `yaml:"source_repo,omitempty" json:"source_repo,omitempty"`
Path string `yaml:"path,omitempty" json:"path,omitempty"`
Type string `yaml:"type,omitempty" json:"type,omitempty"`
Install string `yaml:"install,omitempty" json:"install,omitempty"`
Update string `yaml:"update,omitempty" json:"update,omitempty"`
Installs map[string]string `yaml:"installs,omitempty" json:"installs,omitempty"`
Updates map[string]string `yaml:"updates,omitempty" json:"updates,omitempty"`
}
type ProjectKit ¶
type ProjectKit struct {
Name string `yaml:"name" json:"name"`
SourceRegistry string `yaml:"source_registry" json:"source_registry"`
CommitSHA string `yaml:"commit_sha" json:"commit_sha"`
ContentHash string `yaml:"content_hash" json:"content_hash"`
SkillsRefs []string `yaml:"skills_refs,omitempty" json:"skills_refs,omitempty"`
}
type ProjectLockfile ¶
type ProjectLockfile struct {
FormatVersion int `yaml:"format_version"`
Kind string `yaml:"kind"`
GeneratedAt string `yaml:"generated_at,omitempty"`
GeneratedBy string `yaml:"generated_by,omitempty"`
Kits []ProjectKit `yaml:"kits,omitempty"`
Entries []ProjectEntry `yaml:"entries"`
}
func ParseProject ¶
func ParseProject(data []byte) (*ProjectLockfile, error)
func (*ProjectLockfile) Encode ¶
func (lf *ProjectLockfile) Encode() ([]byte, error)
func (*ProjectLockfile) Entry ¶
func (lf *ProjectLockfile) Entry(name string) (ProjectEntry, bool)
func (*ProjectLockfile) Validate ¶
func (lf *ProjectLockfile) Validate() error
Click to show internal directories.
Click to hide internal directories.