diff options
| author | Joe Mou <dev@mou.fo> | 2026-08-11 08:37:25 -0400 |
|---|---|---|
| committer | Joe Mou <dev@mou.fo> | 2026-08-11 08:38:30 -0400 |
| commit | d76a46b37b12823b5b3976d129c2d4b672a99693 (patch) | |
| tree | 5640077c30a71ac8eccdc66925a82e112aa45963 /views/layout.eta | |
| parent | de557ad66466261ae578ea9342f32d78a139fbc9 (diff) | |
Show the build's commit in the page footer
Workers can't shell out at request time, so the commit has to be baked
in before wrangler bundles the sources. compile-views.ts grows a second
job and becomes scripts/build.ts: alongside the precompiled views it
writes src/commit.generated.ts with `git describe --tags --always
--dirty`, which yields a bare short hash until the repo is tagged and
marks builds made from an unclean working copy.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Diffstat (limited to 'views/layout.eta')
| -rw-r--r-- | views/layout.eta | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/views/layout.eta b/views/layout.eta index f803caf..ca6fff2 100644 --- a/views/layout.eta +++ b/views/layout.eta @@ -34,7 +34,7 @@ git clone git@github.com:<%= it.repo.owner %>/<%= it.repo.name %>.git</code></pr <%~ it.body %> - <footer>Generated by cgithub · <a href="<%= it.githubUrl %>" rel="noreferrer">View original</a></footer> + <footer>Generated by cgithub commit <code><%= it.commit %></code> · <a href="<%= it.githubUrl %>" rel="noreferrer">View original</a></footer> <script> document.addEventListener("keydown", function(e) { |
