Skip to content

only report .BEGIN on success #13

only report .BEGIN on success

only report .BEGIN on success #13

Workflow file for this run

name: Kamaji -- Build HITL Base
on:
push:
branches:
- '**' # Run it on all branches
workflow_dispatch:
jobs:
build_sustainer:
name: Build MIDAS:mcu_hilsim_sustainer
runs-on: ubuntu-latest
defaults:
run:
working-directory: MIDAS
steps:
- uses: actions/checkout@v3
- name: Cache pip
uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
- name: Cache PlatformIO
uses: actions/cache@v3
with:
path: ~/.platformio
key: ${{ runner.os }}-pio-${{ hashFiles('**/platformio.ini') }}
restore-keys: |
${{ runner.os }}-pio-
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.11'
- name: Install PlatformIO
run: |
python -m pip install --upgrade pip
pip install --upgrade platformio
- name: PlatformIO version
run: pio --version
- name: Build mcu_hilsim_sustainer
run: pio run -e mcu_hilsim_sustainer
- name: Upload Artifact for mcu_hilsim_sustainer
uses: actions/upload-artifact@v4
with:
name: firmware-mcu_hilsim_sustainer
path: MIDAS/.pio/build/mcu_hilsim_sustainer/firmware*.*
build_booster:
name: Build MIDAS:mcu_hilsim_booster
runs-on: ubuntu-latest
defaults:
run:
working-directory: MIDAS
steps:
- uses: actions/checkout@v3
- name: Cache pip
uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
- name: Cache PlatformIO
uses: actions/cache@v3
with:
path: ~/.platformio
key: ${{ runner.os }}-pio-${{ hashFiles('**/platformio.ini') }}
restore-keys: |
${{ runner.os }}-pio-
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: '3.11'
- name: Install PlatformIO
run: |
python -m pip install --upgrade pip
pip install --upgrade platformio
- name: PlatformIO version
run: pio --version
- name: Build mcu_hilsim_booster
run: pio run -e mcu_hilsim_booster
- name: Upload Artifact for mcu_hilsim_booster
uses: actions/upload-artifact@v4
with:
name: firmware-mcu_hilsim_booster
path: MIDAS/.pio/build/mcu_hilsim_booster/firmware*.*
notify:
name: Slack Notification (main)
needs: [build_sustainer, build_booster]
runs-on: ubuntu-latest
if: github.ref == 'refs/heads/main'
steps:
- name: Send Slack Summary
uses: rtCamp/action-slack-notify@v2
env:
SLACK_COLOR: ${{ (needs.build_sustainer.result == 'success' && needs.build_booster.result == 'success') && 'good' || 'danger' }}
SLACK_TITLE: "Kamaji Firmware Build"
SLACK_MESSAGE: |
Build results:
- *MIDAS:mcu_hilsim_sustainer*: ${{ needs.build_sustainer.result }}
- *MIDAS:mcu_hilsim_booster*: ${{ needs.build_booster.result }}
:information_source: CI Notifications only run on the `main` branch.
SLACK_WEBHOOK: ${{ secrets.SLACK_WEBHOOK_URL }}