2
0
mirror of https://github.com/kotatogram/kotatogram-desktop synced 2025-08-31 14:45:14 +00:00

Add a cheat code to install launcher on Linux

This commit is contained in:
Ilya Fedin
2020-11-01 14:55:19 +04:00
committed by John Preston
parent 0881e5b20d
commit 204a08df14
3 changed files with 12 additions and 3 deletions

View File

@@ -1129,13 +1129,15 @@ void start() {
void finish() {
}
void InstallLauncher() {
void InstallLauncher(bool force) {
static const auto DisabledByEnv = qEnvironmentVariableIsSet(
"TDESKTOP_DISABLE_DESKTOP_FILE_GENERATION");
// don't update desktop file for alpha version or if updater is disabled
if (cAlphaVersion() || Core::UpdaterDisabled() || DisabledByEnv)
if ((cAlphaVersion() || Core::UpdaterDisabled() || DisabledByEnv)
&& !force) {
return;
}
const auto applicationsPath = QStandardPaths::writableLocation(
QStandardPaths::ApplicationsLocation) + '/';

View File

@@ -41,7 +41,7 @@ QString GetIconName();
inline void IgnoreApplicationActivationRightNow() {
}
void InstallLauncher();
void InstallLauncher(bool force = false);
} // namespace Platform