diff options
Diffstat (limited to 'src/infrastructure/ci/git-post-receive.sh')
-rwxr-xr-x | src/infrastructure/ci/git-post-receive.sh | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/infrastructure/ci/git-post-receive.sh b/src/infrastructure/ci/git-post-receive.sh index 0712713..a4b2d1d 100755 --- a/src/infrastructure/ci/git-post-receive.sh +++ b/src/infrastructure/ci/git-post-receive.sh @@ -41,7 +41,8 @@ now() { date '+%Y-%m-%dT%H:%M:%S%:z' } -LOGS_DIR=/var/log/ci/"$(basename "$PWD" .git)"/ +NAME="$(basename "$PWD" .git)" +LOGS_DIR=/var/log/ci/"$NAME"/ TIMESTAMP="$(now)" FILENAME="$TIMESTAMP-$SHA.log" LOGFILE="$LOGS_DIR/$FILENAME" @@ -137,7 +138,7 @@ mkdtemp() { git notes add -f -m "$NOTE" "$SHA" { - printf 'Git CI HTML report for %s started.\n' "$SHA" >&2 + printf 'Git CI HTML report for %s (%s) started.\n' "$NAME" "$SHA" >&2 DIR="$(mkdtemp)" report -o "$DIR" sudo -u deployer rsync \ @@ -147,7 +148,7 @@ mkdtemp() { -a \ "$DIR"/ "$HTML_OUTDIR_CI"/ rm -rf "$DIR" - printf 'Git CI HTML report for %s generated.\n' "$SHA" >&2 + printf 'Git CI HTML report for %s (%s) generated.\n' "$SHA" >&2 } 2>&1 | logger -i -p local0.warn -t git-ci 1>/dev/null 2>&1 & } trap finish EXIT |