feat: Generate checksums for the frontend
This commit is contained in:
parent
5c1332da36
commit
eed1149b0c
7
.gitignore
vendored
7
.gitignore
vendored
@ -3,6 +3,10 @@
|
||||
**/.cache/
|
||||
**/dist/
|
||||
|
||||
# Frontend ignores
|
||||
frontend/lateinicus-web.tar.gz
|
||||
frontend/sha512sums
|
||||
|
||||
# Backend ignores
|
||||
backend/backend.tar
|
||||
backend/backend.tgz
|
||||
@ -10,3 +14,6 @@ backend/backend.tgz
|
||||
# Server ignores
|
||||
server/*.pem
|
||||
server/db/
|
||||
|
||||
# Script ignores
|
||||
scripts/bee-movie.txt
|
@ -7,6 +7,7 @@ watch: node_modules
|
||||
|
||||
clean:
|
||||
rm -rf dist/
|
||||
rm -f sha512sums
|
||||
|
||||
.PHONY: build
|
||||
build: prod
|
||||
@ -16,6 +17,10 @@ prod: node_modules clean
|
||||
./node_modules/.bin/parcel build --out-dir dist src/lost.html src/error.html
|
||||
sed -e "s/\/src/\/app\/src/g" --in-place dist/app/index.html
|
||||
|
||||
@echo Generate checksums
|
||||
find ./dist/ -exec sha512sum {} + | awk -F \. '{ if($$4 != "map") print $$0}' | awk -F \/ '{ if($$3 == "lost.html") {} else if ($$3 == "error.html") {} else print $$0}' > sha512sums
|
||||
|
||||
@echo Creating tarball
|
||||
tar -czf lateinicus-web.tar.gz dist/
|
||||
|
||||
dev: node_modules clean
|
||||
|
Reference in New Issue
Block a user