Skip to content

Commit

Permalink
Use DEV_BUILD define instead of env
Browse files Browse the repository at this point in the history
  • Loading branch information
dimkanovikov committed Apr 24, 2022
1 parent a4e1bea commit 1d102ed
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/build_starc_app.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,12 +51,11 @@ jobs:
shell: bash
run: |
cd src
qmake starc.pro
qmake starc.pro DEFINES+="DEV_BUILD=$DEV_BUILD"
- name: Build
shell: bash
run: |
export DEV_BUILD=${{env.DEV_BUILD}}
cd src
make -j$(nproc)
Expand Down
9 changes: 6 additions & 3 deletions src/core/management_layer/application_manager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1414,9 +1414,12 @@ ApplicationManager::ApplicationManager(QObject* _parent)


QString applicationVersion = "0.1.5";
if (auto devBuild = qgetenv("DEV_BUILD"); !devBuild.isEmpty()) {
applicationVersion += QString(" dev %1").arg(devBuild.constData());
}
#if defined(DEV_BUILD) && DEV_BUILD > 0
// if (auto devBuild = qgetenv("env.DEV_BUILD"); !devBuild.isEmpty() && devBuild.toInt() > 0)
// {
applicationVersion += QString(" dev %1").arg(DEV_BUILD);
// }
#endif
QApplication::setApplicationVersion(applicationVersion);
QApplication::setStyle(new ApplicationStyle(QStyleFactory::create("Fusion")));

Expand Down

0 comments on commit 1d102ed

Please sign in to comment.