Skip to content

Commit

Permalink
reposync: Do not allow --safe-write-path with multiple repos.
Browse files Browse the repository at this point in the history
  • Loading branch information
m-blaha committed Dec 4, 2024
1 parent f7efc3e commit a09c577
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions dnf5-plugins/reposync_plugin/reposync.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,11 @@ void ReposyncCommand::configure() {
M_("Can't use --norepopath with multiple repositories enabled"));
}

if (!safe_write_path_option->get_value().empty() && repos_query.size() > 1) {
throw libdnf5::cli::ArgumentParserConflictingArgumentsError(
M_("Can't use --safe-write-path with multiple repositories enabled"));
}

// Default destination for downloaded repos is the current directory
context.get_base().get_config().get_destdir_option().set(libdnf5::Option::Priority::DEFAULT, ".");

Expand Down

0 comments on commit a09c577

Please sign in to comment.