diff --git a/action.yml b/action.yml index 8cdcb75..dd2ba44 100644 --- a/action.yml +++ b/action.yml @@ -48,10 +48,14 @@ runs: run: | # Cleanup artifacts from previous run in case it crashed rm -rf "lychee-${{ inputs.LYCHEEVERSION }}-x86_64-unknown-linux-gnu.tar.gz" lychee - curl -sLO "https://github.com/lycheeverse/lychee/releases/download/${{ inputs.LYCHEEVERSION }}/lychee-${{ inputs.LYCHEEVERSION }}-x86_64-unknown-linux-gnu.tar.gz" - tar -xvzf "lychee-${{ inputs.LYCHEEVERSION }}-x86_64-unknown-linux-gnu.tar.gz" - rm "lychee-${{ inputs.LYCHEEVERSION }}-x86_64-unknown-linux-gnu.tar.gz" - install -t "$HOME/.local/bin" -D lychee + case '${{ inputs.LYCHEEVERSION }}' in + v0.0*|v0.1[0-5].*) filename='lychee-${{ inputs.LYCHEEVERSION }}-x86_64-unknown-linux-gnu.tar.gz';; + *) filename='lychee-x86_64-unknown-linux-gnu.tar.gz' + esac + curl -sfLO "https://github.com/lycheeverse/lychee/releases/download/${{ inputs.LYCHEEVERSION }}/$filename" + tar -xvzf "$filename" + rm "$filename" + install -t "$HOME/.local/bin" -D lychee rm lychee echo "$HOME/.local/bin" >> "$GITHUB_PATH" shell: bash