doc: add wiring diagram of fan controller #138
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: ESPHome Full Build CI | |
| on: [push, pull_request] | |
| jobs: | |
| # Step 1 : List all .yaml files | |
| list-files: | |
| runs-on: ubuntu-latest | |
| outputs: | |
| matrix: ${{ steps.set-matrix.outputs.matrix }} | |
| steps: | |
| - name: 📥 Checkout repository | |
| uses: actions/checkout@v6 | |
| - name: 📄 Build matrix | |
| id: set-matrix | |
| run: | | |
| # Liste les .yaml à la racine, exclut secrets.yaml | |
| FILES=$(ls *.yaml | grep -v "secrets.yaml" | jq -R -s -c 'split("\n")[:-1]') | |
| echo "matrix=$FILES" >> "$GITHUB_OUTPUT" | |
| # Step 2 : Check Coverage | |
| coverage: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: 📥 Checkout repository | |
| uses: actions/checkout@v6 | |
| - name: 🧪 Run Coverage Check | |
| env: | |
| TERM: xterm | |
| run: | | |
| ./tools/check_coverage.sh | |
| # Step 3 : Build & Validate Documentation | |
| docs: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: 📥 Checkout repository | |
| uses: actions/checkout@v6 | |
| - name: 🐍 Set up Python | |
| uses: actions/setup-python@v6 | |
| with: | |
| python-version: "3.x" | |
| - name: 📦 Install dependencies | |
| run: | | |
| python -m pip install --upgrade pip | |
| sed -i "/esphome/d" requirements.txt | |
| pip install -r requirements.txt | |
| - name: 🏗️ MkDocs Build | |
| run: | | |
| # Remove plugin not supported in CI which has no impact in documentation check | |
| sed -i '/git-revision-date-localized:/,+1d' mkdocs.yml | |
| # The --strict flag causes the build to fail if any warnings or broken links are detected | |
| mkdocs build --strict | |
| # Step 4 : Compile files | |
| build: | |
| needs: list-files | |
| runs-on: ubuntu-latest | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| file: ${{ fromJson(needs.list-files.outputs.matrix) }} | |
| steps: | |
| - name: 📥 Checkout repository | |
| uses: actions/checkout@v6 | |
| - name: 🔄 Update ref to current branch | |
| run: | | |
| BRANCH_NAME=${GITHUB_HEAD_REF:-$GITHUB_REF_NAME} | |
| echo "Replace 'ref: main' by 'ref: $BRANCH_NAME' in ${{ matrix.file }}" | |
| sed -i "s@ref: main@ref: ${BRANCH_NAME}@g" "${{ matrix.file }}" | |
| - name: 🤫 Create dummy secrets.yaml | |
| run: | | |
| cat > secrets.yaml << 'EOF' | |
| wifi_ssid: "ssid" | |
| wifi_password: "password" | |
| api_encryption_key: "/TQQDQvCLeJ1RfoihmoIUjSk+PtvOF9oUCoOGI53ie8=" | |
| proxy_api_encryption_key: "/TQQDQvCLeJ1RfoihmoIUjSk+PtvOF9oUCoOGI53ie8=" | |
| solar_water_heater_api_encryption_key: "/TQQDQvCLeJ1RfoihmoIUjSk+PtvOF9oUCoOGI53ie8=" | |
| wt32_eth01_api_encryption_key: "/TQQDQvCLeJ1RfoihmoIUjSk+PtvOF9oUCoOGI53ie8=" | |
| solar_router_ota_password: "/TQQDQvCLeJ1RfoihmoIUjSk+PtvOF9oUCoOGI53ie8=" | |
| solar_water_heater_ota_password: "/TQQDQvCLeJ1RfoihmoIUjSk+PtvOF9oUCoOGI53ie8=" | |
| wt32_eth01_ota_password: "/TQQDQvCLeJ1RfoihmoIUjSk+PtvOF9oUCoOGI53ie8=" | |
| EOF | |
| - name: 🔍 Get ESPHome version | |
| id: esphome-version | |
| run: | | |
| pip install esphome | |
| VERSION=$(esphome version | awk '{print $2}') | |
| echo "version=$VERSION" >> "$GITHUB_OUTPUT" | |
| echo "ESPHome version: $VERSION" | |
| - name: 💾 Cache PlatformIO & ESPHome (shared) | |
| uses: actions/cache@v5 | |
| with: | |
| path: | | |
| ~/.cache/pip | |
| ~/.platformio | |
| .esphome | |
| key: ${{ runner.os }}-esphome-${{ steps.esphome-version.outputs.version }} | |
| restore-keys: | | |
| ${{ runner.os }}-esphome-${{ steps.esphome-version.outputs.version }} | |
| ${{ runner.os }}-esphome- | |
| - name: 🚀 Build ESPHome Binary | |
| uses: esphome/build-action@v7 | |
| with: | |
| yaml-file: ${{ matrix.file }} | |
| version: latest | |
| # Décommente si tu veux récupérer les firmwares | |
| # - name: 📦 Upload firmware | |
| # uses: actions/upload-artifact@v4 | |
| # with: | |
| # name: ${{ matrix.file }}-firmware | |
| # path: .esphome/build/${{ matrix.file }}/**/firmware.bin | |
| # if-no-files-found: error |