diff --git a/lib.sh b/lib.sh index a8011a2..975fc3f 100755 --- a/lib.sh +++ b/lib.sh @@ -15,5 +15,5 @@ function get_package_name_ver { if test -z "${ver}"; then ver="$(grep "Version:" <<< "$(apt show ${name})" | awk '{print $2}')" fi - echo 'package_name="${name}"; package_ver="${ver}"' + echo ""${name}"="${ver}"" } diff --git a/pre_cache_action.sh b/pre_cache_action.sh index 1b0c70c..84d9868 100755 --- a/pre_cache_action.sh +++ b/pre_cache_action.sh @@ -41,9 +41,8 @@ for package in ${packages}; do echo "aborted." echo "Package '${package}' not found." >&2 exit 3 - fi - get_package_name_ver "${package}" # -> package_name, package_ver - versioned_packages="${versioned_packages} ${package_name}=${package_ver}" + fi + versioned_packages=""${versioned_packages}" "$(get_package_name_ver "${package}")"" done echo "done."