Skip to content

Commit

Permalink
feat: Support x.y.z project version numbers
Browse files Browse the repository at this point in the history
  • Loading branch information
fuzzypixelz committed Apr 10, 2024
1 parent f6a73c0 commit afd74cc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,10 @@ declare_cache_var(ZENOHC_LIB_STATIC FALSE BOOL "Alias zenohc::lib target to zeno
#
set(project_version "${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}.${PROJECT_VERSION_PATCH}")
if(NOT PROJECT_VERSION_TWEAK)
set(project_version "${project_version}")
elseif(PROJECT_VERSION_TWEAK EQUAL 0)
set(project_version "${project_version}-dev")
elseif(PROJECT_VERSION_TWEAK EQUAL 1)
set(project_version "${project_version}-rc")
elseif(PROJECT_VERSION_TWEAK LESS 255)
elseif(PROJECT_VERSION_TWEAK GREATER 1)
set(project_version "${project_version}-rc.${PROJECT_VERSION_TWEAK}")
endif()
status_print(project_version)
Expand Down

0 comments on commit afd74cc

Please sign in to comment.