Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revert "Drop errorlevel config option" #1793

Merged
merged 1 commit into from
Oct 23, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions include/libdnf5/conf/config_main.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,12 @@ class LIBDNF_API ConfigMain : public Config {

OptionNumber<std::int32_t> & get_debuglevel_option();
const OptionNumber<std::int32_t> & get_debuglevel_option() const;
/// @deprecated errorlevel option does nothing and is scheduled for removal
[[deprecated("errorlevel option does nothing and is scheduled for removal")]] OptionNumber<std::int32_t> &
get_errorlevel_option();
/// @deprecated errorlevel option does nothing and is scheduled for removal
[[deprecated("errorlevel option does nothing and is scheduled for removal")]] const OptionNumber<std::int32_t> &
get_errorlevel_option() const;
OptionPath & get_installroot_option();
const OptionPath & get_installroot_option() const;
OptionPath & get_config_file_path_option();
Expand Down
9 changes: 9 additions & 0 deletions libdnf5/conf/config_main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@ class ConfigMain::Impl {
Config & owner;

OptionNumber<std::int32_t> debuglevel{2, 0, 10};
OptionNumber<std::int32_t> errorlevel{3, 0, 10};
ppisar marked this conversation as resolved.
Show resolved Hide resolved
OptionPath installroot{"/", false, true};
OptionBool use_host_config{false};
OptionPath config_file_path{CONF_FILENAME};
Expand Down Expand Up @@ -299,6 +300,7 @@ class ConfigMain::Impl {

ConfigMain::Impl::Impl(Config & owner) : owner(owner) {
owner.opt_binds().add("debuglevel", debuglevel);
owner.opt_binds().add("errorlevel", errorlevel);
owner.opt_binds().add("installroot", installroot);
owner.opt_binds().add("use_host_config", use_host_config);
owner.opt_binds().add("config_file_path", config_file_path);
Expand Down Expand Up @@ -472,6 +474,13 @@ const OptionNumber<std::int32_t> & ConfigMain::get_debuglevel_option() const {
return p_impl->debuglevel;
}

OptionNumber<std::int32_t> & ConfigMain::get_errorlevel_option() {
return p_impl->errorlevel;
}
const OptionNumber<std::int32_t> & ConfigMain::get_errorlevel_option() const {
return p_impl->errorlevel;
}

OptionPath & ConfigMain::get_installroot_option() {
return p_impl->installroot;
}
Expand Down
Loading