Compare commits

...

8 Commits

Author SHA1 Message Date
Taiki Endo
17a6efb458 Release 1.1.2 2022-01-22 01:01:30 +09:00
Taiki Endo
5c982063f4 Update cargo-hack,cargo-llvm-cov,cargo-minimal-versions,parse-changelog 2022-01-22 00:59:13 +09:00
Taiki Endo
d15809d0ff Release 1.1.1 2022-01-21 14:38:33 +09:00
Taiki Endo
fc28b6c995 Update cargo-hack to 0.5.11 2022-01-21 14:37:35 +09:00
Taiki Endo
dbea48787c Release 1.1.0 2022-01-09 18:57:02 +09:00
Taiki Endo
5a0c826638 Support wasmtime 2022-01-09 18:53:39 +09:00
Taiki Endo
ba3d801fa2 Support wasm-pack 2022-01-09 18:53:31 +09:00
Taiki Endo
aab5a1fdfb Support valgrind 2022-01-09 18:23:50 +09:00
5 changed files with 79 additions and 12 deletions

View File

@@ -24,15 +24,15 @@ jobs:
matrix:
os:
- ubuntu-18.04
- macos-10.15
tool:
- cargo-hack,cargo-llvm-cov,cargo-minimal-versions,parse-changelog,cross,shellcheck,shfmt
- cargo-hack@0.5.10,cargo-llvm-cov@0.1.15,cargo-minimal-versions@0.1.1,parse-changelog@0.4.6,cross@0.2.1,shellcheck@0.8.0,shfmt@3.4.2
# NOTE: Specifying the version of valgrind and wasm-pack is not supported.
- cargo-hack,cargo-llvm-cov,cargo-minimal-versions,parse-changelog,cross,shellcheck,shfmt,valgrind,wasm-pack,wasmtime
- cargo-hack@0.5.12,cargo-llvm-cov@0.1.16,cargo-minimal-versions@0.1.2,parse-changelog@0.4.7,cross@0.2.1,shellcheck@0.8.0,shfmt@3.4.2,wasmtime@0.33.0
include:
- os: macos-10.15
tool: cargo-hack,cargo-llvm-cov,cargo-minimal-versions,parse-changelog,cross,shellcheck,shfmt,wasm-pack,wasmtime
- os: windows-2019
tool: cargo-hack,cargo-llvm-cov,cargo-minimal-versions,parse-changelog
- os: windows-2019
tool: cargo-hack@0.5.10,cargo-llvm-cov@0.1.15,cargo-minimal-versions@0.1.1,parse-changelog@0.4.6,cross@0.2.1
tool: cargo-hack,cargo-llvm-cov,cargo-minimal-versions,parse-changelog,cross
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2

View File

@@ -10,6 +10,21 @@ Note: In this file, do not use the hard wrap in the middle of a sentence for com
## [Unreleased]
## [1.1.2] - 2022-01-21
- Update `cargo-hack@latest` to 0.5.12.
- Update `cargo-llvm-cov@latest` to 0.1.16.
- Update `cargo-minimal-versions@latest` to 0.1.2.
- Update `parse-changelog@latest` to 0.4.7.
## [1.1.1] - 2022-01-21
- Update `cargo-hack@latest` to 0.5.11.
## [1.1.0] - 2022-01-09
- Support `valgrind`, `wasm-pack`, and `wasmtime`.
## [1.0.3] - 2022-01-06
- Update `cargo-llvm-cov@latest` to 0.1.15.
@@ -26,7 +41,10 @@ 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.0.3...HEAD
[Unreleased]: https://github.com/taiki-e/install-action/compare/v1.1.2...HEAD
[1.1.2]: https://github.com/taiki-e/install-action/compare/v1.1.1...v1.1.2
[1.1.1]: https://github.com/taiki-e/install-action/compare/v1.1.0...v1.1.1
[1.1.0]: https://github.com/taiki-e/install-action/compare/v1.0.3...v1.1.0
[1.0.3]: https://github.com/taiki-e/install-action/compare/v1.0.2...v1.0.3
[1.0.2]: https://github.com/taiki-e/install-action/compare/v1.0.1...v1.0.2
[1.0.1]: https://github.com/taiki-e/install-action/compare/v1.0.0...v1.0.1

View File

