<commit_before>if(GIT_FOUND)
    execute_process(COMMAND ${GIT_EXECUTABLE} describe --abbrev=0 --tags
    WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
    OUTPUT_VARIABLE VERSION_STRING
    OUTPUT_STRIP_TRAILING_WHITESPACE)
endif()

if(VERSION_STRING)
    set(PROJECT_VERSION "${VERSION_STRING}")
else()
    # extract it from the existing generated header file
    file(STRINGS "${CMAKE_CURRENT_SOURCE_DIR}/aws-cpp-sdk-core/include/aws/core/VersionConfig.h" __SDK_VERSION_LINE LIMIT_COUNT 1 REGEX "AWS_SDK_VERSION_STRING.*[0-9]+\\.[0-9]+\\.[0-9]+" )
    string( REGEX MATCH "([0-9]+\\.[0-9]+\\.[0-9]+)" VERSION_STRING "${__SDK_VERSION_LINE}" )
endif()

message(STATUS "Building project version: ${PROJECT_VERSION}")

macro(add_project name description)
    set(PROJECT_NAME "${name}")
    set(PROJECT_STRING    "${name}_${PROJECT_VERSION}")
    set(PROJECT_TARNAME   "${name}-${PROJECT_VERSION}")
    set(PROJECT_BUGREPORT "https://github.com/aws/aws-sdk-cpp/issues/")
    set(PROJECT_DESCRIPTION "${description}")
    set(PROJECT_LIBS "")
    foreach(library_var ${ARGN})
        list(APPEND PROJECT_LIBS "${library_var}")
    endforeach()

    project(${name} VERSION "${PROJECT_VERSION}" LANGUAGES CXX)

endmacro()
<commit_msg>More cmake unhappiness<commit_after>if(GIT_FOUND)
    execute_process(COMMAND ${GIT_EXECUTABLE} describe --abbrev=0 --tags
    WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}
    OUTPUT_VARIABLE VERSION_STRING
    OUTPUT_STRIP_TRAILING_WHITESPACE)
endif()

if(VERSION_STRING)
    set(PROJECT_VERSION "${VERSION_STRING}")
else()
    # extract it from the existing generated header file
    file(STRINGS "${CMAKE_CURRENT_SOURCE_DIR}/aws-cpp-sdk-core/include/aws/core/VersionConfig.h" __SDK_VERSION_LINE LIMIT_COUNT 1 REGEX "AWS_SDK_VERSION_STRING.*[0-9]+\\.[0-9]+\\.[0-9]+" )
    string( REGEX MATCH "([0-9]+\\.[0-9]+\\.[0-9]+)" VERSION_STRING "${__SDK_VERSION_LINE}" )
endif()

message(STATUS "Building project version: ${PROJECT_VERSION}")

macro(add_project name description)
    set(PROJECT_NAME "${name}")
    set(PROJECT_STRING    "${name}_${PROJECT_VERSION}")
    set(PROJECT_TARNAME   "${name}-${PROJECT_VERSION}")
    set(PROJECT_BUGREPORT "https://github.com/aws/aws-sdk-cpp/issues/")
    set(PROJECT_DESCRIPTION "${description}")
    set(PROJECT_LIBS "")
    foreach(library_var ${ARGN})
        list(APPEND PROJECT_LIBS "${library_var}")
    endforeach()

    cmake_policy(SET CMP0028 NEW)
    cmake_policy(SET CMP0048 NEW)
    cmake_policy(SET CMP0054 NEW)
    cmake_policy(SET CMP0056 NEW)

    project(${name} VERSION "${PROJECT_VERSION}" LANGUAGES CXX)

endmacro()

{'fraction_non_alphanumeric': 0.14877300613496933, 'fraction_numerical': 0.01687116564417178, 'mean_word_length': 5.011520737327189, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5271173', 'n_tokens_mistral': 953, 'n_tokens_neox': 946, 'n_words': 152}