Regen master kaitai-io/kaitai_struct@8e2eb7a7ab940afbec888db95dc57802… #322
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: CI | |
on: | |
push: | |
branches: | |
- master | |
pull_request: {} | |
jobs: | |
windows: | |
runs-on: windows-latest | |
# NB: see https://github.com/actions/runner-images/blob/main/images/win/Windows2022-Readme.md for what's available in this image | |
strategy: | |
fail-fast: false | |
matrix: | |
tsv: | |
# - target: cpp_stl | |
# subtarget: _98 | |
# implementation: msvc142 | |
# - target: cpp_stl | |
# subtarget: _11 | |
# implementation: msvc142 | |
- target: csharp | |
implementation: net48 | |
env: | |
TARGET: ${{matrix.tsv.target}} | |
SUBTARGET: ${{matrix.tsv.subtarget}} | |
IMPL: ${{matrix.tsv.implementation}} | |
steps: | |
- name: Dump matrix context | |
env: | |
MATRIX_CONTEXT: ${{ toJson(matrix) }} | |
run: echo "$MATRIX_CONTEXT" | |
- uses: actions/checkout@v4 | |
with: | |
submodules: 'true' | |
- name: install rsync | |
run: choco install rsync --no-progress | |
- name: check rsync version | |
run: rsync --version | |
- uses: microsoft/setup-msbuild@v2 | |
- name: prepare | |
run: | | |
git clone --depth 1 https://github.com/kaitai-io/kaitai_struct_tests tests | |
git -C tests rev-parse HEAD | |
cp -r compiled tests/compiled | |
./prepare-$TARGET | |
shell: bash | |
- name: GitHub Actions job_id parser | |
uses: Tiryoh/gha-jobid-action@v1 | |
id: job_info | |
with: | |
github_token: ${{github.token}} | |
job_name: "${{github.job}} (${{matrix.tsv.target}}${{ format('{0}', matrix.tsv.subtarget) != '' && format(', {0}', matrix.tsv.subtarget) || '' }}, ${{matrix.tsv.implementation}})" | |
# This is needed if there are more than 30 jobs in the workflow run, | |
# see https://github.com/Tiryoh/gha-jobid-action/issues/1 | |
per_page: 100 | |
- name: run | |
env: | |
GH_JOB_ID: ${{steps.job_info.outputs.job_id}} | |
GH_HTML_URL: ${{steps.job_info.outputs.html_url}} | |
working-directory: tests | |
run: ./ci-$TARGET$SUBTARGET | |
shell: bash | |
- name: publish | |
env: | |
BOT_SSH_KEY: ${{secrets.BOT_SSH_KEY}} | |
run: | | |
./push_artifacts/git_config_kaitai_bot | |
./push_artifacts/publish \ | |
-o kaitai-io \ | |
-r ci_artifacts \ | |
-m "Build results of ${GITHUB_REF#refs/heads/*} kaitai-io/ci_targets@$GITHUB_SHA" \ | |
-b "${TARGET}${SUBTARGET}"/"$IMPL-windows-x64" \ | |
-- --exclude=.git --exclude=.travis.yml tests/test_out | |
shell: bash | |
macos: | |
runs-on: macos-12 | |
# NB: https://github.com/actions/runner-images/blob/main/images/macos/macos-12-Readme.md | |
strategy: | |
fail-fast: false | |
matrix: | |
tsv: | |
- target: cpp_stl | |
subtarget: _98 | |
implementation: clang14 | |
- target: cpp_stl | |
subtarget: _11 | |
implementation: clang14 | |
env: | |
TARGET: ${{matrix.tsv.target}} | |
SUBTARGET: ${{matrix.tsv.subtarget}} | |
IMPL: ${{matrix.tsv.implementation}} | |
steps: | |
- name: Dump matrix context | |
env: | |
MATRIX_CONTEXT: ${{ toJson(matrix) }} | |
run: echo "$MATRIX_CONTEXT" | |
- uses: actions/checkout@v4 | |
with: | |
submodules: 'true' | |
- name: prepare | |
run: | | |
git clone --depth 1 https://github.com/kaitai-io/kaitai_struct_tests tests | |
git -C tests rev-parse HEAD | |
ln -s ../compiled tests/compiled | |
./prepare-$TARGET | |
- name: GitHub Actions job_id parser | |
uses: Tiryoh/gha-jobid-action@v1 | |
id: job_info | |
with: | |
github_token: ${{github.token}} | |
job_name: "${{github.job}} (${{matrix.tsv.target}}, ${{matrix.tsv.subtarget}}, ${{matrix.tsv.implementation}})" | |
# This is needed if there are more than 30 jobs in the workflow run, | |
# see https://github.com/Tiryoh/gha-jobid-action/issues/1 | |
per_page: 100 | |
- name: run | |
env: | |
GH_JOB_ID: ${{steps.job_info.outputs.job_id}} | |
GH_HTML_URL: ${{steps.job_info.outputs.html_url}} | |
working-directory: tests | |
run: ./ci-$TARGET$SUBTARGET | |
- name: publish | |
env: | |
BOT_SSH_KEY: ${{secrets.BOT_SSH_KEY}} | |
run: | | |
./push_artifacts/git_config_kaitai_bot | |
./push_artifacts/publish \ | |
-o kaitai-io \ | |
-r ci_artifacts \ | |
-m "Build results of ${GITHUB_REF#refs/heads/*} kaitai-io/ci_targets@$GITHUB_SHA" \ | |
-b "${TARGET}${SUBTARGET}"/"$IMPL-macos-x86_64" \ | |
-- --exclude=.git --exclude=.travis.yml tests/test_out | |
linux: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
tsv: | |
- target: csharp | |
implementation: netcore2.2.103 | |
dotnet: 2.2.103 | |
- target: csharp | |
implementation: netcore3.0.100 | |
dotnet: 3.0.100 | |
env: | |
TARGET: ${{matrix.tsv.target}} | |
SUBTARGET: ${{matrix.tsv.subtarget}} | |
IMPL: ${{matrix.tsv.implementation}} | |
steps: | |
- name: Dump matrix context | |
env: | |
MATRIX_CONTEXT: ${{ toJson(matrix) }} | |
run: echo "$MATRIX_CONTEXT" | |
- uses: actions/checkout@v4 | |
with: | |
submodules: 'true' | |
- uses: actions/setup-dotnet@v4 | |
with: | |
dotnet-version: ${{matrix.tsv.dotnet}} | |
if: matrix.tsv.dotnet | |
- uses: nuget/setup-nuget@v2 | |
with: | |
nuget-version: '5.x' | |
if: matrix.tsv.dotnet | |
- name: GitHub Actions job_id parser | |
uses: Tiryoh/gha-jobid-action@v1 | |
id: job_info | |
with: | |
github_token: ${{github.token}} | |
job_name: "${{github.job}} (${{matrix.tsv.target}}, ${{matrix.tsv.implementation}}, ${{matrix.tsv.dotnet}})" | |
# This is needed if there are more than 30 jobs in the workflow run, | |
# see https://github.com/Tiryoh/gha-jobid-action/issues/1 | |
per_page: 100 | |
- name: prepare | |
run: | | |
git clone --depth 1 https://github.com/kaitai-io/kaitai_struct_tests tests | |
git -C tests rev-parse HEAD | |
ln -s ../compiled tests/compiled | |
./prepare-$TARGET | |
- name: run | |
env: | |
GH_JOB_ID: ${{steps.job_info.outputs.job_id}} | |
GH_HTML_URL: ${{steps.job_info.outputs.html_url}} | |
working-directory: tests | |
run: ./ci-$TARGET$SUBTARGET | |
- name: publish | |
env: | |
BOT_SSH_KEY: ${{secrets.BOT_SSH_KEY}} | |
run: | | |
./push_artifacts/git_config_kaitai_bot | |
./push_artifacts/publish \ | |
-o kaitai-io \ | |
-r ci_artifacts \ | |
-m "Build results of ${GITHUB_REF#refs/heads/*} kaitai-io/ci_targets@$GITHUB_SHA" \ | |
-b "${TARGET}${SUBTARGET}"/"$IMPL-linux-x86_64" \ | |
-- --exclude=.git --exclude=.travis.yml tests/test_out | |
docker: | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
tsv: | |
- target: cpp_stl | |
subtarget: _98 | |
implementation: clang3.4 | |
- target: cpp_stl | |
subtarget: _11 | |
implementation: clang3.4 | |
- target: cpp_stl | |
subtarget: _98 | |
implementation: clang11 | |
- target: cpp_stl | |
subtarget: _11 | |
implementation: clang11 | |
- target: cpp_stl | |
subtarget: _98 | |
implementation: gcc4.8 | |
- target: cpp_stl | |
subtarget: _11 | |
implementation: gcc4.8 | |
- target: cpp_stl | |
subtarget: _98 | |
implementation: gcc11 | |
- target: cpp_stl | |
subtarget: _11 | |
implementation: gcc11 | |
- target: construct | |
implementation: python2.7 | |
- target: construct | |
implementation: python3.4 | |
- target: construct | |
implementation: python3.12 | |
- target: csharp | |
implementation: netcore6.0 | |
- target: graphviz | |
implementation: 9 | |
- target: go | |
implementation: 1.21 | |
- target: java | |
implementation: zulu7 | |
- target: java | |
implementation: temurin8 | |
- target: java | |
implementation: temurin11 | |
- target: java | |
implementation: temurin17 | |
- target: java | |
implementation: temurin21 | |
- target: javascript | |
implementation: nodejs4 | |
- target: javascript | |
implementation: nodejs8 | |
- target: javascript | |
implementation: nodejs10 | |
- target: javascript | |
implementation: nodejs12 | |
- target: javascript | |
implementation: nodejs20 | |
- target: lua | |
implementation: 5.3 | |
- target: nim | |
implementation: 1.6.0 | |
- target: perl | |
implementation: 5.24 | |
- target: perl | |
implementation: 5.38 | |
- target: php | |
implementation: 7.1 | |
- target: php | |
implementation: 8.3 | |
- target: python | |
implementation: 2.7 | |
- target: python | |
implementation: 3.4 | |
- target: python | |
implementation: 3.12 | |
- target: ruby | |
implementation: 1.9 | |
- target: ruby | |
implementation: 2.3 | |
- target: ruby | |
implementation: 3.3 | |
env: | |
TARGET: ${{matrix.tsv.target}} | |
SUBTARGET: ${{matrix.tsv.subtarget}} | |
IMPL: ${{matrix.tsv.implementation}} | |
steps: | |
- name: Dump matrix context | |
env: | |
MATRIX_CONTEXT: ${{ toJson(matrix) }} | |
run: echo "$MATRIX_CONTEXT" | |
- uses: actions/checkout@v4 | |
with: | |
submodules: 'true' | |
- name: docker pull | |
run: | | |
docker pull ghcr.io/kaitai-io/kaitai-"$TARGET"-"$IMPL"-linux-x86_64 | |
- name: download tests | |
run: | | |
git clone --depth 1 https://github.com/kaitai-io/kaitai_struct_tests tests | |
git -C tests rev-parse HEAD | |
cp -r compiled tests/compiled | |
- name: download runtime | |
run: | | |
mkdir -p runtime | |
git clone --depth 1 --recurse-submodules https://github.com/kaitai-io/kaitai_struct_${TARGET}_runtime runtime/$TARGET | |
git -C runtime/$TARGET rev-parse HEAD | |
if: matrix.tsv.target != 'construct' && matrix.tsv.target != 'graphviz' | |
- name: GitHub Actions job_id parser | |
uses: Tiryoh/gha-jobid-action@v1 | |
id: job_info | |
with: | |
github_token: ${{github.token}} | |
job_name: "${{github.job}} (${{matrix.tsv.target}}${{ format('{0}', matrix.tsv.subtarget) != '' && format(', {0}', matrix.tsv.subtarget) || '' }}, ${{matrix.tsv.implementation}})" | |
# This is needed if there are more than 30 jobs in the workflow run, | |
# see https://github.com/Tiryoh/gha-jobid-action/issues/1 | |
per_page: 100 | |
- name: run | |
env: | |
GH_JOB_ID: ${{steps.job_info.outputs.job_id}} | |
GH_HTML_URL: ${{steps.job_info.outputs.html_url}} | |
working-directory: tests | |
run: ./docker-ci -t "$TARGET" -u "$SUBTARGET" -i "$IMPL" | |
# - name: publish as artifact | |
# uses: actions/upload-artifact@v3 | |
# with: | |
# name: test-${{matrix.tsv.target}}${{matrix.tsv.subtarget}}-${{matrix.tsv.implementation}} | |
# path: tests/test_out | |
- name: publish | |
env: | |
BOT_SSH_KEY: ${{secrets.BOT_SSH_KEY}} | |
run: | | |
./push_artifacts/git_config_kaitai_bot | |
./push_artifacts/publish \ | |
-o kaitai-io \ | |
-r ci_artifacts \ | |
-m "Build results of ${GITHUB_REF#refs/heads/*} kaitai-io/ci_targets@$GITHUB_SHA" \ | |
-b "${TARGET}${SUBTARGET}"/"$IMPL-linux-x86_64" \ | |
-- --exclude=.git --exclude=.travis.yml tests/test_out |