mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2024-11-21 21:55:38 +00:00
Reading the version directly from the VERSION file
This commit is contained in:
parent
7f0746f14f
commit
9f968d2481
|
@ -2098,13 +2098,20 @@ void GuiMenu::addVersionInfo()
|
|||
#if defined(ANDROID_LITE_RELEASE)
|
||||
const std::string applicationName {"ES-DE LITE"};
|
||||
#else
|
||||
const std::string applicationName {"ES-DE"};
|
||||
const std::string applicationName {"RetroDECK"};
|
||||
#endif
|
||||
|
||||
#if defined(IS_PRERELEASE)
|
||||
mVersion.setText(applicationName + " V" + Utils::String::toUpper(PROGRAM_VERSION_STRING) +
|
||||
" (Built " + __DATE__ + ")");
|
||||
#else
|
||||
std::ifstream file("/app/retrodeck/version");
|
||||
std::string version;
|
||||
std::getline(file, version);
|
||||
file.close();
|
||||
#undef PROGRAM_VERSION_STRING
|
||||
#define PROGRAM_VERSION_STRING version.c_str()
|
||||
std::cout << PROGRAM_VERSION_STRING << std::endl;
|
||||
mVersion.setText(applicationName + " V" + Utils::String::toUpper(PROGRAM_VERSION_STRING));
|
||||
#endif
|
||||
|
||||
|
|
Loading…
Reference in a new issue