mirror of
https://github.com/awalsh128/cache-apt-pkgs-action.git
synced 2024-12-22 18:55:30 +00:00
Fix package name ver function output.
This commit is contained in:
parent
c961be0ea5
commit
45b8861f3a
2
lib.sh
2
lib.sh
|
@ -15,5 +15,5 @@ function get_package_name_ver {
|
||||||
if test -z "${ver}"; then
|
if test -z "${ver}"; then
|
||||||
ver="$(grep "Version:" <<< "$(apt show ${name})" | awk '{print $2}')"
|
ver="$(grep "Version:" <<< "$(apt show ${name})" | awk '{print $2}')"
|
||||||
fi
|
fi
|
||||||
echo 'package_name="${name}"; package_ver="${ver}"'
|
echo ""${name}"="${ver}""
|
||||||
}
|
}
|
||||||
|
|
|
@ -42,8 +42,7 @@ for package in ${packages}; do
|
||||||
echo "Package '${package}' not found." >&2
|
echo "Package '${package}' not found." >&2
|
||||||
exit 3
|
exit 3
|
||||||
fi
|
fi
|
||||||
get_package_name_ver "${package}" # -> package_name, package_ver
|
versioned_packages=""${versioned_packages}" "$(get_package_name_ver "${package}")""
|
||||||
versioned_packages="${versioned_packages} ${package_name}=${package_ver}"
|
|
||||||
done
|
done
|
||||||
echo "done."
|
echo "done."
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue