diff --git a/action.yml b/action.yml index 672982a..2087b79 100644 --- a/action.yml +++ b/action.yml @@ -36,7 +36,7 @@ runs: esac os="${RUNNER_OS}" - if [[ $os == "macOS" ]]; then + if [[ "$os" == "macOS" ]]; then os="Darwin" fi @@ -50,16 +50,16 @@ runs: out=crane.exe fi - if [[ ! -z ${url} ]]; then + if [[ ! -z "${url}" ]]; then echo "Installing crane for ${os} on ${arch}" tmp=$(mktemp -d) - cd ${tmp} + cd "${tmp}" fname="go-containerregistry_${os}_${arch}.tar.gz" curl -o "$fname" -fsSL --retry 5 --retry-delay 1 --retry-all-errors "${url}/${fname}" - tar xzf "$fname" ${out} - chmod +x ${tmp}/${out} - PATH=${PATH}:${tmp} - echo "${tmp}" >> $GITHUB_PATH + tar xzf "$fname" "${out}" + chmod +x "${tmp}/${out}" + PATH="${PATH}:${tmp}" + echo "${tmp}" >> "$GITHUB_PATH" fi # NB: username doesn't seem to matter.