refmeta

package
v0.0.23 Latest Latest
Warning

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

Go to latest
Published: Sep 7, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ErrRepoNotInitialized = errors.Sentinel("this repository not initialized: please run `av init`")

Functions

func Import

func Import(repo *git.Repo, db meta.DB) error

Import imports all ref metadata from the git repo into the database.

func ReadAllBranches

func ReadAllBranches(repo *git.Repo) (map[string]meta.Branch, error)

ReadAllBranches fetches all branch metadata stored in the git repository. It returns a map where the key is the name of the branch.

func ReadBranch

func ReadBranch(repo *git.Repo, branchName string) (meta.Branch, bool)

ReadBranch loads information about the branch from the git repository. Returns the branch metadata and a boolean indicating if the branch metadata already existed and was loaded. If the branch metadata does not exist, a useful default is returned.

func ReadBranchState

func ReadBranchState(repo *git.Repo, branch string, trunk bool) (meta.BranchState, error)

func ReadRepository

func ReadRepository(repo *git.Repo) (meta.Repository, error)

ReadRepository reads repository metadata from the git repo. Returns the metadata and a boolean indicating if the metadata was found.

Types

This section is empty.

Jump to

Keyboard shortcuts

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