diff options
| author | Peter Stone <thepeterstone@gmail.com> | 2026-02-07 15:42:07 -1000 |
|---|---|---|
| committer | Peter Stone <thepeterstone@gmail.com> | 2026-02-07 15:42:07 -1000 |
| commit | d793e16f336189d38a9d43310713dd13e3b7c438 (patch) | |
| tree | b1e53d42069619912e683ddd1a58ed67b1873190 /deploy.sh | |
| parent | 0620afc98fdc0f764e82807bb0090b78618ddb1d (diff) | |
Add build version footer, deploy ldflags, template test helper, and logs script
- Display build commit hash in unobtrusive footer overlay
- Inject buildCommit/buildTime via ldflags in deploy.sh
- Add assertTemplateContains test helper, refactor existing template tests
- Add scripts/logs for fetching production journalctl via SSH
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Diffstat (limited to 'deploy.sh')
| -rwxr-xr-x | deploy.sh | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -11,7 +11,10 @@ echo "==> Building CSS..." npm run css:build echo "==> Building binary (linux/amd64)..." -GOOS=linux GOARCH=amd64 go build -o app cmd/dashboard/main.go +BUILD_COMMIT=$(git rev-parse --short HEAD) +BUILD_TIME=$(date -u '+%Y-%m-%dT%H:%M:%SZ') +LDFLAGS="-X main.buildCommit=${BUILD_COMMIT} -X main.buildTime=${BUILD_TIME}" +GOOS=linux GOARCH=amd64 go build -ldflags "$LDFLAGS" -o app cmd/dashboard/main.go echo "==> Pushing code to ${REMOTE}..." git push ${REMOTE} master |
