kopia lustrzana https://github.com/dl9rdz/rdz_ttgo_sonde
(travis test for fs ota)
rodzic
374f84115b
commit
debaf57f88
|
@ -63,6 +63,8 @@ commit_website_files() {
|
||||||
git add ${BRANCH}/${VERSION}-changelog.txt
|
git add ${BRANCH}/${VERSION}-changelog.txt
|
||||||
echo "<html><body><p>${VERSION}</p></body></html>" > ${BRANCH}/update-info.html
|
echo "<html><body><p>${VERSION}</p></body></html>" > ${BRANCH}/update-info.html
|
||||||
git add ${BRANCH}/update-info.html
|
git add ${BRANCH}/update-info.html
|
||||||
|
${MYPATH}/scripts/makefsupdate.py ${MYPATH}/RX_FSK/data/ > ${BRANCH}/update.fs.bin
|
||||||
|
git add ${BRANCH}/update.fs.bin
|
||||||
git commit --message "Travis build: $TRAVIS_BUILD_NUMBER"
|
git commit --message "Travis build: $TRAVIS_BUILD_NUMBER"
|
||||||
}
|
}
|
||||||
upload_files() {
|
upload_files() {
|
||||||
|
|
|
@ -0,0 +1,19 @@
|
||||||
|
#!/usr/bin/env python3
|
||||||
|
from os import listdir
|
||||||
|
import sys
|
||||||
|
|
||||||
|
path = sys.argv[1]
|
||||||
|
|
||||||
|
# create update.fs.bin with content:
|
||||||
|
# filename size CR LF
|
||||||
|
# data for filename ...
|
||||||
|
|
||||||
|
files = listdir(path)
|
||||||
|
files = list(filter(lambda x: x.endswith('.js') or x.endswith('.html') or x.endswith('.css'), files))
|
||||||
|
for f in files:
|
||||||
|
with open(path+"/"+f,"rb") as myf:
|
||||||
|
data=myf.read(-1)
|
||||||
|
head = str.encode(f + " " + str(len(data)) + "\r\n")
|
||||||
|
sys.stdout.buffer.write(head)
|
||||||
|
sys.stdout.buffer.write(data)
|
||||||
|
|
Ładowanie…
Reference in New Issue