# Copyright (c) 2021 Project CHIP Authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

name: Build example - Mbed OS

on:
    push:
    pull_request:
    merge_group:
    workflow_dispatch:

concurrency:
    group: ${{ github.ref }}-${{ github.workflow }}-${{ (github.event_name == 'pull_request' && github.event.number) || (github.event_name == 'workflow_dispatch' && github.run_number) || github.sha }}
    cancel-in-progress: true

env:
    CHIP_NO_LOG_TIMESTAMPS: true
    # XXX: Workaround for https://github.com/actions/cache/issues/1141
    SEGMENT_DOWNLOAD_TIMEOUT_MINS: 3

jobs:
    mbedos:
        name: Mbed OS examples building
        timeout-minutes: 200

        env:
            BUILD_TYPE: mbedos
            APP_PROFILE: release
            APP_TARGET: CY8CPROTO_062_4343W

        runs-on: ubuntu-latest
        if: github.actor != 'restyled-io[bot]'

        container:
            image: connectedhomeip/chip-build-mbed-os:0.7.3
            volumes:
                - "/tmp/bloat_reports:/tmp/bloat_reports"

        steps:
            - uses: Wandalen/wretry.action@v1.0.36
              name: Checkout
              with:
                  action: actions/checkout@v3.5.2
                  with: |
                      token: ${{ github.token }}
                  attempt_limit: 3
                  attempt_delay: 2000
            - name: Checkout submodules
              run: scripts/checkout_submodules.py --allow-changing-global-git-config --shallow --platform mbed

            - name: Detect changed paths
              uses: dorny/paths-filter@v2
              id: changed_paths
              with:
                  filters: |
                      mbed:
                        - '**/mbed/**'
                      pigweedapp:
                        - 'examples/pigweed-app/mbed/**'

            - name: Set up environment for size reports
              if: ${{ !env.ACT }}
              env:
                  GH_CONTEXT: ${{ toJson(github) }}
              run: scripts/tools/memory/gh_sizes_environment.py "${GH_CONTEXT}"

            - name: Bootstrap cache
              uses: buildjet/cache@v3
              timeout-minutes: 10
              with:
                  key: ${{ runner.os }}-env-${{ hashFiles('scripts/setup/*', 'third_party/pigweed/**') }}
                  path: |
                      .environment
                      build_overrides/pigweed_environment.gni
            - name: Bootstrap
              timeout-minutes: 10
              run: bash scripts/bootstrap.sh
            - name: Uploading bootstrap logs
              uses: actions/upload-artifact@v3
              if: ${{ always() && !env.ACT }}
              with:
                  name: bootstrap-logs
                  path: |
                      .environment/gn_out/.ninja_log
                      .environment/pigweed-venv/*.log

            - name: Build lock-app example
              timeout-minutes: 20
              run: |
                  scripts/examples/mbed_example.sh -a=lock-app -b=$APP_TARGET -p=$APP_PROFILE
                  .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
                    mbed $APP_TARGET+$APP_PROFILE lock-app \
                    examples/lock-app/mbed/build-CY8CPROTO_062_4343W/release/chip-mbed-lock-app-example.elf \
                    /tmp/bloat_reports/

            - name: Build lighting-app example
              if: github.event_name == 'push' || steps.changed_paths.outputs.mbed == 'true'
              timeout-minutes: 20
              run: |
                  scripts/examples/mbed_example.sh -a=lighting-app -b=$APP_TARGET -p=$APP_PROFILE
                  .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
                    mbed $APP_TARGET+$APP_PROFILE lighting-app \
                    examples/lighting-app/mbed/build-CY8CPROTO_062_4343W/release/chip-mbed-lighting-app-example.elf \
                    /tmp/bloat_reports/

            - name: Build pigweed-app example
              if: github.event_name == 'push' || steps.changed_paths.outputs.pigweedapp == 'true'
              timeout-minutes: 20
              run: |
                  scripts/examples/mbed_example.sh -a=pigweed-app -b=$APP_TARGET -p=$APP_PROFILE
                  .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
                    mbed $APP_TARGET+$APP_PROFILE pigweed-app \
                    examples/pigweed-app/mbed/build-CY8CPROTO_062_4343W/release/chip-mbed-pigweed-app-example.elf \
                    /tmp/bloat_reports/

            - name: Build all-clusters-app example
              if: github.event_name == 'push' || steps.changed_paths.outputs.mbed == 'true'
              timeout-minutes: 20
              run: |
                  scripts/examples/mbed_example.sh -a=all-clusters-app -b=$APP_TARGET -p=$APP_PROFILE
                  .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
                    mbed $APP_TARGET+$APP_PROFILE all-clusters-app \
                    examples/all-clusters-app/mbed/build-CY8CPROTO_062_4343W/release/chip-mbed-all-clusters-app-example.elf \
                    /tmp/bloat_reports/

            - name: Build all-clusters-minimal-app example
              if: github.event_name == 'push' || steps.changed_paths.outputs.mbed == 'true'
              timeout-minutes: 20
              run: |
                  scripts/examples/mbed_example.sh -a=all-clusters-minimal-app -b=$APP_TARGET -p=$APP_PROFILE
                  .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
                    mbed $APP_TARGET+$APP_PROFILE all-clusters-minimal-app \
                    examples/all-clusters-minimal-app/mbed/build-CY8CPROTO_062_4343W/release/chip-mbed-all-clusters-minimal-app-example.elf \
                    /tmp/bloat_reports/

            - name: Build shell example
              if: github.event_name == 'push' || steps.changed_paths.outputs.mbed == 'true'
              timeout-minutes: 20
              run: |
                  scripts/examples/mbed_example.sh -a=shell -b=$APP_TARGET -p=$APP_PROFILE
                  .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
                    mbed $APP_TARGET+$APP_PROFILE shell \
                    examples/shell/mbed/build-CY8CPROTO_062_4343W/release/chip-mbed-shell-example.elf \
                    /tmp/bloat_reports/

            - name: Build ota-requestor-app example
              if: github.event_name == 'push' || steps.changed_paths.outputs.mbed == 'true'
              timeout-minutes: 20
              run: |
                  scripts/examples/mbed_example.sh -a=ota-requestor-app -b=$APP_TARGET -p=$APP_PROFILE
                  .environment/pigweed-venv/bin/python3 scripts/tools/memory/gh_sizes.py \
                    mbed $APP_TARGET+$APP_PROFILE shell \
                    examples/ota-requestor-app/mbed/build-CY8CPROTO_062_4343W/release/chip-mbed-ota-requestor-app-example.elf \
                    /tmp/bloat_reports/

            - name: Build unit tests
              # Temporarily disable build due to running out of flash space
              if: false
              timeout-minutes: 20
              run: scripts/tests/mbed/mbed_unit_tests.sh -b=$APP_TARGET -p=$APP_PROFILE

            - name: Uploading Size Reports
              uses: actions/upload-artifact@v3
              if: ${{ !env.ACT }}
              with:
                  name: Size,Mbed-Examples,${{ env.GH_EVENT_PR }},${{ env.GH_EVENT_HASH }},${{ env.GH_EVENT_PARENT }},${{ github.event_name }}
                  path: |
                      /tmp/bloat_reports/
