Skip to content

Add MATLAB code analyzer #2

Add MATLAB code analyzer

Add MATLAB code analyzer #2

Workflow file for this run

name: Matlab Analyzer
on:
workflow_dispatch:
push:
branches: ["main"]
pull_request:
# The branches below must be a subset of the branches above
branches: ["main"]
jobs:
matlab-analyzer:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Dependencies
uses: ./.github/actions/setup-dependencies
- name: Setup MATLAB
id: setup-matlab
uses: matlab-actions/setup-matlab@v2
with:
release: "R2024a"
- name: Set MATLAB_HOME and MATLAB_VERSION
run: |
# Needed for MATLAB R2024a
sudo apt install -y libgtk2.0-0
echo "MATLAB_VERSION=R2024a" >> $GITHUB_ENV
echo "MATLAB_HOME=${{ steps.setup-matlab.outputs.matlabroot }}" >> $GITHUB_ENV
shell: bash
- name: Build MATLAB on Ubuntu
uses: ./.github/actions/build
timeout-minutes: 90
with:
working_directory: "matlab"
build_cpp_and_python: true
- name: MATLAB Analyzer
working-directory: matlab/config
run: $(MATLAB_COMMAND) matlab_analyzer.m
shell: bash
- name: Upload Analyzer Report
uses: actions/upload-artifact@v4
with:
name: matlab-analyzer-report
path: matlab/config/result.json
if-no-files-found: ignore
if: always()