From 2a42024b53ebb512fb5dd63c523338bf26c8489c Mon Sep 17 00:00:00 2001 From: Victor Romero Date: Thu, 7 Jan 2021 18:04:11 -0800 Subject: [vcpkg] Add commands to maintain and verify versions db integrity (#14999) * [vcpkg] Add x-ci-verify-versions command * Code cleanup * Remove port version splitting from x-history * Fix wrong message on success * Parallelize versions file generator * Use cpu_count()/2 to avoid crashes * Check db SHA against local SHA * Check baseline version with x-ci-verify-versions and make baseline generator much faster * Implement x-add-version to update version db files * Better checks for x-add-info and make x-ci-verify-versions silent on success * Use find() instead of [] on maps * Create version file if does not exist * Allow redirection of ports/ and port_versions/ * add test ports * WIP end-to-end tests * Change pats in e2e tests * Fix e2e args * e2e once more * Pass ersions feature flag to e2e * Exit with code 1 if there are errors * Files to test for failure cases * Update test files * Add test for x-add-version * fix redirected ports in last test * Add CI check (use dummy data) * Add feature-flags=versions * Ignore subdirectories inside ports * Add --verify-git-trees switch * [vcpkg] Fix build breaks * [x-ci-verify-versions] PR comments * [x-add-version] PR comments * Fix merge conflicts * Modify tests and pipeline * Baselines should only have version-string * Refactor x-add-version * [vcpkg] Fix help message * [vcpkg] Fix minor warnings * `x-add-version --all` doesn't stop on first failure and reduced default verbosity * [vcpkg] Fix default-baseline * Load file instead of using paths provider * Format * Remove ci test * Add fish port for testing * Update version files * Update fish port to cause SHA discrepancy * Test for discrepancy between local SHA and declared SHA * Missing = operator * Check for error message since x-add-version exits with code 0 * Make x-add-version fail with non-zero exit code if not run with --all Co-authored-by: Robert Schumacher Co-authored-by: Robert Schumacher --- scripts/testing/version-files/ports/mouse/portfile.cmake | 1 + scripts/testing/version-files/ports/mouse/vcpkg.json | 4 ++++ 2 files changed, 5 insertions(+) create mode 100644 scripts/testing/version-files/ports/mouse/portfile.cmake create mode 100644 scripts/testing/version-files/ports/mouse/vcpkg.json (limited to 'scripts/testing/version-files/ports/mouse') diff --git a/scripts/testing/version-files/ports/mouse/portfile.cmake b/scripts/testing/version-files/ports/mouse/portfile.cmake new file mode 100644 index 000000000..0015715fb --- /dev/null +++ b/scripts/testing/version-files/ports/mouse/portfile.cmake @@ -0,0 +1 @@ +set(VCPKG_POLICY_EMPTY_PACKAGE enabled) \ No newline at end of file diff --git a/scripts/testing/version-files/ports/mouse/vcpkg.json b/scripts/testing/version-files/ports/mouse/vcpkg.json new file mode 100644 index 000000000..fd6cab451 --- /dev/null +++ b/scripts/testing/version-files/ports/mouse/vcpkg.json @@ -0,0 +1,4 @@ +{ + "name": "mouse", + "version-semver": "1.0.0" +} \ No newline at end of file -- cgit v1.2.3