@@ -39,7 +39,7 @@ To install a specific version, use `@version` syntax:
```yaml
- uses: taiki-e/install-action@v1
with:
tool: cargo-hack@0.5.10
tool: cargo-hack@0.5.11
```
To install multiple tools:
@@ -73,6 +73,9 @@ https://spdx.org/licenses
| [**cross**](https://github.com/rust-embedded/cross) | `~/.cargo/bin` | [GitHub Releases](https://github.com/rust-embedded/cross/releases) | Linux, macOS, Windows | [Apache-2.0](https://github.com/rust-embedded/cross/blob/HEAD/LICENSE-APACHE) OR [MIT](https://github.com/rust-embedded/cross/blob/HEAD/LICENSE-MIT) |
| [**shellcheck**](https://www.shellcheck.net) | `/usr/local/bin` | [GitHub Releases](https://github.com/koalaman/shellcheck/releases) | Linux, macOS | [GPL-3.0-or-later](https://github.com/koalaman/shellcheck/blob/HEAD/LICENSE) |
| [**shfmt**](https://github.com/mvdan/sh) | `/usr/local/bin` | [GitHub Releases](https://github.com/mvdan/sh/releases) | Linux, macOS | [BSD-3-Clause](https://github.com/mvdan/sh/blob/HEAD/LICENSE) |
| [**valgrind**](https://valgrind.org) | `/snap/bin` | [snap](https://snapcraft.io/install/valgrind/ubuntu) | Linux | [GPL-2.0-or-later](https://valgrind.org/docs/manual/license.gpl.html) |
| [**wasm-pack**](https://github.com/rustwasm/wasm-pack) | `~/.cargo/bin` | [GitHub Releases](https://github.com/rustwasm/wasm-pack/releases) | Linux, macOS | [Apache-2.0](https://github.com/rustwasm/wasm-pack/blob/HEAD/LICENSE-APACHE) OR [MIT](https://github.com/rustwasm/wasm-pack/blob/HEAD/LICENSE-MIT) |
| [**wasmtime**](https://github.com/bytecodealliance/wasmtime) | `~/.cargo/bin` | [GitHub Releases](https://github.com/bytecodealliance/wasmtime/releases) | Linux, macOS | [Apache-2.0 WITH LLVM-exception](https://github.com/bytecodealliance/wasmtime/blob/HEAD/LICENSE) |
<!-- TODO:
| [**cmake**](https://cmake.org) | | [GitHub Releases](https://github.com/Kitware/CMake/releases) | Linux, macOS, Windows | [BSD-3-Clause](https://github.com/Kitware/CMake/blob/HEAD/Copyright.txt) |

51
main.sh
View File

@@ -57,13 +57,13 @@ for tool in "${tools[@]}"; do
cargo-hack | cargo-llvm-cov | cargo-minimal-versions | parse-changelog)
case "${tool}" in
# https://github.com/taiki-e/cargo-hack/releases
cargo-hack) latest_version="0.5.10" ;;
cargo-hack) latest_version="0.5.12" ;;
# https://github.com/taiki-e/cargo-llvm-cov/releases
cargo-llvm-cov) latest_version="0.1.15" ;;
cargo-llvm-cov) latest_version="0.1.16" ;;
# https://github.com/taiki-e/cargo-minimal-versions/releases
cargo-minimal-versions) latest_version="0.1.1" ;;
cargo-minimal-versions) latest_version="0.1.2" ;;
# https://github.com/taiki-e/parse-changelog/releases
parse-changelog) latest_version="0.4.6" ;;
parse-changelog) latest_version="0.4.7" ;;
*) exit 1 ;;
esac
repo="taiki-e/${tool}"
@@ -136,6 +136,49 @@ for tool in "${tools[@]}"; do
retry curl --proto '=https' --tlsv1.2 -fsSL --retry 10 --retry-connrefused -o /usr/local/bin/shfmt "${url}"
chmod +x /usr/local/bin/shfmt
;;
valgrind)
case "${OSTYPE}" in
linux*) ;;
darwin* | cygwin* | msys*) bail "${tool} for non-linux is not supported yet by this action" ;;
*) bail "unsupported OSTYPE '${OSTYPE}' for ${tool}" ;;
esac
case "${version}" in
latest) ;;
*) warn "specifying the version of ${tool} is not supported yet by this action" ;;
esac
sudo apt-get -o Acquire::Retries=10 -qq update
# libc6-dbg is needed to run Valgrind
sudo apt-get -o Acquire::Retries=10 -qq -o Dpkg::Use-Pty=0 install -y libc6-dbg
# Use snap to install the latest Valgrind
# https://snapcraft.io/install/valgrind/ubuntu
sudo snap install valgrind --classic
;;
wasm-pack)
# https://rustwasm.github.io/wasm-pack/installer
case "${OSTYPE}" in
linux* | darwin*) ;;
cygwin* | msys*) bail "${tool} for windows is not supported yet by this action" ;;
*) bail "unsupported OSTYPE '${OSTYPE}' for ${tool}" ;;
esac
retry curl --proto '=https' --tlsv1.2 -fsSL --retry 10 --retry-connrefused https://rustwasm.github.io/wasm-pack/installer/init.sh | sh
;;
wasmtime)
# https://github.com/bytecodealliance/wasmtime/releases
latest_version="0.33.0"
repo="bytecodealliance/wasmtime"
case "${OSTYPE}" in
linux*) target="x86_64-linux" ;;
darwin*) target="x86_64-macos" ;;
cygwin* | msys*) bail "${tool} for windows is not supported yet by this action" ;;
*) bail "unsupported OSTYPE '${OSTYPE}' for ${tool}" ;;
esac
case "${version}" in
latest) version="${latest_version}" ;;
esac
url="https://github.com/bytecodealliance/wasmtime/releases/download/v${version}/wasmtime-v${version}-${target}.tar.xz"
retry curl --proto '=https' --tlsv1.2 -fsSL --retry 10 --retry-connrefused "${url}" \
| tar xJf - --strip-components 1 -C ~/.cargo/bin "wasmtime-v${version}-${target}/wasmtime"
;;
*) bail "unsupported tool '${tool}'" ;;
esac

View File

@@ -57,6 +57,9 @@ tools=(
cross
shellcheck
shfmt
valgrind
wasm-pack
wasmtime
)
(