Skip to content

Commit 5725cb0

Browse files
committed
use the build date in a shortcode
1 parent cd47d49 commit 5725cb0

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

content/now.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ layout: "simple"
88

99
_Yet another [now](https://nownownow.com/about) page inspired by [Derek Sivers](https://sive.rs/nowff)._
1010

11-
{{< badge >}} Last updated: November 10, 2025 {{< /badge >}}
11+
{{< badge >}} Last updated: {{< build-date >}} {{< /badge >}}
1212

1313
<!--- content --->
1414
### 📝 Recent writings

layouts/shortcodes/build-date.html

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
{{- /* Build-time date. `hugo.BuildDate` can be overridden (e.g. in CI) and may be empty in some contexts, so we fallback to `now`. */ -}}
2+
{{- (or hugo.BuildDate now) | time.Format "January 2, 2006" -}}
3+

0 commit comments

Comments
 (0)