diff --git a/src/lib/common.sh b/src/lib/common.sh index 8c3a538..81d833a 100755 --- a/src/lib/common.sh +++ b/src/lib/common.sh @@ -9,6 +9,7 @@ if command -v paru > /dev/null; then # shellcheck disable=SC2034 aur_helper="paru" elif command -v yay > /dev/null; then + # shellcheck disable=SC2034 aur_helper="yay" fi @@ -40,6 +41,7 @@ if [ -z "${no_color}" ]; then # shellcheck disable=SC2034 pacman_color_opt="always" else + # shellcheck disable=SC2034 pacman_color_opt="never" contrib_color_opt+=("--nocolor") fi diff --git a/src/lib/list_packages.sh b/src/lib/list_packages.sh index e3eca1b..9974a9e 100755 --- a/src/lib/list_packages.sh +++ b/src/lib/list_packages.sh @@ -7,15 +7,19 @@ info_msg "$(eval_gettext "Looking for updates...\n")" if [ -z "${no_version}" ]; then + # shellcheck disable=SC2154 packages=$(checkupdates "${contrib_color_opt[@]}") else + # shellcheck disable=SC2154 packages=$(checkupdates "${contrib_color_opt[@]}" | awk '{print $1}') fi if [ -n "${aur_helper}" ]; then if [ -z "${no_version}" ]; then + # shellcheck disable=SC2154 aur_packages=$("${aur_helper}" --color "${pacman_color_opt}" "${devel_flag[@]}" -Qua) else + # shellcheck disable=SC2154 aur_packages=$("${aur_helper}" --color "${pacman_color_opt}" "${devel_flag[@]}" -Qua | awk '{print $1}') fi fi @@ -51,8 +55,10 @@ else if [ -z "${list_option}" ]; then ask_msg "$(eval_gettext "Proceed with update? [Y/n]")" + # shellcheck disable=SC2154 case "${answer}" in "$(eval_gettext "Y")"|"$(eval_gettext "y")"|"") + # shellcheck disable=SC2154 proceed_with_update="y" echo ;; diff --git a/src/lib/pacnew_files.sh b/src/lib/pacnew_files.sh index c53409f..d7b28c2 100755 --- a/src/lib/pacnew_files.sh +++ b/src/lib/pacnew_files.sh @@ -16,6 +16,7 @@ if [ -n "${pacnew_files}" ]; then ask_msg "$(eval_gettext "Would you like to process these files now? [Y/n]")" fi + # shellcheck disable=SC2154 case "${answer}" in "$(eval_gettext "Y")"|"$(eval_gettext "y")"|"") echo