fix: fix the cli option name in qwfassoc

This commit is contained in:
2026-08-18 21:08:22 +08:00
parent 27235c2619
commit b45a5c2760
@@ -89,12 +89,12 @@ int main(int argc, char* argv[]) {
parser.addHelpOption(); parser.addHelpOption();
QCommandLineOption manifestOption( QCommandLineOption manifestOption(
QStringList() << QStringLiteral("c") << QStringLiteral("manifest"), QStringList() << QStringLiteral("m") << QStringLiteral("manifest"),
QCoreApplication::translate(kTranslationContext, QCoreApplication::translate(kTranslationContext,
"Path to the application manifest TOML file."), "Path to the application manifest TOML file."),
QStringLiteral("manifest")); QStringLiteral("manifest"));
QCommandLineOption forOption( QCommandLineOption forOption(
QStringList() << QStringLiteral("f") << QStringLiteral("for"), QStringList() << QStringLiteral("t") << QStringLiteral("target"),
QCoreApplication::translate(kTranslationContext, QCoreApplication::translate(kTranslationContext,
"Target scope: \"user\" or \"system\"."), "Target scope: \"user\" or \"system\"."),
QStringLiteral("scope")); QStringLiteral("scope"));
@@ -111,13 +111,13 @@ int main(int argc, char* argv[]) {
return fatal(nullptr, return fatal(nullptr,
QCoreApplication::translate( QCoreApplication::translate(
kTranslationContext, kTranslationContext,
"The --manifest/-c option is required.")); "The --manifest/-m option is required."));
} }
if (forValue.isEmpty()) { if (forValue.isEmpty()) {
return fatal(nullptr, return fatal(nullptr,
QCoreApplication::translate( QCoreApplication::translate(
kTranslationContext, kTranslationContext,
"The --for/-f option is required.")); "The --target/-t option is required."));
} }
qwfassoc::TargetScope scope; qwfassoc::TargetScope scope;