Skip to content

Add helper script

Add helper script #1

Workflow file for this run

name: development
on:
push:
branches: ["master"]
paths:
- 'components/**'
- 'main/**'
- 'test/**'
pull_request:
types:
- opened
- edited
- synchronize
- reopened
paths:
- 'components/**'
- 'main/**'
- 'test/**'
workflow_dispatch:
env:
ESP_DOCKER_IMAGE: gfurtadoalmeida/esp32-docker-sonar:v5.1
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Docker Login
uses: docker/login-action@v3
with:
username: ${{secrets.DOCKER_USERNAME}}
password: ${{secrets.DOCKER_TOKEN}}
- name: Pull ESP-IDF Image
shell: pwsh
run: docker pull ${{env.ESP_DOCKER_IMAGE}}
- name: Build with Sonar
shell: pwsh
run: docker run --rm --env SONARCLOUD_ORGANIZATION=${{secrets.SONARCLOUD_ORGANIZATION}} --env SONARCLOUD_TOKEN=${{secrets.SONARCLOUD_TOKEN}} --env LC_ALL='C.UTF-8' -v ${{github.workspace}}:/project -w /project ${{env.ESP_DOCKER_IMAGE}} idf.py build
- name: Build Test
shell: pwsh
run: docker run --rm --env LC_ALL='C.UTF-8' -v ${{github.workspace}}:/project -w /project ${{env.ESP_DOCKER_IMAGE}} idf.py -C ./test build