Skip to content

Commit

Permalink
Remove deprecated option --confdir
Browse files Browse the repository at this point in the history
This was meant to be used before roaming profiles were supported on
Windows.

Fixes: #11246
  • Loading branch information
erikjv committed Oct 27, 2023
1 parent 468099d commit 7f99f88
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 8 deletions.
8 changes: 0 additions & 8 deletions src/gui/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -127,7 +127,6 @@ CommandLineOptions parseOptions(const QStringList &arguments)
auto logDirOption = addOption({QStringLiteral("logdir"), QStringLiteral("Write each sync log output in a new file in folder."), QStringLiteral("name")});
auto logFlushOption = addOption({QStringLiteral("logflush"), QStringLiteral("Flush the log file after every write.")});
auto logDebugOption = addOption({QStringLiteral("logdebug"), QStringLiteral("Output debug-level messages in the log.")});
auto confDirOption = addOption({QStringLiteral("confdir"), QStringLiteral("Use the given configuration folder."), QStringLiteral("dirname")});
auto debugOption = addOption({QStringLiteral("debug"), QStringLiteral("Enable debug mode.")});
addOption({QStringLiteral("cmd"), QStringLiteral("Forward all arguments to the cmd client. This argument must be the first.")});

Expand Down Expand Up @@ -160,13 +159,6 @@ CommandLineOptions parseOptions(const QStringList &arguments)
if (parser.isSet(logDebugOption)) {
out.logDebug = true;
}
if (parser.isSet(confDirOption)) {
const auto confDir = parser.value(confDirOption);
if (!ConfigFile::setConfDir(confDir)) {
displayHelpText(QStringLiteral("Invalid path passed to --confdir"));
std::exit(1);
}
}
if (parser.isSet(debugOption)) {
out.logDebug = true;
out.debugMode = true;
Expand Down
1 change: 1 addition & 0 deletions src/libsync/configfile.h
Original file line number Diff line number Diff line change
Expand Up @@ -150,6 +150,7 @@ class OWNCLOUDSYNC_EXPORT ConfigFile
bool moveToTrash() const;
void setMoveToTrash(bool);

/// Used for testing, so we do not change the user's config file.
static bool setConfDir(const QString &value);

bool optionalDesktopNotifications() const;
Expand Down

0 comments on commit 7f99f88

Please sign in to comment.