Minor cleanup #1022
Workflow file for this run
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: Build OSW-OS (Ubuntu, additional features) | |
on: | |
push: | |
paths_ignore: '["*.md", "**/scripts/screen_capture/**"]' | |
pull_request: | |
branches: [ master, develop ] | |
jobs: | |
check_skip: | |
runs-on: ubuntu-latest | |
outputs: | |
should_skip: ${{ steps.skip_check.outputs.should_skip }} | |
steps: | |
- id: skip_check | |
uses: fkirc/[email protected] | |
with: | |
concurrent_skipping: 'same_content_newer' | |
skip_after_successful_duplicate: 'true' | |
Find-feature: | |
runs-on: ubuntu-latest | |
needs: check_skip | |
if: ${{ needs.check_skip.outputs.should_skip != 'true' }} | |
steps: | |
- name: Checkout repository and submodules | |
# uses: actions/checkout@v3 # incompatible with git lfs cache bandwidth calcs (https://github.com/actions/checkout/issues/165) | |
uses: nschloe/[email protected] | |
with: | |
submodules: recursive | |
lfs: 'true' | |
- id: get-flag | |
run: | | |
echo "feature=$(python3 .github/getWorkflowMatrix.py all_flags)" >> $GITHUB_OUTPUT | |
- id: default_mod | |
run: | | |
echo "default_model=$(python3 .github/getWorkflowMatrix.py default_model)" >> $GITHUB_OUTPUT | |
- id: default_lang | |
run: | | |
echo "default_language=$(python3 .github/getWorkflowMatrix.py default_language)" >> $GITHUB_OUTPUT | |
outputs: | |
feature: ${{ steps.get-flag.outputs.feature }} | |
default_model: ${{ steps.default_mod.outputs.default_model }} | |
default_language: ${{ steps.default_lang.outputs.default_language }} | |
build-OSW: | |
needs: Find-feature | |
runs-on: ubuntu-latest | |
strategy: | |
fail-fast: false | |
matrix: | |
feature: ${{ fromJson(needs.Find-feature.outputs.feature) }} | |
model: ${{ fromJson(needs.Find-feature.outputs.default_model) }} | |
language: ${{ fromJson(needs.Find-feature.outputs.default_language) }} | |
steps: | |
- name: Checkout repository and submodules | |
# uses: actions/checkout@v3 # incompatible with git lfs cache bandwidth calcs (https://github.com/actions/checkout/issues/165) | |
uses: nschloe/[email protected] | |
with: | |
submodules: recursive | |
lfs: 'true' | |
- name: Cache pip | |
uses: actions/cache@v3 | |
with: | |
path: ~/.cache/pip | |
key: pip-${{ runner.os }} | |
- name: Cache PlatformIO | |
uses: actions/cache@v3 | |
with: | |
path: ~/.platformio | |
key: platformio-${{ runner.os }} | |
- name: Install swig | |
run: sudo apt-get update && sudo apt-get -y install swig | |
- name: Set up Python | |
uses: actions/setup-python@v4 | |
with: | |
python-version: '3.10' | |
- name: Install PlatformIO | |
run: python -m pip install --upgrade pip && pip install --upgrade platformio | |
- name: Rename config | |
run: mv include/config.h.example include/config.h | |
- name: Compile language ${{ matrix.language }} model ${{ matrix.model }} feature ${{ matrix.feature }} | |
run: python3 .github/buildFirmware.py -l "${{ matrix.language }}" -m "${{ matrix.model }}" -f "${{ matrix.feature }}" -b debug |