#!/bin/sh ROOT_DIR="./build/website/" # replace placeholder tags with stuff for i in $(find "$ROOT_DIR" -type f -name '*.html'); do if [ "$(basename "$i")" = 'index.html' ]; then sed -i -e 's||\| Back|g' "$i" else sed -i -e 's||\| Back|g' "$i" fi done; sed -i -e 's|\| Back||g' "$ROOT_DIR/index.html"