package inventory import "context" // Lookups of builds the delivery plans once held, which other code still reads. // BuildOf is the id of the newest successful build of a module from a commit; empty when none is // recorded (a manifest handed over by hand). func (i *Inventory) BuildOf(ctx context.Context, module, commit string) (string, error) { c, err := i.theChain(ctx) if err != nil { return "", err } return i.chainBuildOf(ctx, c, module, commit) } // BuildFingerprints is, per commit, what the newest successful build of a module from it would put on a // machine — its artifacts and its manifest, hashed — so a rebuild that changes nothing there is told // from one that does (the bus's planned step, ADR 0236). func (i *Inventory) BuildFingerprints(ctx context.Context, module string) (map[string]string, error) { c, err := i.theChain(ctx) if err != nil { return nil, err } return i.chainBuildFingerprints(ctx, c, module) }