metadata

package
v0.5.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 31, 2026 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func SaveGlobalMeta

func SaveGlobalMeta(meta *GlobalMeta) error

SaveGlobalMeta saves the global metadata file

func WriteRepoMeta

func WriteRepoMeta(repoPath string, meta *RepoMeta) error

WriteRepoMeta writes .rogmeta.yml to a repository directory

Types

type GlobalMeta

type GlobalMeta struct {
	Repos []GlobalRepoMeta `yaml:"repos"`
}

GlobalMeta represents global metadata configuration

func LoadGlobalMeta

func LoadGlobalMeta() (*GlobalMeta, error)

LoadGlobalMeta loads the global metadata file

type GlobalRepoMeta

type GlobalRepoMeta struct {
	Root            string   `yaml:"root"`
	Path            string   `yaml:"path"`
	Description     string   `yaml:"description,omitempty"`
	Tags            []string `yaml:"tags,omitempty"`
	PrimaryLanguage string   `yaml:"primary_language,omitempty"`
}

GlobalRepoMeta represents a repository entry in global metadata

func FindGlobalMeta

func FindGlobalMeta(globalMeta *GlobalMeta, root, relPath string) *GlobalRepoMeta

FindGlobalMeta finds metadata for a repository in global metadata

type RepoMeta

type RepoMeta struct {
	Name            string   `yaml:"name,omitempty"`
	Description     string   `yaml:"description,omitempty"`
	Tags            []string `yaml:"tags,omitempty"`
	PrimaryLanguage string   `yaml:"primary_language,omitempty"`
}

RepoMeta represents metadata for a repository

func MergeMeta

func MergeMeta(existing *RepoMeta, repoMeta *RepoMeta, globalMeta *GlobalRepoMeta) *RepoMeta

MergeMeta merges metadata from different sources with precedence Priority: repoMeta (manual) > globalMeta > existing

func ReadRepoMeta

func ReadRepoMeta(repoPath string) (*RepoMeta, error)

ReadRepoMeta reads .rogmeta.yml from a repository directory

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL