hi, to get version of MY app while running I'm creating a variable : in .spec, add / change : %qtc_qmake5 \ VERSION=%{version}
in .pro add : DEFINES += APP_VERSION=\"\\\"$${VERSION}\\\"\" then in cpp, set version to the QGuiApplication : app->setApplicationVersion(QString(APP_VERSION)); from qml : Qt.application.version from cpp : QCoreApplication::applicationVersion(); Note, when you change version number, you need to to a full clean/rebuild 2017-09-03 8:59 GMT+02:00 Dylan Van Assche via Devel < devel@lists.sailfishos.org>: > Hi, > > I'm trying to update the application version everytime I change it in the > .SPEC file but it seems that there's no Harbour allowed API is available to > querry the application version when running? > My last help would be parsing a "pkcon search name <app>" but if there's a > better method available, that would be great. > > Kind regards, > Dylan Van Assche > > > > > _______________________________________________ > SailfishOS.org Devel mailing list > To unsubscribe, please send a mail to devel-unsubscribe@lists. > sailfishos.org >
_______________________________________________ SailfishOS.org Devel mailing list To unsubscribe, please send a mail to devel-unsubscr...@lists.sailfishos.org