diff --git a/YACReaderLibraryServer/main.cpp b/YACReaderLibraryServer/main.cpp index 0437bd42..084f3850 100644 --- a/YACReaderLibraryServer/main.cpp +++ b/YACReaderLibraryServer/main.cpp @@ -127,8 +127,13 @@ int main(int argc, char **argv) #endif app.installTranslator(&translator); + auto settingsPath = YACReader::getSettingsPath() + "/" + QCoreApplication::applicationName() + ".ini"; + QCommandLineParser parser; - parser.setApplicationDescription(QCoreApplication::tr("\nYACReaderLibraryServer is the headless (no gui) version of YACReaderLibrary")); + parser.setApplicationDescription(QString(QCoreApplication::tr("\nYACReaderLibraryServer is the headless (no gui) version of YACReaderLibrary.\n\n" + "This appplication support persisten settings, to set them up edit this file %1\n" + "To learn about the available settings please check the documentation at https://raw.githubusercontent.com/YACReader/yacreader/develop/YACReaderLibraryServer/SETTINGS_README.md")) + .arg(settingsPath)); parser.addHelpOption(); const QCommandLineOption versionOption = parser.addVersionOption(); parser.addPositionalArgument("command", "The command to execute. [start, create-library, update-library, add-library, remove-library, list-libraries, set-port]"); @@ -146,7 +151,7 @@ int main(int argc, char **argv) return 0; } - QSettings *settings = new QSettings(YACReader::getSettingsPath() + "/" + QCoreApplication::applicationName() + ".ini", QSettings::IniFormat); + QSettings *settings = new QSettings(settingsPath, QSettings::IniFormat); settings->beginGroup("libraryConfig"); if (command == "start") {