From 19bd6d6e2d20bf7b3fd41291dc8b03470abbc052 Mon Sep 17 00:00:00 2001 From: Santiago Gimeno Date: Thu, 14 Nov 2024 16:00:18 +0100 Subject: [PATCH] tools: fix CURRENT_VERSION calculation Don't look for the last element but the third. PR-URL: https://github.com/nodesource/nsolid/pull/218 Reviewed-By: Trevor Norris --- tools/dep_updaters/update-nlohmann-json.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/dep_updaters/update-nlohmann-json.sh b/tools/dep_updaters/update-nlohmann-json.sh index ac196816bbc..d57bbe39ea2 100755 --- a/tools/dep_updaters/update-nlohmann-json.sh +++ b/tools/dep_updaters/update-nlohmann-json.sh @@ -24,9 +24,9 @@ console.log(tag_name.replace('v', '')); EOF )" -VERSION_MAJOR=$(grep "#define NLOHMANN_JSON_VERSION_MAJOR" ./deps/json/single_include/nlohmann/json.hpp | awk '{print $NF}') -VERSION_MINOR=$(grep "#define NLOHMANN_JSON_VERSION_MINOR" ./deps/json/single_include/nlohmann/json.hpp | awk '{print $NF}') -VERSION_PATCH=$(grep "#define NLOHMANN_JSON_VERSION_PATCH" ./deps/json/single_include/nlohmann/json.hpp | awk '{print $NF}') +VERSION_MAJOR=$(grep "#define NLOHMANN_JSON_VERSION_MAJOR" ./deps/json/single_include/nlohmann/json_fwd.hpp | awk '{print $3}') +VERSION_MINOR=$(grep "#define NLOHMANN_JSON_VERSION_MINOR" ./deps/json/single_include/nlohmann/json_fwd.hpp | awk '{print $3}') +VERSION_PATCH=$(grep "#define NLOHMANN_JSON_VERSION_PATCH" ./deps/json/single_include/nlohmann/json_fwd.hpp | awk '{print $3}') CURRENT_VERSION=$VERSION_MAJOR.$VERSION_MINOR.$VERSION_PATCH # This function exit with 0 if new version and current version are the same