diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..7653b5a --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,37 @@ +on: [push] +name: ci + +jobs: + build: + runs-on: ubuntu-latest + steps: + - name: Checkout repo + uses: actions/checkout@v4 + - name: Create empty sdkconfig.defaults + run: touch sdkconfig.defaults + - name: esp-idf build + uses: espressif/esp-idf-ci-action@v1 + with: + esp_idf_version: v5.2 + target: esp32 + path: '.' + - name: Archive build artifacts + uses: actions/upload-artifact@v4 + with: + name: binaries + path: | + build/bootloader/bootloader.bin + build/partition_table/partition-table.bin + build/netshlix.bin + clang-format: + runs-on: ubuntu-latest + container: + image: ubuntu:22.04 + steps: + - name: Checkout repo + uses: actions/checkout@v4 + - name: Install clang-format etc. + run: apt-get update && apt-get install -y clang-format-14 git findutils + - name: Run clang-format + shell: bash + run: shopt -s globstar; clang-format-14 --dry-run --Werror **/*.c **/*.h diff --git a/CMakeLists.txt b/CMakeLists.txt index e9fc862..7958582 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -2,5 +2,7 @@ # CMakeLists in this exact order for cmake to work correctly cmake_minimum_required(VERSION 3.16) +set(SDKCONFIG_DEFAULTS "sdkconfig.defaults.ci;sdkconfig.defaults") + include($ENV{IDF_PATH}/tools/cmake/project.cmake) project(netshlix) diff --git a/main/main.c b/main/main.c index b7c9e3a..cd924ff 100644 --- a/main/main.c +++ b/main/main.c @@ -17,7 +17,6 @@ #include "rtp_jpeg.h" #include "rtp_udp.h" #include "sdkconfig.h" -#include "tjpgd.h" #include "wifi.h" static const char *TAG = "main"; diff --git a/sdkconfig.defaults.ci b/sdkconfig.defaults.ci new file mode 100644 index 0000000..f3caa5d --- /dev/null +++ b/sdkconfig.defaults.ci @@ -0,0 +1,7 @@ +# Config used in CI runs. + +CONFIG_SMALLTV_WIFI_SSID="my-amazing-ssid" +CONFIG_SMALLTV_WIFI_PASSWORD="my-amazing-key" +CONFIG_ESP_WIFI_SOFTAP_SUPPORT=n + +CONFIG_LWIP_NETBUF_RECVINFO=y