mirror of
https://github.com/vale981/tridactyl
synced 2025-03-04 09:01:39 -05:00
21 lines
510 B
Bash
Executable file
21 lines
510 B
Bash
Executable file
#!/usr/bin/env bash
|
|
|
|
set -e
|
|
err() { echo "error: line $(caller)"; }
|
|
trap err ERR
|
|
|
|
mkdir -p .build_cache
|
|
cd src/static
|
|
|
|
authors="../../build/static/authors.html"
|
|
|
|
sed "/REPLACETHIS/,$ d" authors.html > "$authors"
|
|
|
|
# If we're in a git repo, refresh the cache
|
|
if [ -d "../../.git/" ]; then
|
|
git shortlog -sn HEAD | cut -c8- | awk '!seen[$0]++' | sed 's/^/<p>/' | sed 's/$/<\/p>/' > ../../.build_cache/authors
|
|
fi
|
|
|
|
cat ../../.build_cache/authors >> "$authors"
|
|
|
|
sed "1,/REPLACETHIS/ d" authors.html >> "$authors"
|