From bcfdcc2b97e315940ab6569ccc6e0e7ac3d24258 Mon Sep 17 00:00:00 2001 From: Michael Boelen Date: Sat, 13 Aug 2016 09:45:38 +0200 Subject: [PATCH] Add show-report-solution setting --- include/consts | 1 + include/profiles | 18 ++++++++++++++++-- 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/include/consts b/include/consts index 6cb9045c..e57cc69e 100644 --- a/include/consts +++ b/include/consts @@ -186,6 +186,7 @@ unset LANG SHOWMOUNTBINARY="" SHOW_PROGRAM_DETAILS=1 SHOW_REPORT=1 + SHOW_REPORT_SOLUTION=0 SHOW_TOOL_TIPS=1 # Show inline tool tips (default true) SHOW_WARNINGS_ONLY=0 SKIP_PLUGINS=0 diff --git a/include/profiles b/include/profiles index 81c56a50..726aa7e6 100644 --- a/include/profiles +++ b/include/profiles @@ -22,7 +22,10 @@ # ################################################################################# # - + SETTING_SHOW_REPORT_SOLUTION=0 # default is no +# +################################################################################# +# for PROFILE in ${PROFILES}; do LogText "Reading profile/configuration ${PROFILE}" FIND=$(egrep "^config:|^[a-z-].*=" ${PROFILE} | sed 's/ /!space!/g') @@ -216,6 +219,13 @@ AddSetting "refresh-repositories" "${SETTING_REFRESH_REPOSITORIES}" "Refresh repositories (for vulnerable package detection)" ;; + # Show more details in report + show-report-solution) + FIND=$(echo "${VALUE}" | egrep "^(1|true|yes)$") && SHOW_REPORT_SOLUTION=1 + if [ ! -z "${FIND}" ]; then SETTING_SHOW_REPORT_SOLUTION=1; fi + Debug "Show report details (solution) set to ${SETTING_SHOW_REPORT_SOLUTION}" + ;; + # Inline tips about tool (default enabled) show_tool_tips | show-tool-tips) SETTING_SHOW_TOOL_TIPS=1 # default is yes @@ -428,7 +438,11 @@ # ################################################################################# # - + # Register the discovered settings + AddSetting "show-report-solution" "${SETTING_SHOW_REPORT_SOLUTION}" "Show more details in report (solution)" +# +################################################################################# +# Display --indent 2 --text "- Checking profiles..." --result "DONE" --color GREEN