mirror of
https://github.com/taiki-e/install-action.git
synced 2026-05-29 04:02:47 +08:00
Compare commits
12 Commits
v2.79.10
...
parse-dock
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
3b129fe20d | ||
|
|
6ed6112eb9 | ||
|
|
e5595d7ea6 | ||
|
|
7a697beba8 | ||
|
|
846d47aa31 | ||
|
|
b90a8a9122 | ||
|
|
06339b4e20 | ||
|
|
528208bb6d | ||
|
|
17370fd159 | ||
|
|
13608cbb45 | ||
|
|
cfb00c7135 | ||
|
|
1421678089 |
1
.github/.cspell/project-dictionary.txt
vendored
1
.github/.cspell/project-dictionary.txt
vendored
@@ -34,7 +34,6 @@ rdme
|
|||||||
sccache
|
sccache
|
||||||
SHASUMS
|
SHASUMS
|
||||||
sigstore
|
sigstore
|
||||||
startswith
|
|
||||||
syft
|
syft
|
||||||
tombi
|
tombi
|
||||||
udeps
|
udeps
|
||||||
|
|||||||
16
CHANGELOG.md
16
CHANGELOG.md
@@ -10,6 +10,18 @@ Note: In this file, do not use the hard wrap in the middle of a sentence for com
|
|||||||
|
|
||||||
## [Unreleased]
|
## [Unreleased]
|
||||||
|
|
||||||
|
## [2.79.12] - 2026-05-28
|
||||||
|
|
||||||
|
- Update `prek@latest` to 0.4.3.
|
||||||
|
|
||||||
|
- Remove uses of crates.io API, which potentially cases 403 error.
|
||||||
|
|
||||||
|
## [2.79.11] - 2026-05-28
|
||||||
|
|
||||||
|
- Update `vacuum@latest` to 0.26.8.
|
||||||
|
|
||||||
|
- Update `cargo-nextest@latest` to 0.9.137.
|
||||||
|
|
||||||
## [2.79.10] - 2026-05-27
|
## [2.79.10] - 2026-05-27
|
||||||
|
|
||||||
- Update `tombi@latest` to 1.1.0.
|
- Update `tombi@latest` to 1.1.0.
|
||||||
@@ -6666,7 +6678,9 @@ Note: This release is considered a breaking change because installing on version
|
|||||||
|
|
||||||
Initial release
|
Initial release
|
||||||
|
|
||||||
[Unreleased]: https://github.com/taiki-e/install-action/compare/v2.79.10...HEAD
|
[Unreleased]: https://github.com/taiki-e/install-action/compare/v2.79.12...HEAD
|
||||||
|
[2.79.12]: https://github.com/taiki-e/install-action/compare/v2.79.11...v2.79.12
|
||||||
|
[2.79.11]: https://github.com/taiki-e/install-action/compare/v2.79.10...v2.79.11
|
||||||
[2.79.10]: https://github.com/taiki-e/install-action/compare/v2.79.9...v2.79.10
|
[2.79.10]: https://github.com/taiki-e/install-action/compare/v2.79.9...v2.79.10
|
||||||
[2.79.9]: https://github.com/taiki-e/install-action/compare/v2.79.8...v2.79.9
|
[2.79.9]: https://github.com/taiki-e/install-action/compare/v2.79.8...v2.79.9
|
||||||
[2.79.8]: https://github.com/taiki-e/install-action/compare/v2.79.7...v2.79.8
|
[2.79.8]: https://github.com/taiki-e/install-action/compare/v2.79.7...v2.79.8
|
||||||
|
|||||||
@@ -4,8 +4,8 @@ description: GitHub Action for installing development tools
|
|||||||
inputs:
|
inputs:
|
||||||
tool:
|
tool:
|
||||||
description: Tools to install (whitespace or comma separated list)
|
description: Tools to install (whitespace or comma separated list)
|
||||||
required: true
|
required: false
|
||||||
# default: #publish:tool
|
default: parse-dockerfile
|
||||||
checksum:
|
checksum:
|
||||||
description: Whether to enable checksums (strongly discouraged to disable)
|
description: Whether to enable checksums (strongly discouraged to disable)
|
||||||
required: false
|
required: false
|
||||||
|
|||||||
85
main.sh
85
main.sh
@@ -254,29 +254,6 @@ read_manifest() {
|
|||||||
exact_version="${version}"
|
exact_version="${version}"
|
||||||
else
|
else
|
||||||
manifest=$(jq -r --arg version "${exact_version}" '.[$version]' "${manifest_dir}/${tool}.json")
|
manifest=$(jq -r --arg version "${exact_version}" '.[$version]' "${manifest_dir}/${tool}.json")
|
||||||
if [[ "${rust_crate}" != "null" ]]; then
|
|
||||||
# TODO: don't hardcode tool name and use 'immediate_yank_reflection' field in base manifest.
|
|
||||||
case "${tool}" in
|
|
||||||
cargo-nextest)
|
|
||||||
crate_info=$(retry curl --user-agent "${ACTION_USER_AGENT}" --proto '=https' --tlsv1.2 -fsSL --retry 10 "https://crates.io/api/v1/crates/${rust_crate}" || true)
|
|
||||||
if [[ -n "${crate_info}" ]]; then
|
|
||||||
while true; do
|
|
||||||
yanked=$(jq -r --arg version "${exact_version}" '.versions[] | select(.num == $version) | .yanked' <<<"${crate_info}")
|
|
||||||
if [[ "${yanked}" != "true" ]]; then
|
|
||||||
break
|
|
||||||
fi
|
|
||||||
previous_stable_version=$(jq -r '.previous_stable_version' <<<"${manifest}")
|
|
||||||
if [[ "${previous_stable_version}" == "null" ]]; then
|
|
||||||
break
|
|
||||||
fi
|
|
||||||
info "${tool}@${exact_version} is yanked; downgrade to ${previous_stable_version}"
|
|
||||||
exact_version="${previous_stable_version}"
|
|
||||||
manifest=$(jq -r --arg version "${exact_version}" '.[$version]' "${manifest_dir}/${tool}.json")
|
|
||||||
done
|
|
||||||
fi
|
|
||||||
;;
|
|
||||||
esac
|
|
||||||
fi
|
|
||||||
fi
|
fi
|
||||||
|
|
||||||
case "${host_os}" in
|
case "${host_os}" in
|
||||||
@@ -1090,66 +1067,18 @@ if [[ ${#unsupported_tools[@]} -gt 0 ]]; then
|
|||||||
cargo-binstall)
|
cargo-binstall)
|
||||||
install_cargo_binstall
|
install_cargo_binstall
|
||||||
# By default, cargo-binstall enforce downloads over secure transports only.
|
# By default, cargo-binstall enforce downloads over secure transports only.
|
||||||
# As a result, http will be disabled, and it will also set
|
# As a result, http will be disabled, and it will also set min tls version
|
||||||
# min tls version to be 1.2
|
# to be 1.2
|
||||||
binstall_args=(
|
binstall_args=(
|
||||||
--force
|
--force
|
||||||
--no-confirm
|
--no-confirm
|
||||||
--locked
|
--locked
|
||||||
# Since the build script can access the token when `cargo install` is called
|
|
||||||
# within `cargo-binstall`, disables building from source in cargo-binstall
|
|
||||||
# and fallback to `cargo install` which doesn't need the token.
|
|
||||||
# TODO: once https://github.com/cargo-bins/cargo-binstall/pull/2533 merged,
|
|
||||||
# we can remove this and use batch install again.
|
|
||||||
--disable-strategies compile
|
|
||||||
)
|
)
|
||||||
unsupported_tools2=()
|
if [[ -n "${token}" ]]; then
|
||||||
for tool in "${unsupported_tools[@]}"; do
|
GITHUB_TOKEN="${token}" \
|
||||||
if [[ -n "${token}" ]]; then
|
cargo-binstall binstall "${binstall_args[@]}" "${unsupported_tools[@]}"
|
||||||
if ! GITHUB_TOKEN="${token}" cargo-binstall binstall "${binstall_args[@]}" "${tool}"; then
|
else
|
||||||
warn "cargo-binstall fallback does not support prebuilt binaries for ${tool} on this platform (${host_arch}); use 'cargo-install' fallback instead"
|
cargo-binstall binstall "${binstall_args[@]}" "${unsupported_tools[@]}"
|
||||||
unsupported_tools2+=("${tool}")
|
|
||||||
fi
|
|
||||||
else
|
|
||||||
if ! cargo-binstall binstall "${binstall_args[@]}" "${tool}"; then
|
|
||||||
warn "cargo-binstall fallback does not support prebuilt binaries for ${tool} on this platform (${host_arch}); use 'cargo-install' fallback instead"
|
|
||||||
unsupported_tools2+=("${tool}")
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
if [[ ${#unsupported_tools2[@]} -gt 0 ]]; then
|
|
||||||
for tool in "${unsupported_tools2[@]}"; do
|
|
||||||
# This logic is from cache-cargo-install-action.
|
|
||||||
cargo_args=(--locked)
|
|
||||||
if [[ "${tool}" == *"@"* ]]; then
|
|
||||||
version="${tool#*@}"
|
|
||||||
tool="${tool%@*}"
|
|
||||||
if [[ ! "${version}" =~ ^([1-9][0-9]*\.[0-9]+\.[0-9]+|0\.[1-9][0-9]*\.[0-9]+|^0\.0\.[0-9]+)(-[0-9A-Za-z\.-]+)?(\+[0-9A-Za-z\.-]+)?$|^latest$ ]]; then
|
|
||||||
if [[ ! "${version}" =~ ^([1-9][0-9]*(\.[0-9]+(\.[0-9]+)?)?|0\.[1-9][0-9]*(\.[0-9]+)?|^0\.0\.[0-9]+)(-[0-9A-Za-z\.-]+)?(\+[0-9A-Za-z\.-]+)?$|^latest$ ]]; then
|
|
||||||
bail "install-action does not support non-semver version: '${version}'"
|
|
||||||
fi
|
|
||||||
crate_info=$(retry curl --user-agent "${ACTION_USER_AGENT}" --proto '=https' --tlsv1.2 -fsSL --retry 10 "https://crates.io/api/v1/crates/${tool}")
|
|
||||||
if [[ ! "${version}" =~ ^[0-9]+(\.[0-9]+)?$ ]]; then
|
|
||||||
bail "install-action does not support non-semver version: '${version}'"
|
|
||||||
fi
|
|
||||||
# shellcheck disable=SC2207
|
|
||||||
versions=($(jq -r --arg start "${version}." '.versions[] | select(.num | startswith($start)) | select(.yanked == false) | .num' <<<"${crate_info}"))
|
|
||||||
full_version=''
|
|
||||||
for v in ${versions[@]+"${versions[@]}"}; do
|
|
||||||
if [[ "${v}" =~ ^[0-9]+\.[0-9]+\.[0-9]+(\+[0-9A-Za-z\.-]+)?$ ]]; then
|
|
||||||
full_version="${v}"
|
|
||||||
break
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
if [[ -z "${full_version}" ]]; then
|
|
||||||
bail "no stable version found for ${tool} that match with '${version}.*'; if you want to install a pre-release version, please specify the full version"
|
|
||||||
fi
|
|
||||||
version="${full_version}"
|
|
||||||
fi
|
|
||||||
cargo_args+=(--version "${version}")
|
|
||||||
fi
|
|
||||||
cargo install "${cargo_args[@]}" "${tool}"
|
|
||||||
done
|
|
||||||
fi
|
fi
|
||||||
if [[ -z "${cargo_path}" ]]; then
|
if [[ -z "${cargo_path}" ]]; then
|
||||||
_bin_dir=$(canonicalize_windows_path "${home}/.cargo/bin")
|
_bin_dir=$(canonicalize_windows_path "${home}/.cargo/bin")
|
||||||
|
|||||||
22
manifests/cargo-deny.json
generated
22
manifests/cargo-deny.json
generated
@@ -28,6 +28,28 @@
|
|||||||
"0.19": {
|
"0.19": {
|
||||||
"version": "0.19.7"
|
"version": "0.19.7"
|
||||||
},
|
},
|
||||||
|
"0.19.8": {
|
||||||
|
"x86_64_linux_musl": {
|
||||||
|
"etag": "0x8DEBC9143658A6A",
|
||||||
|
"hash": "70e769ae3872e34d45132b17040859175e11401dc12dddb0303e0b8c7d088f3f"
|
||||||
|
},
|
||||||
|
"x86_64_macos": {
|
||||||
|
"etag": "0x8DEBC9158C150A8",
|
||||||
|
"hash": "dcd997dd8b7039015cd6f72d4feff64a21f5a6ec905e463751df80e70d82886c"
|
||||||
|
},
|
||||||
|
"x86_64_windows": {
|
||||||
|
"etag": "0x8DEBC9184A543FA",
|
||||||
|
"hash": "7db40a864ea299304e3a6c1d9f647fa8f554bb0353e181f63955b21c0dc57cd0"
|
||||||
|
},
|
||||||
|
"aarch64_linux_musl": {
|
||||||
|
"etag": "0x8DEBC914C73B2AC",
|
||||||
|
"hash": "67ef48056523d27f58a527c5e49172bc24758f7b8147998d47219d45b181c354"
|
||||||
|
},
|
||||||
|
"aarch64_macos": {
|
||||||
|
"etag": "0x8DEBC9138285055",
|
||||||
|
"hash": "24bbdbe694f9b0cc00b721d94cbd5a8f967eb9a4d2ee99351aa246a69b33ae4f"
|
||||||
|
}
|
||||||
|
},
|
||||||
"0.19.7": {
|
"0.19.7": {
|
||||||
"x86_64_linux_musl": {
|
"x86_64_linux_musl": {
|
||||||
"etag": "0x8DEB7D6F3B4B3A3",
|
"etag": "0x8DEB7D6F3B4B3A3",
|
||||||
|
|||||||
4
manifests/cargo-nextest.json
generated
4
manifests/cargo-nextest.json
generated
@@ -27,10 +27,10 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"latest": {
|
"latest": {
|
||||||
"version": "0.9.136"
|
"version": "0.9.137"
|
||||||
},
|
},
|
||||||
"0.9": {
|
"0.9": {
|
||||||
"version": "0.9.136"
|
"version": "0.9.137"
|
||||||
},
|
},
|
||||||
"0.9.137": {
|
"0.9.137": {
|
||||||
"previous_stable_version": "0.9.136",
|
"previous_stable_version": "0.9.136",
|
||||||
|
|||||||
22
manifests/gungraun-runner.json
generated
22
manifests/gungraun-runner.json
generated
@@ -28,6 +28,28 @@
|
|||||||
"0.19": {
|
"0.19": {
|
||||||
"version": "0.19.0"
|
"version": "0.19.0"
|
||||||
},
|
},
|
||||||
|
"0.19.1": {
|
||||||
|
"x86_64_linux_musl": {
|
||||||
|
"etag": "0x8DEBC4AE0ECBD5A",
|
||||||
|
"hash": "fadef57834f6b7a3514695eed65fce748efeb1e601073b40de3062df02894102"
|
||||||
|
},
|
||||||
|
"aarch64_linux_gnu": {
|
||||||
|
"etag": "0x8DEBC4AE56BAF89",
|
||||||
|
"hash": "b8142d894bcb5bb66f7113b0b5cef4e861cc10399453312c977f9d564fdd951b"
|
||||||
|
},
|
||||||
|
"powerpc64le_linux_gnu": {
|
||||||
|
"etag": "0x8DEBC4AA0A11589",
|
||||||
|
"hash": "96a3118c55ee7ed60982dd9f3611f930dc3da0b648d6bf8a2c8bffd7da0524e3"
|
||||||
|
},
|
||||||
|
"riscv64_linux_gnu": {
|
||||||
|
"etag": "0x8DEBC4AD908F661",
|
||||||
|
"hash": "00f70a4c20fc820a42a3d3c681169b028474528f324f9ea3bc29cdc5a8584997"
|
||||||
|
},
|
||||||
|
"s390x_linux_gnu": {
|
||||||
|
"etag": "0x8DEBC4B0AA8CF46",
|
||||||
|
"hash": "2a460d5cf58e8332c4b5876f3c26203dfee898bd0411db9e9590bd03eb16c227"
|
||||||
|
}
|
||||||
|
},
|
||||||
"0.19.0": {
|
"0.19.0": {
|
||||||
"x86_64_linux_musl": {
|
"x86_64_linux_musl": {
|
||||||
"etag": "0x8DEB2939FC5A8D0",
|
"etag": "0x8DEB2939FC5A8D0",
|
||||||
|
|||||||
4
manifests/prek.json
generated
4
manifests/prek.json
generated
@@ -39,10 +39,10 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"latest": {
|
"latest": {
|
||||||
"version": "0.4.2"
|
"version": "0.4.3"
|
||||||
},
|
},
|
||||||
"0.4": {
|
"0.4": {
|
||||||
"version": "0.4.2"
|
"version": "0.4.3"
|
||||||
},
|
},
|
||||||
"0.4.3": {
|
"0.4.3": {
|
||||||
"x86_64_linux_musl": {
|
"x86_64_linux_musl": {
|
||||||
|
|||||||
30
manifests/vacuum.json
generated
30
manifests/vacuum.json
generated
@@ -21,10 +21,36 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"latest": {
|
"latest": {
|
||||||
"version": "0.26.7"
|
"version": "0.26.8"
|
||||||
|
},
|
||||||
|
"0.27.0": {
|
||||||
|
"x86_64_linux_musl": {
|
||||||
|
"etag": "0x8DEBC985A78A3AD",
|
||||||
|
"hash": "904c1187f9c1530a08250a4eb147ef0f78dd4a501e58bfd6330c6a4b2af00f06"
|
||||||
|
},
|
||||||
|
"x86_64_macos": {
|
||||||
|
"etag": "0x8DEBC9859848012",
|
||||||
|
"hash": "eb21f091626d12a162532462ff4c3decf098958edb9e20036b407abccc30c71d"
|
||||||
|
},
|
||||||
|
"x86_64_windows": {
|
||||||
|
"etag": "0x8DEBC985A760E7B",
|
||||||
|
"hash": "b07f642723b73ecdeaae9d4e951d3f667569a3fc7cf30aeed9f32fcf54743dac"
|
||||||
|
},
|
||||||
|
"aarch64_linux_musl": {
|
||||||
|
"etag": "0x8DEBC985A887073",
|
||||||
|
"hash": "a042fba6852813a5e7a1edd652f4d55b218a67249933ebe91b3cdbf714aa0727"
|
||||||
|
},
|
||||||
|
"aarch64_macos": {
|
||||||
|
"etag": "0x8DEBC98598935BC",
|
||||||
|
"hash": "684aeaeff2e1cb0c771e76448d183637529c1821162eb651a940274211da03e2"
|
||||||
|
},
|
||||||
|
"aarch64_windows": {
|
||||||
|
"etag": "0x8DEBC98597AC6F8",
|
||||||
|
"hash": "d60003d000f9c5c981489d0fa45eccd0f65d846ffafe61b2070d902359640a3c"
|
||||||
|
}
|
||||||
},
|
},
|
||||||
"0.26": {
|
"0.26": {
|
||||||
"version": "0.26.7"
|
"version": "0.26.8"
|
||||||
},
|
},
|
||||||
"0.26.8": {
|
"0.26.8": {
|
||||||
"x86_64_linux_musl": {
|
"x86_64_linux_musl": {
|
||||||
|
|||||||
Reference in New Issue
Block a user