diff options
Diffstat (limited to 'toolsrc/src/commands_export.cpp')
| -rw-r--r-- | toolsrc/src/commands_export.cpp | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/toolsrc/src/commands_export.cpp b/toolsrc/src/commands_export.cpp index 5e1cc2052..4adfbc0f6 100644 --- a/toolsrc/src/commands_export.cpp +++ b/toolsrc/src/commands_export.cpp @@ -246,9 +246,12 @@ namespace vcpkg::Commands::Export const bool zip = options.switches.find(OPTION_ZIP) != options.switches.cend(); const bool _7zip = options.switches.find(OPTION_7ZIP) != options.switches.cend(); - Checks::check_exit(VCPKG_LINE_INFO, - raw || nuget || zip || _7zip, - "Must provide at least one of the following options: --raw --nuget --zip --7zip"); + if (!raw && !nuget && !zip && !_7zip && !dryRun) + { + System::println(System::Color::error, "Must provide at least one export type: --raw --nuget --zip --7zip"); + System::print(example); + Checks::exit_fail(VCPKG_LINE_INFO); + } auto maybe_nuget_id = maybe_lookup(options.settings, OPTION_NUGET_ID); auto maybe_nuget_version = maybe_lookup(options.settings, OPTION_NUGET_VERSION); |
