Skip to content

Commit

Permalink
lint: Fix SC2207 violations
Browse files Browse the repository at this point in the history
  • Loading branch information
ixti committed Feb 21, 2023
1 parent f2a5b39 commit 357fe91
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
5 changes: 4 additions & 1 deletion share/ruby-install/functions.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,10 @@ function load_dependencies_from()
{
local file="$1"

ruby_dependencies=($(fetch "$ruby/$file" "$package_manager" || return $?))
ruby_dependencies=()
while IFS='' read -r line; do
ruby_dependencies+=("$line");
done < <(fetch "$ruby/$file" "$package_manager" || return $?)
}

#
Expand Down
5 changes: 4 additions & 1 deletion share/ruby-install/package_manager.sh
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,10 @@ function install_packages()
run $brew_sudo brew upgrade "$@" || return $?
;;
pacman)
local missing_pkgs=($(pacman -T "$@"))
local missing_pkgs=()
while IFS='' read -r line; do
missing_pkgs+=("$line");
done < <(pacman -T "$@")

if (( ${#missing_pkgs[@]} > 0 )); then
run $sudo pacman -S "${missing_pkgs[@]}" || return $?
Expand Down

0 comments on commit 357fe91

Please sign in to comment.