# HG changeset patch # User Sebastien Jodogne # Date 1786460481 -7200 # Node ID e1cce5515153bd745b7fb260a391f9e5e3795e26 # Parent 667acdc1b2f2dfa66f4b882bab0815a683be4194 multiple paths to configuration files can now be provided diff -r 667acdc1b2f2 -r e1cce5515153 NEWS --- a/NEWS Tue Aug 11 16:56:06 2026 +0200 +++ b/NEWS Tue Aug 11 17:01:21 2026 +0200 @@ -4,6 +4,7 @@ General ------- +* Multiple paths to configuration files can now be provided, instead of a single file or a single folder * Orthanc will now refuse to start if you have "AuthenticationEnabled" and "RemoteAccessAllowed" set to true and have not defined any users in "RegisteredUsers". * New values for "OverwriteInstances" configuration. In previous versions, this configuration diff -r 667acdc1b2f2 -r e1cce5515153 OrthancServer/Sources/OrthancConfiguration.cpp --- a/OrthancServer/Sources/OrthancConfiguration.cpp Tue Aug 11 16:56:06 2026 +0200 +++ b/OrthancServer/Sources/OrthancConfiguration.cpp Tue Aug 11 17:01:21 2026 +0200 @@ -693,8 +693,8 @@ { if (configurationPaths_.size() >= 2) { - LOG(WARNING) << "A plugin has called deprecated OrthancPluginGetConfigurationPath(), the results " - << "are unreliable because multiple configuration path were provided"; + LOG(WARNING) << "A plugin has called the deprecated OrthancPluginGetConfigurationPath() primitive, the results " + << "are unreliable because multiple configuration paths were provided"; } const boost::filesystem::path& first = configurationPaths_.front(); diff -r 667acdc1b2f2 -r e1cce5515153 OrthancServer/Sources/main.cpp --- a/OrthancServer/Sources/main.cpp Tue Aug 11 16:56:06 2026 +0200 +++ b/OrthancServer/Sources/main.cpp Tue Aug 11 17:01:21 2026 +0200 @@ -2049,17 +2049,7 @@ } else if (argument[0] != '-') { - if (!configurationPaths.empty()) - { - LOG(ERROR) << "More than one configuration path were provided on the command line, aborting"; - return -1; - } - else - { - // Use the first argument that does not start with a "-" as - // the configuration file - - boost::filesystem::path configurationFile = SystemToolbox::PathFromUtf8(argument); + boost::filesystem::path configurationFile = SystemToolbox::PathFromUtf8(argument); // // TODO WHAT IS THE ENCODING? //#if defined(_WIN32) @@ -2068,8 +2058,7 @@ // configurationFileUtf8Str = std::string(argv[i]); //#endif - configurationPaths.push_back(configurationFile); - } + configurationPaths.push_back(configurationFile); } else if (argument == "--errors") {