Skip to content

Commit

Permalink
Add architecture suggestion
Browse files Browse the repository at this point in the history
  • Loading branch information
fcaffieri committed Jan 31, 2025
1 parent 6005324 commit 137069b
Showing 1 changed file with 14 additions and 2 deletions.
16 changes: 14 additions & 2 deletions install_functions/checks.sh
Original file line number Diff line number Diff line change
Expand Up @@ -56,12 +56,24 @@ function checks_arguments() {
if [ -n "${download}" ] && [ -n "${download_arch}" ]; then
if [ "${package_type}" = "deb" ]; then
if [ "${arch}" != "amd64" ] && [ "${arch}" != "arm64" ]; then
common_logger -e "Architecture ${arch} not valid for package type ${package_type}"
if [ "${arch}" = "x86_64" ]; then
common_logger -e "Architecture ${arch} not valid for package type ${package_type}. Use amd64 instead."
elif [ "${arch}" = "aarch64" ]; then
common_logger -e "Architecture ${arch} not valid for package type ${package_type}. Use arm64 instead."
else
common_logger -e "Architecture ${arch} not valid for package type ${package_type}"
fi
exit 1
fi
elif [ "${package_type}" = "rpm" ]; then
if [ "${arch}" != "x86_64" ] && [ "${arch}" != "aarch64" ]; then
common_logger -e "Architecture ${arch} not valid for package type ${package_type}"
if [ "${arch}" = "amd64" ]; then
common_logger -e "Architecture ${arch} not valid for package type ${package_type}. Use x86_64 instead."
elif [ "${arch}" = "arm64" ]; then
common_logger -e "Architecture ${arch} not valid for package type ${package_type}. Use aarch64 instead."
else
common_logger -e "Architecture ${arch} not valid for package type ${package_type}"
fi
exit 1
fi
fi
Expand Down

0 comments on commit 137069b

Please sign in to comment.