shared: shared.pro: Add git commit id to build

このコミットが含まれているのは:
Albert S. 2022-05-31 18:42:20 +02:00
コミット db029dd915
2個のファイルの変更7行の追加1行の削除

ファイルの表示

@ -205,5 +205,6 @@ bool Common::isTextFile(QFileInfo fileInfo)
QString Common::versionText()
{
QString commitid = GIT_COMMIT_ID;
return commitid + " built " + __DATE__ + " " + __TIME__;
QString tag = GIT_TAG;
return tag + " (" + commitid + ") built " + __DATE__ + " " + __TIME__;
}

ファイルの表示

@ -16,12 +16,17 @@ CONFIG += c++17
INCLUDEPATH += $$PWD/../sandbox/exile.h/
INCLUDEPATH += /usr/include/poppler/qt5/ /usr/include/quazip5
# The following define makes your compiler emit warnings if you use
# any feature of Qt which has been marked as deprecated (the exact warnings
# depend on your compiler). Please consult the documentation of the
# deprecated API in order to know how to port your code away from it.
DEFINES += QT_DEPRECATED_WARNINGS
DEFINES += GIT_COMMIT_ID="\\\"$(shell git rev-parse --short HEAD)\\\""
DEFINES += GIT_TAG="\\\"$(shell git describe --tags HEAD)\\\""
# You can also make your code fail to compile if you use deprecated APIs.
# In order to do so, uncomment the following line.
# You can also select to disable deprecated APIs only up to a certain version of Qt.