tianocore / edk2-edkrepo

Repository for the edkrepo utility
Other
21 stars 24 forks source link

commit, tag, branch priority support in list-repos and 'combo -v' commands #182

Closed ndhaller closed 11 months ago

ndhaller commented 1 year ago

I made a test Combination that uses commit and tag and branch at the same time, as this is a documented supported configuration to define all three. When the combo is checked out, the priority is supposed to be commit > tag > branch .

    <Combination name="sandbox-listRepos-test2-commit-tag-branch" description="a combo for testing the list-repos command with commit > tag > branch priority">
      <Source localRoot="edkrepo" remote="EdkrepoRepo" commit="31bb065c7f288437e2823a95606928325d6b2467" tag="edkrepo-v3.1.1" branch="main" />
      <Source localRoot="edkrepo-manifest" remote="EdkrepoManifestRepo" commit="498fc403d3ab9fd96fbd9ac3ca78dd01e5ead466" branch="main" />
    </Combination>

list-repos issue

The recently updated edkrepo list-repos command only lists this Combination by the branch name.

edkrepo - [https://github.com/tianocore/edk2-edkrepo]
Branches:
  main
    EdkRepo                                      : *(main)*
    Edkrepo-Sandbox2                             : *(sandbox-main2)*
                                                    (sandbox-listRepos-test2-commit-tag-branch)
edkrepo-manifest - [https://github.com/tianocore/edk2-edkrepo-manifest]
Branches:
  main
    EdkRepoManifest                              : *(main)*
    Edkrepo-Sandbox2                             : *(sandbox-main2)*
                                                    (sandbox-listRepos-test2-commit-tag-branch)

"edkrepo list-repos" should display the Combination under all of the groups it belongs to: branch name, tag name, and commit

combo -v issue

The recently updated "edkrepo combo -v" command, when used on this example combo, is also prioritizing the branch name instead of the higher priority commit or tag values in the Combination definition.

  sandbox-listRepos-test2-commit-tag-branch
    edkrepo          : main
    edkrepo-manifest : main