We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e0be19d commit c6450e0Copy full SHA for c6450e0
cmake/modules/LibraryVersion.cmake
@@ -8,13 +8,14 @@
8
9
# The current version of the Swift Testing release. For release branches,
10
# remember to remove -dev.
11
-set(SWT_TESTING_LIBRARY_VERSION "6.1.0-dev")
+set(SWT_TESTING_LIBRARY_VERSION "6.1-dev")
12
13
find_package(Git QUIET)
14
if(Git_FOUND)
15
- # Look for a tag (including non-annotated, i.e. commit-specific, ones.)
+ # Get the commit hash corresponding to the current build. Limit length to 15
16
+ # to match `swift --version` output format.
17
execute_process(
- COMMAND ${GIT_EXECUTABLE} describe --tags
18
+ COMMAND ${GIT_EXECUTABLE} rev-parse --short=15 --verify HEAD
19
WORKING_DIRECTORY ${PROJECT_SOURCE_DIR}
20
OUTPUT_VARIABLE GIT_VERSION
21
OUTPUT_STRIP_TRAILING_WHITESPACE
0 commit comments