mirror of
https://github.com/taiki-e/install-action.git
synced 2026-04-21 15:10:27 +00:00
Install Rust-related binaries to /usr/local/bin when cargo home is not available
This commit is contained in:
6
main.sh
6
main.sh
@@ -129,9 +129,9 @@ case "${OSTYPE}" in
|
||||
esac
|
||||
|
||||
cargo_bin="${CARGO_HOME:-"$HOME/.cargo"}/bin"
|
||||
mkdir -p "${cargo_bin}"
|
||||
# For version check. It is intentional that this is not wrote in GITHUB_ENV.
|
||||
export PATH="${cargo_bin}:$PATH"
|
||||
if [[ ! -d "${cargo_bin}" ]]; then
|
||||
cargo_bin=/usr/local/bin
|
||||
fi
|
||||
|
||||
for tool in "${tools[@]}"; do
|
||||
if [[ "${tool}" == *"@"* ]]; then
|
||||
|
||||
Reference in New Issue
Block a user