From 67d2785258bb2b77bd060ab44347bbee22614e71 Mon Sep 17 00:00:00 2001 From: Tomas Rezucha Date: Fri, 13 Jan 2023 11:32:07 +0100 Subject: [PATCH] ci: Build test_app only on relevant changes --- .github/PULL_REQUEST_TEMPLATE.md | 12 ++++-------- .github/PULL_REQUEST_TEMPLATE/pr_template_bsp.md | 14 ++++++++++++++ .github/workflows/build_test.yml | 6 +++++- 3 files changed, 23 insertions(+), 9 deletions(-) create mode 100644 .github/PULL_REQUEST_TEMPLATE/pr_template_bsp.md diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md index b5372ea84..e6c8eee80 100644 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -1,12 +1,8 @@ -# Checklist for new Board Support package or Component +# ESP-BSP Pull Request checklist -- [ ] Component contains License -- [ ] Component contains README.md -- [ ] Project [README.md](../README.md) updated -- [ ] Component contains idf_component.yml file with `url` field defined -- [ ] Component was added to CI [upload job](https://github.com/espressif/esp-bsp/blob/master/.github/workflows/upload_component.yml#L17) -- [ ] New files were added to CI build job -- [ ] _Optional:_ Component contains unit tests +> Note: For new BSPs create a PR with this [link](https://github.com/espressif/esp-bsp/compare/main...my-branch?quick_pull=1&template=pr_template_bsp.md). + +- [ ] Version of modified component bumped - [ ] CI passing # Change description diff --git a/.github/PULL_REQUEST_TEMPLATE/pr_template_bsp.md b/.github/PULL_REQUEST_TEMPLATE/pr_template_bsp.md new file mode 100644 index 000000000..ff2986132 --- /dev/null +++ b/.github/PULL_REQUEST_TEMPLATE/pr_template_bsp.md @@ -0,0 +1,14 @@ +# Checklist for new Board Support package or Component + +- [ ] Component contains License +- [ ] Component contains README.md +- [ ] Project [README.md](../README.md) updated +- [ ] Component contains idf_component.yml file with `url` field defined +- [ ] Component was added to CI [upload job](https://github.com/espressif/esp-bsp/blob/master/.github/workflows/upload_component.yml#L17) +- [ ] New files were added to CI build job +- [ ] New BSP definitions added to [build_example_for_all_bsps.sh](./build_example_for_all_bsps.sh) and to [bsp_ext.py](../examples/bsp_ext.py) +- [ ] _Optional:_ Component contains unit tests +- [ ] CI passing + +# Change description +_Please describe your change here_ diff --git a/.github/workflows/build_test.yml b/.github/workflows/build_test.yml index 71042b935..3e86ad799 100644 --- a/.github/workflows/build_test.yml +++ b/.github/workflows/build_test.yml @@ -3,6 +3,10 @@ name: Build Test Application on: pull_request: types: [opened, reopened, synchronize] + paths: + - 'components/**' + - 'test_app/**' + - '.github/workflows/build_test.yml' jobs: build: @@ -20,9 +24,9 @@ jobs: - name: Build ESP-BSP Test Application env: IDF_TARGET: ${{ matrix.idf_target }} + working-directory: test_app shell: bash run: | - cd test_app . ${IDF_PATH}/export.sh export PEDANTIC_FLAGS="-DIDF_CI_BUILD -Werror -Werror=deprecated-declarations -Werror=unused-variable -Werror=unused-but-set-variable -Werror=unused-function" export EXTRA_CFLAGS="${PEDANTIC_FLAGS} -Wstrict-prototypes"