feat: Generate checksums for the frontend
This commit is contained in:
parent
5c1332da36
commit
eed1149b0c
9
.gitignore
vendored
9
.gitignore
vendored
@ -3,10 +3,17 @@
|
|||||||
**/.cache/
|
**/.cache/
|
||||||
**/dist/
|
**/dist/
|
||||||
|
|
||||||
|
# Frontend ignores
|
||||||
|
frontend/lateinicus-web.tar.gz
|
||||||
|
frontend/sha512sums
|
||||||
|
|
||||||
# Backend ignores
|
# Backend ignores
|
||||||
backend/backend.tar
|
backend/backend.tar
|
||||||
backend/backend.tgz
|
backend/backend.tgz
|
||||||
|
|
||||||
# Server ignores
|
# Server ignores
|
||||||
server/*.pem
|
server/*.pem
|
||||||
server/db/
|
server/db/
|
||||||
|
|
||||||
|
# Script ignores
|
||||||
|
scripts/bee-movie.txt
|
@ -7,6 +7,7 @@ watch: node_modules
|
|||||||
|
|
||||||
clean:
|
clean:
|
||||||
rm -rf dist/
|
rm -rf dist/
|
||||||
|
rm -f sha512sums
|
||||||
|
|
||||||
.PHONY: build
|
.PHONY: build
|
||||||
build: prod
|
build: prod
|
||||||
@ -16,6 +17,10 @@ prod: node_modules clean
|
|||||||
./node_modules/.bin/parcel build --out-dir dist src/lost.html src/error.html
|
./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
|
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/
|
tar -czf lateinicus-web.tar.gz dist/
|
||||||
|
|
||||||
dev: node_modules clean
|
dev: node_modules clean
|
||||||
|
Reference in New Issue
Block a user