-
Notifications
You must be signed in to change notification settings - Fork 21
Closed
Labels
Description
The package version is set in 2 places in CMake. In the root CMakeLists.txt (
Lines 9 to 14 in 80a8997
| execute_process( | |
| COMMAND git describe --tags --abbrev=0 --exclude nightly | |
| WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}" | |
| OUTPUT_VARIABLE SCIPP_VERSION | |
| OUTPUT_STRIP_TRAILING_WHITESPACE | |
| ) |
lib/CMakeLists.txt (Lines 92 to 102 in 80a8997
| execute_process( | |
| COMMAND git describe --tag | |
| WORKING_DIRECTORY "${CMAKE_SOURCE_DIR}" | |
| RESULT_VARIABLE HAVE_GIT_VERSION_INFO | |
| OUTPUT_VARIABLE GIT_VERSION_INFO | |
| OUTPUT_STRIP_TRAILING_WHITESPACE | |
| ) | |
| if(${HAVE_GIT_VERSION_INFO} EQUAL 0) | |
| message(STATUS "Got version from Git: ${GIT_VERSION_INFO}") | |
| add_definitions(-DSCIPP_VERSION="${GIT_VERSION_INFO}") | |
| endif() |
The first filters out nightly tags and abbreviates. But the second does not. The second is what how we define
scipp.__version__ in Python.
Why are there 2 separate commands? Should we remove one? In any case, we should probably filter out nightly in both.
Metadata
Metadata
Assignees
Labels
Type
Projects
Status
Done