From fb21b708461641927290976adb2b7eee21b5748e Mon Sep 17 00:00:00 2001 From: Victor Romero Date: Thu, 14 Jan 2021 08:57:05 -0800 Subject: [vcpkg] Change version field in `baseline.json` (#15633) * [vcpkg] Change version field in `baseline.json` * Change name from `version-tag` to `baseline` * [vcpkg] x-history serializes version scheme * Update e2e tests * Update baseline e2e test --- toolsrc/include/vcpkg/registries.h | 4 ++-- toolsrc/include/vcpkg/sourceparagraph.h | 5 +++++ toolsrc/include/vcpkg/versiondeserializers.h | 1 + 3 files changed, 8 insertions(+), 2 deletions(-) (limited to 'toolsrc/include') diff --git a/toolsrc/include/vcpkg/registries.h b/toolsrc/include/vcpkg/registries.h index c36c0179d..74782859d 100644 --- a/toolsrc/include/vcpkg/registries.h +++ b/toolsrc/include/vcpkg/registries.h @@ -106,8 +106,8 @@ namespace vcpkg std::unique_ptr>> get_registry_array_deserializer( const fs::path& configuration_directory); - ExpectedS>> get_builtin_versions(const VcpkgPaths& paths, - StringView port_name); + ExpectedS>> get_builtin_versions(const VcpkgPaths& paths, + StringView port_name); ExpectedS>> get_builtin_baseline(const VcpkgPaths& paths); } diff --git a/toolsrc/include/vcpkg/sourceparagraph.h b/toolsrc/include/vcpkg/sourceparagraph.h index 50417b8ad..f2dd0798b 100644 --- a/toolsrc/include/vcpkg/sourceparagraph.h +++ b/toolsrc/include/vcpkg/sourceparagraph.h @@ -12,6 +12,7 @@ #include #include #include +#include #include namespace vcpkg @@ -107,6 +108,10 @@ namespace vcpkg const FeatureFlagSettings& flags) const; VersionT to_versiont() const { return core_paragraph->to_versiont(); } + SchemedVersion to_schemed_version() const + { + return SchemedVersion{core_paragraph->version_scheme, core_paragraph->to_versiont()}; + } friend bool operator==(const SourceControlFile& lhs, const SourceControlFile& rhs); friend bool operator!=(const SourceControlFile& lhs, const SourceControlFile& rhs) { return !(lhs == rhs); } diff --git a/toolsrc/include/vcpkg/versiondeserializers.h b/toolsrc/include/vcpkg/versiondeserializers.h index 02696d39b..ae368f6c5 100644 --- a/toolsrc/include/vcpkg/versiondeserializers.h +++ b/toolsrc/include/vcpkg/versiondeserializers.h @@ -11,6 +11,7 @@ namespace vcpkg { Json::IDeserializer& get_versiont_deserializer_instance(); + Json::IDeserializer& get_versiontag_deserializer_instance(); std::unique_ptr> make_version_deserializer(StringLiteral type_name); struct SchemedVersion -- cgit v1.2.3