This commit is contained in:
@ -40,15 +40,23 @@ jobs:
|
|||||||
with:
|
with:
|
||||||
path: /root/.arduino15/packages
|
path: /root/.arduino15/packages
|
||||||
key: ${{ runner.os }}-esp32tool-${{ hashFiles("/root/additional.json") }}
|
key: ${{ runner.os }}-esp32tool-${{ hashFiles("/root/additional.json") }}
|
||||||
restore-keys: ${{ runner.os }}-esp32tool-
|
restore-keys: |
|
||||||
- name: 安裝平台
|
${{ runner.os }}-esp32tool-
|
||||||
|
- name: 判斷平台是否安裝
|
||||||
|
id: platformIsInstall
|
||||||
run: |
|
run: |
|
||||||
if [ -d "/root/.arduino15/packages/esp32" ]; then
|
if [ -d "/root/.arduino15/packages/esp32" ]; then
|
||||||
echo "平台已被安裝 跳過安裝"
|
echo "isinstall=true" >> "$GITHUB_OUTPUT"
|
||||||
else
|
else
|
||||||
arduino-cli core update-index
|
echo "isinstall=false" >> "$GITHUB_OUTPUT"
|
||||||
arduino-cli core install esp32:esp32 --additional-urls $additionalurls
|
|
||||||
fi
|
fi
|
||||||
|
- name: 判斷平台是否安裝
|
||||||
|
run: echo ${{ steps.platformIsInstall.outputs.isinstall }}
|
||||||
|
- name: 安裝平台
|
||||||
|
if: ${{ steps.platformIsInstall.outputs.isinstall == "true" }}
|
||||||
|
run: |
|
||||||
|
arduino-cli core update-index
|
||||||
|
arduino-cli core install esp32:esp32 --additional-urls $additionalurls
|
||||||
- name: 安裝庫
|
- name: 安裝庫
|
||||||
run: |
|
run: |
|
||||||
arduino-cli lib install "Adafruit ILI9341@1.6.1"
|
arduino-cli lib install "Adafruit ILI9341@1.6.1"
|
||||||
|
Reference in New Issue
Block a user