diff options
Diffstat (limited to 'Tests/RunCMake/CMakeRelease/FileTable.cmake')
-rw-r--r-- | Tests/RunCMake/CMakeRelease/FileTable.cmake | 20 |
1 files changed, 20 insertions, 0 deletions
diff --git a/Tests/RunCMake/CMakeRelease/FileTable.cmake b/Tests/RunCMake/CMakeRelease/FileTable.cmake new file mode 100644 index 0000000..1bddeb8 --- /dev/null +++ b/Tests/RunCMake/CMakeRelease/FileTable.cmake @@ -0,0 +1,20 @@ +set(version "@version@") +set(version_major "1") +set(version_minor "2") +set(version_patch "3") +set(maybe_version_suffix "\"suffix\": \"rc4\",") +configure_file("${CMAKE_CURRENT_LIST_DIR}/../../../Utilities/Release/files-v1.json.in" "files-v1.json" @ONLY) + +foreach(query + ".version | .major , .minor , .patch , .suffix, .string" + ".files[].name" + ".files[] | select(.os[] | . == \"source\") | .name" + ".files[] | select((.os[] | . == \"macOS\") and (.class == \"volume\")) | .name" + ".files[] | select((.os[] | . == \"windows\") and (.architecture[] | . == \"i386\") and (.class == \"installer\")) | .name" + ".files[] | select(.architecture[] | . == \"x86_64\") | .name" + ".files[] | select([.macOSmin] | inside([\"10.7\", \"10.8\", \"10.9\"])) | .name" + ".hashFiles[] | select(.algorithm[] | . == \"SHA-256\") | .name" + ) + message(STATUS "query: ${query}") + execute_process(COMMAND ${JQ} "${query}" files-v1.json) +endforeach() |