Backup deployment scripts

This commit is contained in:
2023-06-23 17:51:34 +02:00
parent 990a2dff19
commit 7b88f5e792
4 changed files with 150 additions and 7 deletions

View File

@@ -0,0 +1,7 @@
#! /bin/bash
LINE=`grep -oP '.*main.*": ".*"' /home/mz/deployment/Frontend/ngsw.json`
IFS=': ' read -r -a array <<< $LINE
FILE="${array[0]//\"/}"
NEWHASH=($(sha1sum /home/mz/deployment/Frontend$FILE))
OLDHASH="${array[1]//\"/}"
sed -i "s/$OLDHASH/$NEWHASH/g" /home/mz/deployment/Frontend/ngsw.json