Commit 6a4ad9e5 authored by Thiago Santini's avatar Thiago Santini

Improves and updates metadata

parent 62da509f
VERSION = 1.2
QMAKE_TARGET_COMPANY = "University of Tuebingen"
QMAKE_TARGET_PRODUCT = "EyeRecToo"
QMAKE_TARGET_DESCRIPTION = ""
QMAKE_TARGET_COPYRIGHT = "Thiago Santini"
QT += core gui multimedia
greaterThan(QT_MAJOR_VERSION, 4): QT += widgets
......@@ -176,8 +182,12 @@ unix{
}
system("git --version"):{
GIT_VERSION=$$system(git --git-dir $${TOP}/../.git --work-tree $$TOP describe --always --tags)
DEFINES += GIT_VERSION=\\\"$$GIT_VERSION\\\"
GIT_BRANCH=$$system(git rev-parse --abbrev-ref HEAD)
GIT_COMMIT_HASH=$$system(git rev-parse --short HEAD)
} else {
GIT_VERSION=""
GIT_BRANCH="unknown"
GIT_COMMIT_HASH="unknown"
}
DEFINES += VERSION=\\\"$$VERSION\\\"
DEFINES += GIT_BRANCH=\\\"$$GIT_BRANCH\\\"
DEFINES += GIT_COMMIT_HASH=\\\"$$GIT_COMMIT_HASH\\\"
......@@ -25,7 +25,7 @@ MainWindow::MainWindow(QWidget *parent) :
settings = new QSettings(gCfgDir + "/" + "EyeRecToo", QSettings::IniFormat);
cfg.load(settings);
setWindowTitle(QString("EyeRecToo v%1").arg(GIT_VERSION));
ui->statusBar->showMessage( QString("This is version %1").arg(VERSION) );
setWindowIcon(QIcon(":/icons/EyeRecToo.png"));
if (!cfg.workingDirectory.isEmpty())
......@@ -546,10 +546,11 @@ void MainWindow::showReferencesDialog()
void MainWindow::showAboutDialog()
{
QString msg = QString("EyeRecToo v%1<br><br>").arg(GIT_VERSION);
QString msg = QString("EyeRecToo v%1<br><br>").arg(VERSION);
msg.append("Contact: <a href=\"mailto:thiago.santini@uni-tuebingen.de?Subject=[EyeRecToo] Contact\" target=\"_top\">thiago.santini@uni-tuebingen.de</a><br><br>");
msg.append("Copyright &copy; 2017 University of Tübingen");
QMessageBox::about(this, "About", msg);
msg.append("Copyright &copy; 2018 Thiago Santini / University of Tübingen<br><br>");
msg.append( QString("Build: %1 %2").arg(GIT_BRANCH).arg(GIT_COMMIT_HASH) );
QMessageBox::about(this, "About", msg);
}
void MainWindow::setupWidget(ERWidget *widget, QSettings* settings, QPushButton *button)
......
......@@ -64,7 +64,7 @@ void logInitBanner()
QDateTime utc = QDateTime::currentDateTimeUtc();
qDebug() << "Starting\n######################################################################"
<< "\n# " << QString("EyeRecToo v%1").arg(GIT_VERSION)
<< "\n# " << QString("EyeRecToo v%1").arg(VERSION)
<< "\n# UTC: " << utc.toString()
<< "\n# Local: " << utc.toLocalTime().toString()
<< "\n######################################################################";
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment