Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduce 'ci --output-hashes=' #167

Merged

Conversation

ras0219-msft
Copy link
Contributor

In order to build additional tooling on top of the vcpkg CI, we need to know the package hashes of what is being built. This PR introduces the ability for the CI to output the full set of computed hashes for the run, with a schema like:

[
  {
    "name": "boost-vcpkg-helpers",
    "triplet": "x64-linux",
    "state": "pass",
    "abi": "f9931d4a68e4136736dba6de934e450cb427df181c560f855510a3588f9b1fb0"
  },
  {
    "name": "boost-config",
    "triplet": "x64-linux",
    "state": "pass",
    "abi": "96b7c320891a2fb2d0abced0308c433d6ee6aab85404145f84c505fcd2fcedaa"
  },
  {
    "name": "boost-preprocessor",
    "triplet": "x64-linux",
    "state": "pass",
    "abi": "e236064d5bd096a970d4a01097e6e491d3aa099b8f2afa048150656a42a5559c"
  }
]

For quick-and-dirty manipulation, this can be munged through jq, such as jq '[.[].abi]' cihashes.json to get the full list of hashes.

To implement this functionality, I've refactored the mega function find_unknown_ports_for_ci into three smaller, simpler functions which are closer to being testable.

@ras0219-msft ras0219-msft marked this pull request as draft August 21, 2021 01:38
@ras0219-msft ras0219-msft marked this pull request as ready for review September 14, 2021 21:03
@ras0219-msft ras0219-msft merged commit 3272721 into microsoft:main Sep 16, 2021
@ras0219-msft ras0219-msft deleted the dev/roschuma/ci-write-hashes branch September 16, 2021 21:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants