diff options
| author | James Rowe <jroweboy@gmail.com> | 2017-08-03 18:37:03 -0600 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2017-08-03 18:37:03 -0600 |
| commit | 0dc285dcfd1085c7725b7db474266371226de672 (patch) | |
| tree | 1246eca78bc61a5122c12804f3bc70b93245118d /CMakeLists.txt | |
| parent | 035716d57bfc2142779e421ee242efc0d51059f6 (diff) | |
| parent | fb8de8985930bc76d8d39d0ff97f880798d5761a (diff) | |
Merge pull request #2855 from bunnei/telemetry-additional-fields
Telemetry: Add several more useful fields
Diffstat (limited to 'CMakeLists.txt')
| -rw-r--r-- | CMakeLists.txt | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 79d8046d9..ddba04ef9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -295,11 +295,18 @@ function(create_directory_groups) endforeach() endfunction() -# generate git revision information +# Gets a UTC timstamp and sets the provided variable to it +function(get_timestamp _var) + string(TIMESTAMP timestamp UTC) + set(${_var} "${timestamp}" PARENT_SCOPE) +endfunction() + +# generate git/build information include(GetGitRevisionDescription) get_git_head_revision(GIT_REF_SPEC GIT_REV) git_describe(GIT_DESC --always --long --dirty) git_branch_name(GIT_BRANCH) +get_timestamp(BUILD_DATE) enable_testing() add_subdirectory(externals) |
