a #133
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: check test | |
# on: | |
# push: | |
defaults: | |
run: | |
shell: bash | |
# jobs: | |
# # 全OSで実行lsしてwcで行数を数えるコードを叩いてみる | |
# check: | |
# runs-on: ${{ matrix.os }} | |
# strategy: | |
# matrix: | |
# os: [ubuntu-latest, windows-latest, macos-latest] | |
# steps: | |
# - name: Run ls | |
# run: ls | |
# - name: Run wc | |
# run: ls | wc -l | |
# - name: Setup tmate session | |
# uses: mxschmitt/action-tmate@v3 | |
on: | |
push: | |
workflow_call: | |
inputs: | |
version: | |
type: string | |
required: true | |
repo_url: | |
type: string | |
required: false | |
workflow_dispatch: | |
inputs: | |
version: | |
type: string | |
description: "テストしたいタグ名" | |
required: true | |
repo_url: | |
type: string | |
description: "リポジトリのURL(省略可能)" | |
required: false | |
env: | |
REPO_URL: "https://github.com/VOICEVOX/voicevox_engine" | |
VERSION: "0.19.0" | |
# VERSION: "0.18.1" | |
jobs: | |
test: | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- os: macos-11 | |
target: macos-x64 | |
- os: macos-12 | |
target: macos-x64 | |
- os: macos-13 | |
target: macos-x64 | |
- os: macos-14 | |
target: macos-x64 | |
runs-on: ${{ matrix.os }} | |
steps: | |
- name: <Setup> Declare variables | |
id: vars | |
run: | | |
echo "release_url=${{ env.REPO_URL }}/releases/download/${{ env.VERSION }}" >> "$GITHUB_OUTPUT" | |
echo "package_name=voicevox_engine-${{ matrix.target }}-${{ env.VERSION }}" >> "$GITHUB_OUTPUT" | |
- name: <Setup> Download ENGINE package | |
run: | | |
mkdir -p download | |
curl -L -o "download/list.txt" "${{ steps.vars.outputs.release_url }}/${{ steps.vars.outputs.package_name }}.7z.txt" | |
cat "download/list.txt" | xargs -I '%' curl -L -o "download/%" "${{ steps.vars.outputs.release_url }}/%" | |
7z x "download/$(head -n1 download/list.txt)" | |
mv "${{ matrix.target }}" dist/ | |
- name: <Setup> Set up permission | |
if: startsWith(matrix.target, 'linux') || startsWith(matrix.target, 'macos') | |
run: chmod +x dist/run | |
- name: run dist/run | |
run: ./dist/run | |
# - name: Setup tmate session | |
# uses: mxschmitt/action-tmate@v3 | |
# - name: <Setup> Install Python test dependencies | |
# run: | | |
# pip install -r requirements-test.txt | |
# - name: <Test> Test ENGINE package | |
# run: python build_util/check_release_build.py --dist_dir dist/ |