tunuifranken.info/create-index.sh

13 lines
300 B
Bash
Raw Normal View History

2021-01-04 13:53:39 +01:00
#!/bin/bash
[ "$HOSTNAME" != lime2 ] || exit 1
2021-01-05 11:11:51 +01:00
echo "Updating index.html"
2021-01-04 13:53:39 +01:00
chmod 644 ./index.html
2021-01-05 11:11:51 +01:00
awk -v header="$(<./header.html)" '{sub(/===HEADER===/,header)} 1' ./index.template.html |
awk -v footer="$(<./footer.html)" '{sub(/===FOOTER===/,footer)} 1' > ./index.html
chmod 444 ./index.html