cleanup + git commit info

This commit is contained in:
Simon Gardling
2022-02-24 20:47:15 -05:00
parent 1ddc3774a1
commit 6f8a7c9cc2
7 changed files with 51 additions and 50 deletions

14
push.sh
View File

@@ -3,20 +3,6 @@ set -e #kill script if error occurs
bash build.sh
rm -fr tmp | true #delete tmp folder if exists
mkdir tmp tmp/pkg
cp -r pkg/integral_site_bg.wasm pkg/integral_site.js tmp/pkg/
cp www/index.html www/style.css tmp/
sed -i 's/\.\.\/pkg/\.\/pkg/g' tmp/index.html
# put the commit at the beginning of index.html
mv tmp/index.html tmp/index.html.bak
commit_comment="<!-- Commit: $(git rev-parse HEAD) -->"
echo $commit_comment > tmp/index.html
cat tmp/index.html.bak >> tmp/index.html
rm -fr tmp/index.html.bak
echo "rsyncing"
rsync -av --delete --info=progress2 tmp/ rpi-public:/mnt/hdd/http_share/integral-demo/
rsync -av --delete --info=progress2 --exclude=".git" tmp/ ../integral-demo/