Migrate lock commands to independent objects

This commit is contained in:
2026-09-05 13:11:11 +00:00
parent 4bc33773fa
commit 610eaefb27
13 changed files with 368 additions and 156 deletions

View File

@@ -84,7 +84,7 @@ func Status(ctx context.Context, args []string, out io.Writer) error {
artifacts.CollectPreviousArtifactRequirements(configuredScriptoriumArtifacts(cfg), effective),
))
lockChecks := inspectEffectiveLocks(ctx, cfg, store)
lockChecks := inspectRemoteLocks(ctx, cfg, store)
locks := lockChecks.Locks
lockErr := lockChecks.Err
if catalog, catalogErr := buildHelperArtifactCatalog(cfg, localManifest); catalogErr != nil {
@@ -92,10 +92,7 @@ func Status(ctx context.Context, args []string, out io.Writer) error {
} else if storeErr == nil {
catalogLocks := locks
if lockErr != nil {
catalogLocks = &effectiveLocks{
Static: staticPublishLocks(cfg),
All: staticPublishLocks(cfg),
}
catalogLocks = nil
}
publishedRemoteState := map[string]string{}
if store != nil {