ESP32-A1S.yml 1.1 KB

123456789101112131415161718192021222324252627282930313233343536
  1. # This is a basic workflow to help you get started with Actions
  2. name: ESP32-A1S
  3. on:
  4. push:
  5. branches: [ master-cmake ]
  6. pull_request:
  7. branches: [ master-cmake ]
  8. jobs:
  9. build:
  10. runs-on: ubuntu-latest
  11. steps:
  12. - name: Set target
  13. run: echo "TARGET_BUILD_NAME=ESP32-A1S" >> $GITHUB_ENV
  14. id: target-name-generator
  15. - name: Show Target
  16. run: echo "Target is ${TARGET_BUILD_NAME}"
  17. - uses: actions/checkout@v2
  18. with:
  19. submodules: true
  20. - name: Generate build number
  21. id: buildnumber
  22. uses: einaregilsson/build-number@v2
  23. with:
  24. token: ${{secrets.github_token}}
  25. - name: Cache build
  26. id: cache-build
  27. uses: actions/cache@v1
  28. with:
  29. path: ${{github.workspace}}/build
  30. key: ${{ runner.os }}-${TARGET_BUILD_NAME}
  31. - name: Build the firmware
  32. run: |
  33. docker run --rm -v $PWD:/project -w /project espressif/idf:release-v4.0 /bin/bash -c "cp build-scripts/${TARGET_BUILD_NAME}-sdkconfig.defaults sdkconfig && export PROJECT_VER=${TARGET_BUILD_NAME}-${{ steps.buildnumber.outputs.build_number }} && idf.py build"