Skip to content

Commit

Permalink
Create Status_led_pir_0_14-b3_esp8266.yaml
Browse files Browse the repository at this point in the history
  • Loading branch information
dosipod authored Jan 17, 2024
1 parent 47179e7 commit f8ca9ba
Showing 1 changed file with 55 additions and 0 deletions.
55 changes: 55 additions & 0 deletions .github/workflows/Status_led_pir_0_14-b3_esp8266.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
name: Status_led_gpio02_0_14-b3_esp8266

on:
workflow_dispatch:

jobs:
build:

runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: 3.9

- name: Install PlatformIO
run: |
python -m pip install --upgrade pip
pip install --upgrade platformio
- name: Set up Node.js
uses: actions/setup-node@v4
- name: Run PlatformIO
run: |
rm -rf /tmp/WLEDtemp/* || true
mkdir -p /tmp/WLEDtemp
wget https://api.github.com/repos/Aircoookie/WLED/zipball/v0.14.1-b3 -O /tmp/WLEDtemp/mm.zip
unzip /tmp/WLEDtemp/mm.zip -d /tmp/WLEDtemp
find /tmp/WLEDtemp -maxdepth 1 -mindepth 1 -name "*" -type d >> /tmp/WLEDtemp/wledfoldername
cd `cat /tmp/WLEDtemp/wledfoldername`
npm install
echo '[env:custom_build]' >>platformio.ini
echo 'extends = env:nodemcuv2' >>platformio.ini
echo 'build_flags = ${env:nodemcuv2.build_flags} -D STATUSLED=2 -D USERMOD_PIRSWITCH' >>platformio.ini
echo 'lib_deps = ' >>platformio.ini
echo ' ${env:nodemcuv2.lib_deps}' >>platformio.ini
echo ' OneWire@~2.3.5' >>platformio.ini
pio run -e custom_build || pio run -e custom_build
- name: Copy Files
run: |
cd $GITHUB_WORKSPACE
git rm -r $GITHUB_WORKSPACE/*.bin || true
WLEDFOLDERNAME=`cat /tmp/WLEDtemp/wledfoldername`
cp ${WLEDFOLDERNAME}/build_output/firmware/custom_build.bin $GITHUB_WORKSPACE/
date -I | tr -d '\n' >$GITHUB_WORKSPACE/last_update_date.txt
- name: Commit Files
run: |
cd $GITHUB_WORKSPACE
git config user.name "GitHub Actions Bot"
git config user.email "<>"
git add $GITHUB_WORKSPACE/custom_build.bin
git add $GITHUB_WORKSPACE/last_update_date.txt
git commit -m "Commit Custom Build"
git push origin main

0 comments on commit f8ca9ba

Please sign in to comment.