mirror of
https://github.com/OPM/ResInsight.git
synced 2026-08-27 13:47:12 -05:00
Fix time stamp for build
This commit is contained in:
@@ -37,4 +37,6 @@
|
||||
|
||||
#define RESINSIGHT_GIT_HASH "@RESINSIGHT_GIT_HASH@"
|
||||
|
||||
#define RESINSIGHT_BUILD_SYSTEM_ID "@RESINSIGHT_BUILD_SYSTEM_ID@"
|
||||
#define RESINSIGHT_BUILD_SYSTEM_ID "@RESINSIGHT_BUILD_SYSTEM_ID@"
|
||||
|
||||
#define RESINSIGHT_BUILD_DATE "@RESINSIGHT_BUILD_DATE@"
|
||||
|
||||
@@ -172,8 +172,8 @@ void RicHelpAboutFeature::onActionTriggered( bool isChecked )
|
||||
}
|
||||
|
||||
dlg.addVersionEntry( " ", "" );
|
||||
QString nowDate = QDateTime::currentDateTime().toString( "yyyy-MMM-dd" );
|
||||
dlg.addVersionEntry( "", QString( "Build date: " ) + nowDate );
|
||||
QString buildDate = RESINSIGHT_BUILD_DATE;
|
||||
dlg.addVersionEntry( "", QString( "Build date: " ) + buildDate );
|
||||
dlg.addVersionEntry( "", "SHA " + QString( RESINSIGHT_GIT_HASH ) );
|
||||
|
||||
dlg.create();
|
||||
|
||||
@@ -422,6 +422,16 @@ if(GIT_FOUND AND EXISTS "${PROJECT_SOURCE_DIR}/.git")
|
||||
endif()
|
||||
endif()
|
||||
|
||||
if(UNIX)
|
||||
execute_process(
|
||||
COMMAND date "+%Y-%m-%d %H:%M:%S"
|
||||
OUTPUT_VARIABLE RESINSIGHT_BUILD_DATE
|
||||
OUTPUT_STRIP_TRAILING_WHITESPACE
|
||||
)
|
||||
else()
|
||||
string(TIMESTAMP RESINSIGHT_BUILD_DATE "%Y-%m-%d %H:%M:%S")
|
||||
endif()
|
||||
|
||||
# ##############################################################################
|
||||
# OpenVDS seismic file access
|
||||
# ##############################################################################
|
||||
|
||||
Reference in New Issue
Block a user