Skip to content

Commit e7f108c

Browse files
committed
Exemplar updates since 2026-04-05
Bump infra-workflows from 1.5.0 to 1.5.1 in all GitHub Actions workflow files. Bump infra-workflows version from 1.5.1 to 1.5.2 in all GitHub Actions workflow files (fixes deprecated Node.js v20 actions). Add build telemetry support: include BuildTelemetryConfig.cmake and call configure_build_telemetry() in CMakeLists.txt; update infra to commit dfdb103 (adds BuildTelemetry.cmake, BuildTelemetryConfig.cmake, telemetry.sh; updates beman-install-library.cmake, Config.cmake.in, use-fetch-content.cmake, .pre-commit-config.yaml, README.md). Bump infra-workflows version from 1.5.2 to 1.5.3 in all GitHub Actions workflow files. Remove explicit args from beman-tidy pre-commit hook to use defaults instead of ["." "--verbose" "--require-all"]. Split Clang 18/17 CI matrix entry into separate entries, restoring Clang 18 + libstdc++ + c++23 test (exemplar 26982cd907aa137d046ed536dd1b2db4fbc16f03) b1e7015b1bd62ce5b20009cec7ee98ba5c783818: Remove beman-tidy pre-commit hook from .pre-commit-config.yaml
1 parent d76e27c commit e7f108c

16 files changed

Lines changed: 276 additions & 65 deletions

.exemplar_version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
f5759898e1ac110fc070791b83267f13c9b50b4c
1+
b1e7015b1bd62ce5b20009cec7ee98ba5c783818

.github/workflows/ci_tests.yml

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,10 @@ on:
1313

1414
jobs:
1515
beman-submodule-check:
16-
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-submodule-check.yml@1.5.0
16+
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-submodule-check.yml@1.5.3
1717

