1
0
mirror of https://github.com/Swordfish90/cool-retro-term.git synced 2025-01-18 12:15:27 +00:00

Use a single version name.

This commit is contained in:
Filippo Scognamiglio 2019-01-17 22:03:25 +01:00
parent 8f0d1023a4
commit b961109623
2 changed files with 5 additions and 2 deletions

View File

@ -74,8 +74,10 @@ int main(int argc, char *argv[])
return 0;
}
QString appVersion("1.1.0");
if (args.contains("-v") || args.contains("--version")) {
qDebug() << "cool-retro-term 1.1.0";
qDebug() << ("cool-retro-term " + appVersion).toStdString().c_str();
return 0;
}
@ -86,6 +88,7 @@ int main(int argc, char *argv[])
}
QVariant command(cmdList.empty() ? QVariant() : cmdList[0]);
QVariant commandArgs(cmdList.size() <= 1 ? QVariant() : QVariant(cmdList.mid(1)));
engine.rootContext()->setContextProperty("appVersion", appVersion);
engine.rootContext()->setContextProperty("defaultCmd", command);
engine.rootContext()->setContextProperty("defaultCmdArgs", commandArgs);

View File

@ -24,7 +24,7 @@ import QtQuick.Controls 1.0
import "utils.js" as Utils
QtObject{
readonly property string version: "1.1.0"
readonly property string version: appVersion
readonly property int profileVersion: 2
// STATIC CONSTANTS ////////////////////////////////////////////////////////