Skip to content

Commit

Permalink
Sort provider version by provider Source.
Browse files Browse the repository at this point in the history
  • Loading branch information
Zheng Qin committed Sep 10, 2024
1 parent 9b4036c commit c7ff5b4
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions cli/bpmetadata/tfconfig.go
Original file line number Diff line number Diff line change
Expand Up @@ -216,6 +216,8 @@ func parseBlueprintProviderVersions(versionsFile *hcl.File) ([]*ProviderVersion,
Version: strings.Join(providerData.VersionConstraints, ", "),
})
}
// Sort provider_versions
sort.SliceStable(v, func(i, j int) bool { return v[i].Source < v[j].Source })
return v, nil
}

Expand Down

0 comments on commit c7ff5b4

Please sign in to comment.