Compare commits

...

3 Commits

Author SHA1 Message Date
Taiki Endo
80528fecb9 Release 1.10.0 2022-08-01 17:43:41 +09:00
Taiki Endo
878e967972 Set PROTOC environment variable when installing protoc 2022-08-01 17:40:32 +09:00
Taiki Endo
b1b32c59f1 Tweak readme 2022-08-01 17:30:50 +09:00
3 changed files with 15 additions and 2 deletions

View File

@@ -10,6 +10,10 @@ Note: In this file, do not use the hard wrap in the middle of a sentence for com
## [Unreleased]
## [1.10.0] - 2022-08-01
- Set the `PROTOC` environment variable when installing `protoc` if it has not already been set.
## [1.9.0] - 2022-08-01
- Support `protoc`.
@@ -257,7 +261,8 @@ Note: In this file, do not use the hard wrap in the middle of a sentence for com
Initial release
[Unreleased]: https://github.com/taiki-e/install-action/compare/v1.9.0...HEAD
[Unreleased]: https://github.com/taiki-e/install-action/compare/v1.10.0...HEAD
[1.10.0]: https://github.com/taiki-e/install-action/compare/v1.9.0...v1.10.0
[1.9.0]: https://github.com/taiki-e/install-action/compare/v1.8.4...v1.9.0
[1.8.4]: https://github.com/taiki-e/install-action/compare/v1.8.3...v1.8.4
[1.8.3]: https://github.com/taiki-e/install-action/compare/v1.8.2...v1.8.3

View File

@@ -84,7 +84,7 @@ https://spdx.org/licenses
If `$CARGO_HOME/bin` is not available, Rust-related binaries will be installed to `$HOME/.cargo/bin`.<br>
If `$HOME/.cargo/bin` is not available, Rust-related binaries will be installed to `/usr/local/bin`.<br>
If `/usr/local/bin` is not available, all binaries will be installed to `$HOME/.install-action/bin`.<br>
If `/usr/local/bin` is not available, binaries will be installed to `$HOME/.install-action/bin`.<br>
If a tool not included in the list above is specified, this action uses [cargo-binstall] as a fallback.

View File

@@ -239,6 +239,14 @@ for tool in "${tools[@]}"; do
*) bail "unsupported OSTYPE '${OSTYPE}' for ${tool}" ;;
esac
download "${url}" /usr/local/bin "bin/protoc${exe}"
if [[ -z "${PROTOC:-}" ]]; then
info "setting PROTOC environment variable"
if [[ -d /usr/local/bin ]]; then
echo "PROTOC=/usr/local/bin/protoc${exe}" >>"${GITHUB_ENV}"
else
echo "PROTOC=${HOME}/.install-action/bin/protoc${exe}" >>"${GITHUB_ENV}"
fi
fi
;;
shellcheck)
# https://github.com/koalaman/shellcheck/releases