From 84ed75ca7db28672a29d865382389ad3e0f03f8a Mon Sep 17 00:00:00 2001 From: Lars Melchior Date: Fri, 3 Feb 2023 18:38:14 +0100 Subject: [PATCH 01/10] Update CPM.cmake (#164) --- cmake/CPM.cmake | 19 +++++++++++++++---- 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/cmake/CPM.cmake b/cmake/CPM.cmake index a10f926..e9674a7 100644 --- a/cmake/CPM.cmake +++ b/cmake/CPM.cmake @@ -1,8 +1,6 @@ -set(CPM_DOWNLOAD_VERSION 0.35.0) +set(CPM_DOWNLOAD_VERSION 0.37.0) if(CPM_SOURCE_CACHE) - # Expand relative path. This is important if the provided path contains a tilde (~) - get_filename_component(CPM_SOURCE_CACHE ${CPM_SOURCE_CACHE} ABSOLUTE) set(CPM_DOWNLOAD_LOCATION "${CPM_SOURCE_CACHE}/cpm/CPM_${CPM_DOWNLOAD_VERSION}.cmake") elseif(DEFINED ENV{CPM_SOURCE_CACHE}) set(CPM_DOWNLOAD_LOCATION "$ENV{CPM_SOURCE_CACHE}/cpm/CPM_${CPM_DOWNLOAD_VERSION}.cmake") @@ -10,12 +8,25 @@ else() set(CPM_DOWNLOAD_LOCATION "${CMAKE_BINARY_DIR}/cmake/CPM_${CPM_DOWNLOAD_VERSION}.cmake") endif() -if(NOT (EXISTS ${CPM_DOWNLOAD_LOCATION})) +# Expand relative path. This is important if the provided path contains a tilde (~) +get_filename_component(CPM_DOWNLOAD_LOCATION ${CPM_DOWNLOAD_LOCATION} ABSOLUTE) + +function(download_cpm) message(STATUS "Downloading CPM.cmake to ${CPM_DOWNLOAD_LOCATION}") file(DOWNLOAD https://github.com/cpm-cmake/CPM.cmake/releases/download/v${CPM_DOWNLOAD_VERSION}/CPM.cmake ${CPM_DOWNLOAD_LOCATION} ) +endfunction() + +if(NOT (EXISTS ${CPM_DOWNLOAD_LOCATION})) + download_cpm() +else() + # resume download if it previously failed + file(READ ${CPM_DOWNLOAD_LOCATION} check) + if("${check}" STREQUAL "") + download_cpm() + endif() endif() include(${CPM_DOWNLOAD_LOCATION}) From f0b5bdb1f5c638c7c4c957d626dc9a3460a452e5 Mon Sep 17 00:00:00 2001 From: Long Deng <37360259+ldeng-ustc@users.noreply.github.com> Date: Sun, 5 Mar 2023 21:06:43 +0800 Subject: [PATCH 02/10] Fix inconsistent fmt version (#167) fmt version is still 8.1.1 in `DEPENDENCIES` of `packageProject`, update it to 9.1.0 --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 8e686d9..c2d81e0 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -74,5 +74,5 @@ packageProject( INCLUDE_DESTINATION include/${PROJECT_NAME}-${PROJECT_VERSION} VERSION_HEADER "${VERSION_HEADER_LOCATION}" COMPATIBILITY SameMajorVersion - DEPENDENCIES "fmt 8.1.1" + DEPENDENCIES "fmt 9.1.0" ) From 776d4f36be8fc6e855179405f9f75e78c38955e4 Mon Sep 17 00:00:00 2001 From: Tobias Schmidl Date: Mon, 18 Sep 2023 16:20:20 +0200 Subject: [PATCH 03/10] Added a download status (#171) * bump the version of CPM to 0.38.1 * feature: added CPM download status This is very useful in shaky network solutions. We want both a success and a failure message, to determine if the download was successful. * feature: compare CPM against a given checksum This is more comprehensive than just comparing against an empty file. * bump the version of Ccache.cmake to 1.2.4 * bump the version of StableCoder/cmake-scripts to 23.04 * update to use new get_cpm.cmake script --------- Co-authored-by: Lars Melchior --- cmake/CPM.cmake | 28 ++++++++++------------------ cmake/tools.cmake | 4 ++-- 2 files changed, 12 insertions(+), 20 deletions(-) diff --git a/cmake/CPM.cmake b/cmake/CPM.cmake index e9674a7..a786712 100644 --- a/cmake/CPM.cmake +++ b/cmake/CPM.cmake @@ -1,4 +1,9 @@ -set(CPM_DOWNLOAD_VERSION 0.37.0) +# SPDX-License-Identifier: MIT +# +# SPDX-FileCopyrightText: Copyright (c) 2019-2023 Lars Melchior and contributors + +set(CPM_DOWNLOAD_VERSION 0.38.5) +set(CPM_HASH_SUM "192aa0ccdc57dfe75bd9e4b176bf7fb5692fd2b3e3f7b09c74856fc39572b31c") if(CPM_SOURCE_CACHE) set(CPM_DOWNLOAD_LOCATION "${CPM_SOURCE_CACHE}/cpm/CPM_${CPM_DOWNLOAD_VERSION}.cmake") @@ -11,22 +16,9 @@ endif() # Expand relative path. This is important if the provided path contains a tilde (~) get_filename_component(CPM_DOWNLOAD_LOCATION ${CPM_DOWNLOAD_LOCATION} ABSOLUTE) -function(download_cpm) - message(STATUS "Downloading CPM.cmake to ${CPM_DOWNLOAD_LOCATION}") - file(DOWNLOAD - https://github.com/cpm-cmake/CPM.cmake/releases/download/v${CPM_DOWNLOAD_VERSION}/CPM.cmake - ${CPM_DOWNLOAD_LOCATION} - ) -endfunction() - -if(NOT (EXISTS ${CPM_DOWNLOAD_LOCATION})) - download_cpm() -else() - # resume download if it previously failed - file(READ ${CPM_DOWNLOAD_LOCATION} check) - if("${check}" STREQUAL "") - download_cpm() - endif() -endif() +file(DOWNLOAD + https://github.com/cpm-cmake/CPM.cmake/releases/download/v${CPM_DOWNLOAD_VERSION}/CPM.cmake + ${CPM_DOWNLOAD_LOCATION} EXPECTED_HASH SHA256=${CPM_HASH_SUM} +) include(${CPM_DOWNLOAD_LOCATION}) diff --git a/cmake/tools.cmake b/cmake/tools.cmake index 2364da9..ece09c0 100644 --- a/cmake/tools.cmake +++ b/cmake/tools.cmake @@ -11,7 +11,7 @@ include(${CMAKE_CURRENT_LIST_DIR}/CPM.cmake) # enables sanitizers support using the the `USE_SANITIZER` flag available values are: Address, # Memory, MemoryWithOrigins, Undefined, Thread, Leak, 'Address;Undefined' if(USE_SANITIZER OR USE_STATIC_ANALYZER) - CPMAddPackage("gh:StableCoder/cmake-scripts#1f822d1fc87c8d7720c074cde8a278b44963c354") + CPMAddPackage("gh:StableCoder/cmake-scripts@23.04") if(USE_SANITIZER) include(${cmake-scripts_SOURCE_DIR}/sanitizers.cmake) @@ -62,5 +62,5 @@ endif() # enables CCACHE support through the USE_CCACHE flag possible values are: YES, NO or equivalent if(USE_CCACHE) - CPMAddPackage("gh:TheLartians/Ccache.cmake@1.2.3") + CPMAddPackage("gh:TheLartians/Ccache.cmake@1.2.4") endif() From 57d0b4dfc8db967030e0760ddd2b37a3faaf4870 Mon Sep 17 00:00:00 2001 From: Krishna Parmar <99113843+kparmar09@users.noreply.github.com> Date: Sun, 19 Nov 2023 16:49:51 +0530 Subject: [PATCH 04/10] Update about.dox (#183) --- documentation/pages/about.dox | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/documentation/pages/about.dox b/documentation/pages/about.dox index 8ca02c0..59fc18f 100644 --- a/documentation/pages/about.dox +++ b/documentation/pages/about.dox @@ -1,5 +1,5 @@ /** @page about About @section doc ModernCppStarter Documentation - This is the auto-generated documentation for the initial project of the ModernCppStater. + This is the auto-generated documentation for the initial project of the ModernCppStarter. It shows how we can use Doxygen to automatically build a browsable documentation for your projects. */ From 9f4867aa5e517368dfa8b82caee9c87c977948db Mon Sep 17 00:00:00 2001 From: Ian <111059524+zen-is@users.noreply.github.com> Date: Sun, 7 Apr 2024 13:32:20 -0400 Subject: [PATCH 05/10] Upgrade fmt version from 9.1.0 to 10.2.1 (#185) * Bump fmt 9.1.0 to 10.2.1 * trigger CI --------- Co-authored-by: Lars Melchior --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index c2d81e0..84f15ec 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -28,7 +28,7 @@ CPMAddPackage("gh:TheLartians/PackageProject.cmake@1.8.0") CPMAddPackage( NAME fmt - GIT_TAG 9.1.0 + GIT_TAG 10.2.1 GITHUB_REPOSITORY fmtlib/fmt OPTIONS "FMT_INSTALL YES" # create an installable target ) From 74fd5a2ff86090cc95879de5f8cb15907c7ca08c Mon Sep 17 00:00:00 2001 From: Volodymyr <58738099+Gerodote@users.noreply.github.com> Date: Sun, 21 Apr 2024 22:40:54 +0000 Subject: [PATCH 06/10] update StableCoder/cmake-scripts version (#187) additional info: https://github.com/StableCoder/cmake-scripts/releases https://github.com/StableCoder/cmake-scripts/issues/50 --- cmake/tools.cmake | 16 ++++++++++++---- 1 file changed, 12 insertions(+), 4 deletions(-) diff --git a/cmake/tools.cmake b/cmake/tools.cmake index ece09c0..e884c36 100644 --- a/cmake/tools.cmake +++ b/cmake/tools.cmake @@ -11,7 +11,7 @@ include(${CMAKE_CURRENT_LIST_DIR}/CPM.cmake) # enables sanitizers support using the the `USE_SANITIZER` flag available values are: Address, # Memory, MemoryWithOrigins, Undefined, Thread, Leak, 'Address;Undefined' if(USE_SANITIZER OR USE_STATIC_ANALYZER) - CPMAddPackage("gh:StableCoder/cmake-scripts@23.04") + CPMAddPackage("gh:StableCoder/cmake-scripts#24.04") if(USE_SANITIZER) include(${cmake-scripts_SOURCE_DIR}/sanitizers.cmake) @@ -54,9 +54,17 @@ if(USE_SANITIZER OR USE_STATIC_ANALYZER) include(${cmake-scripts_SOURCE_DIR}/tools.cmake) - clang_tidy(${CLANG_TIDY_ARGS}) - include_what_you_use(${IWYU_ARGS}) - cppcheck(${CPPCHECK_ARGS}) + if(${CLANG_TIDY}) + clang_tidy(${CLANG_TIDY_ARGS}) + endif() + + if(${IWYU}) + include_what_you_use(${IWYU_ARGS}) + endif() + + if(${CPPCHECK}) + cppcheck(${CPPCHECK_ARGS}) + endif() endif() endif() From e6920f7c1227dec99015e118386ac918ee12622b Mon Sep 17 00:00:00 2001 From: PaulXiCao <25491255+PaulXiCao@users.noreply.github.com> Date: Fri, 7 Jun 2024 18:32:16 +0200 Subject: [PATCH 07/10] Update CPM.cmake to version 0.39.0 (#189) --- cmake/CPM.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmake/CPM.cmake b/cmake/CPM.cmake index a786712..d0fd0e8 100644 --- a/cmake/CPM.cmake +++ b/cmake/CPM.cmake @@ -2,8 +2,8 @@ # # SPDX-FileCopyrightText: Copyright (c) 2019-2023 Lars Melchior and contributors -set(CPM_DOWNLOAD_VERSION 0.38.5) -set(CPM_HASH_SUM "192aa0ccdc57dfe75bd9e4b176bf7fb5692fd2b3e3f7b09c74856fc39572b31c") +set(CPM_DOWNLOAD_VERSION 0.39.0) +set(CPM_HASH_SUM "66639bcac9dd2907b2918de466783554c1334446b9874e90d38e3778d404c2ef") if(CPM_SOURCE_CACHE) set(CPM_DOWNLOAD_LOCATION "${CPM_SOURCE_CACHE}/cpm/CPM_${CPM_DOWNLOAD_VERSION}.cmake") From cc129789319386928df480aaf8a9e655941d6be3 Mon Sep 17 00:00:00 2001 From: sguruswamy-more <155405643+sguruswamy-more@users.noreply.github.com> Date: Fri, 18 Oct 2024 12:11:21 -0700 Subject: [PATCH 08/10] Updated CPM to 0.40.2 (#193) --- cmake/CPM.cmake | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmake/CPM.cmake b/cmake/CPM.cmake index d0fd0e8..baf2d8c 100644 --- a/cmake/CPM.cmake +++ b/cmake/CPM.cmake @@ -2,8 +2,8 @@ # # SPDX-FileCopyrightText: Copyright (c) 2019-2023 Lars Melchior and contributors -set(CPM_DOWNLOAD_VERSION 0.39.0) -set(CPM_HASH_SUM "66639bcac9dd2907b2918de466783554c1334446b9874e90d38e3778d404c2ef") +set(CPM_DOWNLOAD_VERSION 0.40.2) +set(CPM_HASH_SUM "c8cdc32c03816538ce22781ed72964dc864b2a34a310d3b7104812a5ca2d835d") if(CPM_SOURCE_CACHE) set(CPM_DOWNLOAD_LOCATION "${CPM_SOURCE_CACHE}/cpm/CPM_${CPM_DOWNLOAD_VERSION}.cmake") From 5115efe66a630f1b25fe51742a7a484e08d0a365 Mon Sep 17 00:00:00 2001 From: Max Bretschneider <54221876+brtmax@users.noreply.github.com> Date: Sun, 22 Dec 2024 11:47:15 +0100 Subject: [PATCH 09/10] Fix fmt dependency version mismatch in CMakeLists.txt (#194) * Fix fmt dependency version mismatch in CMakeLists.txt * trigger ci? --------- Co-authored-by: Lars Melchior --- CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 84f15ec..31cf517 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -74,5 +74,5 @@ packageProject( INCLUDE_DESTINATION include/${PROJECT_NAME}-${PROJECT_VERSION} VERSION_HEADER "${VERSION_HEADER_LOCATION}" COMPATIBILITY SameMajorVersion - DEPENDENCIES "fmt 9.1.0" + DEPENDENCIES "fmt 10.2.1" ) From 12cf5de1a8473c9b3a01a07f2ab46814dbecd9aa Mon Sep 17 00:00:00 2001 From: Ian Torres Date: Wed, 12 Mar 2025 15:30:20 -0300 Subject: [PATCH 10/10] Fix GitHub pages (#191) * Fix GitHub pages As `peaceiris/actions-gh-pages` README describes, the `permissions / contents / write` definition is required. In other hand, without that, the step will fail. Also a jump to the version 4 is recommended. Basically because i did a test and previous version, as-is doesn't work. * Space for testing * switch to ubunto for documentation workflow * build test without publish * try again * add tag restriction and pages back --------- Co-authored-by: Lars Melchior Co-authored-by: Lars Melchior --- .github/workflows/documentation.yaml | 18 +++++++++++++----- 1 file changed, 13 insertions(+), 5 deletions(-) diff --git a/.github/workflows/documentation.yaml b/.github/workflows/documentation.yaml index 9e90bf5..454d91b 100644 --- a/.github/workflows/documentation.yaml +++ b/.github/workflows/documentation.yaml @@ -8,10 +8,14 @@ on: env: CPM_SOURCE_CACHE: ${{ github.workspace }}/cpm_modules +permissions: + contents: write + + jobs: build: name: Build and publish documentation - runs-on: macos-latest + runs-on: ubuntu-latest steps: - uses: actions/checkout@v3 @@ -20,18 +24,22 @@ jobs: path: "**/cpm_modules" key: ${{ github.workflow }}-cpm-modules-${{ hashFiles('**/CMakeLists.txt', '**/*.cmake') }} - - name: Install dependencies + - name: Install python dependencies run: | - brew install doxygen - pip3 install jinja2 Pygments + pip3 install jinja2==3.1.6 Pygments==2.19.1 + - name: Install Doxygen + uses: ssciwr/doxygen-install@v1 + with: + version: "1.13.2" + - name: Build run: | cmake -Sdocumentation -Bbuild cmake --build build --target GenerateDocs - name: Publish - uses: peaceiris/actions-gh-pages@v3 + uses: peaceiris/actions-gh-pages@v4 with: github_token: ${{ secrets.GITHUB_TOKEN }} publish_dir: ./build/doxygen/html