Skip to content

Commit

Permalink
Add new configuration option exclude_from_weak_autodetect
Browse files Browse the repository at this point in the history
It will enable automatic mechanism to prevent installing unmet weak
deps.
  • Loading branch information
j-mracek authored and pkratoch committed Sep 30, 2021
1 parent bff0078 commit d8d2703
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
3 changes: 3 additions & 0 deletions libdnf/conf/ConfigMain.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -299,6 +299,7 @@ class ConfigMain::Impl {
OptionStringList excludepkgs{std::vector<std::string>{}};
OptionStringList includepkgs{std::vector<std::string>{}};
OptionStringList exclude_from_weak{std::vector<std::string>{}};
OptionBool exclude_from_weak_autodetect{true};
OptionString proxy{""};
OptionString proxy_username{nullptr};
OptionString proxy_password{nullptr};
Expand Down Expand Up @@ -482,6 +483,7 @@ ConfigMain::Impl::Impl(Config & owner)
}, nullptr, true
);

owner.optBinds().add("exclude_from_weak_autodetect", exclude_from_weak_autodetect);
owner.optBinds().add("proxy", proxy);
owner.optBinds().add("proxy_username", proxy_username);
owner.optBinds().add("proxy_password", proxy_password);
Expand Down Expand Up @@ -608,6 +610,7 @@ OptionBool & ConfigMain::fastestmirror() { return pImpl->fastestmirror; }
OptionStringList & ConfigMain::excludepkgs() { return pImpl->excludepkgs; }
OptionStringList & ConfigMain::includepkgs() { return pImpl->includepkgs; }
OptionStringList & ConfigMain::exclude_from_weak() { return pImpl->exclude_from_weak; }
OptionBool & ConfigMain::exclude_from_weak_autodetect() { return pImpl->exclude_from_weak_autodetect; }
OptionString & ConfigMain::proxy() { return pImpl->proxy; }
OptionString & ConfigMain::proxy_username() { return pImpl->proxy_username; }
OptionString & ConfigMain::proxy_password() { return pImpl->proxy_password; }
Expand Down
1 change: 1 addition & 0 deletions libdnf/conf/ConfigMain.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,7 @@ class ConfigMain : public Config {
OptionStringList & excludepkgs();
OptionStringList & includepkgs();
OptionStringList & exclude_from_weak();
OptionBool & exclude_from_weak_autodetect();
OptionString & proxy();
OptionString & proxy_username();
OptionString & proxy_password();
Expand Down

0 comments on commit d8d2703

Please sign in to comment.