* fixed timestamp for alarms send over MqTT
* auto-patch of `AsyncWebServer` #834, #1036
* Update documentation in Git regarding `ESP8266` default NRF24 pin assignments
This commit is contained in:
lumapu 2023-08-18 00:23:40 +02:00
parent ac53925a24
commit ed268d1b63
7 changed files with 54 additions and 9 deletions

20
scripts/applyPatches.py Normal file
View file

@ -0,0 +1,20 @@
import os
import subprocess
Import("env")
def applyPatch(libName, patchFile):
os.chdir('.pio/libdeps/' + env['PIOENV'] + '/' + libName)
process = subprocess.run(['git', 'apply', '--reverse', '--check', '../../../../' + patchFile], stdout=subprocess.DEVNULL, stderr=subprocess.DEVNULL)
if (process.returncode == 0):
print('\'' + patchFile + '\' already applied')
else:
process = subprocess.run(['git', 'apply', '../../../../' + patchFile])
if (process.returncode == 0):
print('\'' + patchFile + '\' applied')
else:
print('applying \'' + patchFile + '\' failed')
# list of patches to apply (relative to /src)
applyPatch("ESP Async WebServer", "../patches/AsyncWeb_Prometheus.patch")