Skip to content

Update main.yml

Update main.yml #30

Workflow file for this run

name: CI
# Controls when the action will run.
on:
# Triggers the workflow on push or pull request events
push:
pull_request:
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "syntax_check"
syntax_checks:
timeout-minutes: 5
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 5
- name: Get moparser
run: git clone --depth=1 https://github.com/modelica-tools/ModelicaSyntaxChecker
- name: Check file encoding
run: "! find . -name '*.mo' -exec bash -c 'iconv -o /dev/null -f utf8 -t utf8 \"{}\" |& sed \"s,^,{}: ,\"' ';' | grep '.'"
- name: Check for UTF-8 BOM
run: "! find . -name '*.mo' -print0 | xargs -0 grep -l $'^\\xEF\\xBB\\xBF' | grep ."
- name: Check syntax
run: |
echo "::add-matcher::./.github/moparser.json"
ModelicaSyntaxChecker/Linux64/moparser -v 3.6 -r Chemical
echo "::remove-matcher owner=moparser::"