Skip to content

update example

update example #13

Workflow file for this run

name: validate and compile on all branch pushes
on:
push:
workflow_dispatch:
env:
MLM_LICENSE_TOKEN: ${{ secrets.MATLAB_BATCH_TOKEN }}
jobs:
validate-exports:
name: validate exports.txt
runs-on: ubuntu-latest
steps:
- name: checkout repo
uses: actions/checkout@v4
- name: check if all files listed in exports.txt exist
run: ./validate.sh
test-compile:
needs: validate-exports
runs-on: ubuntu-latest
steps:
- name: checkout repo
uses: actions/checkout@v4
- name: get latest h5parser release
uses: robinraju/release-downloader@v1.11
with:
repository: hytech-racing/h5parser
fileName: h5parser.mltbx
latest: true
- name: setup MATLAB
uses: matlab-actions/setup-matlab@v2
with:
release: R2024b
products: MATLAB_Compiler_SDK
cache: true
- name: install h5parser toolbox
uses: matlab-actions/run-command@v2
with:
command: matlab.addons.toolbox.installToolbox("h5parser.mltbx")
- name: get list of exported .m files
run: |
scripts=$(./get_scripts.sh)
echo "SCRIPTS=$scripts" >> $GITHUB_ENV
- name: compile scripts
uses: matlab-actions/run-command@v2
with:
command: scripts = jsondecode(getenv("SCRIPTS")), archive = compiler.build.productionServerArchive(scripts)