<commit_before># Copyright (C) 2013 <NAME>

set (SYSCONFDIR ${CMAKE_INSTALL_FULL_SYSCONFDIR})
set (XDG_CONFIG_DIR "xdg/${CMAKE_PROJECT_NAME}")

file (GLOB_RECURSE CONFIG_FILES RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *)
list (REMOVE_ITEM CONFIG_FILES "CMakeLists.txt")

if (${CMAKE_INSTALL_PREFIX} MATCHES "/usr")
    set(CMAKE_INSTALL_SYSCONFDIR "/etc")
endif()

foreach (FILE ${CONFIG_FILES})
    string (FIND ${FILE} "adblock" ADBLOCK_CONF)
    if (ADBLOCK_CONF GREATER -1)
        string (REPLACE "config" "" dirname ${FILE})
        install (FILES ${FILE}
            DESTINATION "${CMAKE_INSTALL_SYSCONFDIR}/${XDG_CONFIG_DIR}/${dirname}")
    else ()
        install (FILES ${FILE}
            DESTINATION "${CMAKE_INSTALL_SYSCONFDIR}/${XDG_CONFIG_DIR}")
    endif ()
endforeach ()
<commit_msg>Only install config files to /etc if prefix equals /usr<commit_after># Copyright (C) 2013 <NAME>

set (SYSCONFDIR ${CMAKE_INSTALL_FULL_SYSCONFDIR})
set (XDG_CONFIG_DIR "xdg/${CMAKE_PROJECT_NAME}")

file (GLOB_RECURSE CONFIG_FILES RELATIVE ${CMAKE_CURRENT_SOURCE_DIR} *)
list (REMOVE_ITEM CONFIG_FILES "CMakeLists.txt")

if (${CMAKE_INSTALL_PREFIX} STREQUAL "/usr")
    set(CMAKE_INSTALL_SYSCONFDIR "/etc")
endif()

foreach (FILE ${CONFIG_FILES})
    string (FIND ${FILE} "adblock" ADBLOCK_CONF)
    if (ADBLOCK_CONF GREATER -1)
        string (REPLACE "config" "" dirname ${FILE})
        install (FILES ${FILE}
            DESTINATION "${CMAKE_INSTALL_SYSCONFDIR}/${XDG_CONFIG_DIR}/${dirname}")
    else ()
        install (FILES ${FILE}
            DESTINATION "${CMAKE_INSTALL_SYSCONFDIR}/${XDG_CONFIG_DIR}")
    endif ()
endforeach ()

{'fraction_non_alphanumeric': 0.1345565749235474, 'fraction_numerical': 0.0061162079510703364, 'mean_word_length': 4.527027027027027, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, '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': '5071160', 'n_tokens_mistral': 623, 'n_tokens_neox': 585, 'n_words': 123}