1818
preset-test:
19-
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-preset-test.yml@1.5.0
19+
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-preset-test.yml@1.5.3
2020
with:
2121
matrix_config: >
2222
[
@@ -31,7 +31,7 @@ jobs:
3131
]
3232
3333
build-and-test:
34-
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-build-and-test.yml@1.5.0
34+
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-build-and-test.yml@1.5.3
3535
with:
3636
matrix_config: >
3737
{
@@ -105,7 +105,17 @@ jobs:
105105
}
106106
]
107107
},
108-
{ "versions": ["18", "17"],
108+
{ "versions": ["18"],
109+
"tests": [
110+
{ "cxxversions": ["c++26", "c++23", "c++20"],
111+
"tests": [{"stdlibs": ["libc++"], "tests": ["Release.Default"]}]
112+
},
113+
{ "cxxversions": ["c++23", "c++20"],
114+
"tests": [{"stdlibs": ["libstdc++"], "tests": ["Release.Default"]}]
115+
}
116+
]
117+
},
118+
{ "versions": ["17"],
109119
"tests": [
110120
{ "cxxversions": ["c++26", "c++23", "c++20"],
111121
"tests": [{"stdlibs": ["libc++"], "tests": ["Release.Default"]}]
@@ -143,4 +153,4 @@ jobs:
143153
create-issue-when-fault:
144154
needs: [preset-test, build-and-test]
145155
if: failure() && github.event_name == 'schedule'
146-
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-create-issue-when-fault.yml@1.5.0
156+
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-create-issue-when-fault.yml@1.5.3

.github/workflows/pre-commit-check.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,4 +16,4 @@ permissions:
1616

1717
jobs:
1818
pre-commit:
19-
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-pre-commit.yml@1.5.0
19+
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-pre-commit.yml@1.5.3

.github/workflows/pre-commit-update.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ on:
99

1010
jobs:
1111
auto-update-pre-commit:
12-
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-update-pre-commit.yml@1.5.0
12+
uses: bemanproject/infra-workflows/.github/workflows/reusable-beman-update-pre-commit.yml@1.5.3
1313
secrets:
1414
APP_ID: ${{ secrets.AUTO_PR_BOT_APP_ID }}
1515
PRIVATE_KEY: ${{ secrets.AUTO_PR_BOT_PRIVATE_KEY }}

.pre-commit-config.yaml

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -39,10 +39,4 @@ repos:
3939
hooks:
4040
- id: codespell
4141

42-
- repo: https://github.com/bemanproject/beman-tidy
43-
rev: v0.3.1
44-
hooks:
45-
- id: beman-tidy
46-
args: [".", "--verbose", "--require-all"]
47-
4842
exclude: 'cookiecutter/|infra/'

CMakeLists.txt

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,9 @@ option(
2424
${PROJECT_IS_TOP_LEVEL}
2525
)
2626

27-
# for find of beman-install-library
27+
# for find of beman_install_library and configure_build_telemetry
2828
include(infra/cmake/beman-install-library.cmake)
29+
include(infra/cmake/BuildTelemetryConfig.cmake)
2930

3031
add_library(beman.timed_lock_alg INTERFACE)
3132
add_library(beman::timed_lock_alg ALIAS beman.timed_lock_alg)
@@ -43,6 +44,7 @@ set_target_properties(
4344
add_subdirectory(include/beman/timed_lock_alg)
4445

4546
beman_install_library(beman.timed_lock_alg TARGETS beman.timed_lock_alg)
47+
configure_build_telemetry()
4648

4749
if(BEMAN_TIMED_LOCK_ALG_BUILD_TESTS)
4850
enable_testing()

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -68,8 +68,10 @@ You can disable building tests by setting CMake option `BEMAN_TIMED_LOCK_ALG_BUI
6868
| GCC | 15-13 | C++26-C++20 | libstdc++ |
6969
| GCC | 12-11 | C++23, C++20 | libstdc++ |
7070
| Clang | 22-19 | C++26-C++20 | libstdc++, libc++ |
71-
| Clang | 18-17 | C++26-C++20 | libc++ |
72-
| Clang | 18-17 | C++20 | libstdc++ |
71+
| Clang | 18 | C++26-C++20 | libc++ |
72+
| Clang | 18 | C++23-C++20 | libstdc++ |
73+
| Clang | 17 | C++26-C++20 | libc++ |
74+
| Clang | 17 | C++20 | libstdc++ |
7375
| AppleClang | latest | C++26-C++20 | libc++ |
7476
| MSVC | latest | C++23 | MSVC STL |
7577

infra/.beman_submodule

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
[beman_submodule]
22
remote=https://github.com/bemanproject/infra.git
3-
commit_hash=54dcdad8b661a405a6ac06453f0f06da5d30ba5c
3+
commit_hash=dfdb103b5fc9cccd3424c377130e318466f1dd89

infra/.pre-commit-config.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,13 +8,13 @@ repos:
88
- id: check-added-large-files
99

1010
- repo: https://github.com/codespell-project/codespell
11-
rev: v2.4.1
11+
rev: v2.4.2
1212
hooks:
1313
- id: codespell
1414

1515
# CMake linting and formatting
16-
- repo: https://github.com/BlankSpruce/gersemi
17-
rev: 0.22.3
16+
- repo: https://github.com/BlankSpruce/gersemi-pre-commit
17+
rev: 0.27.2
1818
hooks:
1919
- id: gersemi
2020
name: CMake linting

infra/README.md

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,3 +52,37 @@ Some options for the project and target will also be supported:
5252
* `BEMAN_INSTALL_CONFIG_FILE_PACKAGES` - a list of package names (e.g., `beman.something`) for which to install the config file
5353
(default: all packages)
5454
* `<BEMAN_NAME>_INSTALL_CONFIG_FILE_PACKAGE` - a per-project option to enable/disable config file installation (default: `ON` if the project is top-level, `OFF` otherwise). For instance for `beman.something`, the option would be `BEMAN_SOMETHING_INSTALL_CONFIG_FILE_PACKAGE`.
55+
56+
# BuildTelemetry
57+
58+
The cmake modules in this library provide access to CMake instrumentation data in Google Trace format which is visualizable with chrome://tracing and https://ui.perfetto.dev.
59+
60+
Telemetry may be enabled in several ways:
61+
62+
## `include`
63+
64+
```cmake
65+
include (infra/cmake/BuildTelemetry.cmake)
66+
configure_build_telemetry()
67+
```
68+
69+
## `find_package`
70+
71+
```cmake
72+
find_package(BuildTelemetry)
73+
configure_build_telemetry()
74+
```
75+
76+
as long as [BuildTelemetryConfig.cmake](./cmake/BuildTelemetryConfig.cmake) is in your module path.
77+
78+
## `CMAKE_PROJECT_TOP_LEVEL_INCLUDES`
79+
A non-invasive way to inject this telemetry into a CMake build you do not want to modify.
80+
Add:
81+
```sh
82+
-DCMAKE_PROJECT_TOP_LEVEL_INCLUDES=infra/cmake/BuildTelemetry.cmake
83+
```
84+
To the cmake invocation.
85+
86+
In any form, CMake will call `telemetry.sh` which will copy the trace data in json format into a `.trace` subdirectory within the build directory.
87+
88+
Multiple calls to `configure_build_telemetry` will only configure the callback hooks once, so it is safe to enable multiple times, including by TOP_LEVEL_INCLUDE.

0 commit comments

Comments
 (0)