diff --git a/shell.nix b/shell.nix index f94ace3..e9ca35a 100644 --- a/shell.nix +++ b/shell.nix @@ -40,4 +40,5 @@ mkShell { SITE_PREFIX = "devel."; CLACK_SET = "Ashlynn,Terry Davis,Dennis Ritchie"; RUST_LOG = "info"; + GITHUB_SHA = "devel"; } diff --git a/src/post/mod.rs b/src/post/mod.rs index dbad39c..ca1f3b6 100644 --- a/src/post/mod.rs +++ b/src/post/mod.rs @@ -113,6 +113,12 @@ impl PartialOrd for Post { } } +impl Post { + pub fn detri(&self) -> String { + self.date.format("M%m %d %Y").to_string() + } +} + pub fn load(dir: &str) -> Result> { let mut result: Vec = vec![]; diff --git a/static/js/sw.js b/static/js/sw.js index a982f97..5e2c921 100755 --- a/static/js/sw.js +++ b/static/js/sw.js @@ -5,7 +5,7 @@ self.addEventListener('install', function(event) { event.waitUntil(preLoad()); }); -const cacheName = "cache-2019-11-01"; +const cacheName = "cache-xesite-2.0.0"; var preLoad = function(){ console.log('[PWA Builder] Install Event processing'); diff --git a/templates/blogindex.rs.html b/templates/blogindex.rs.html index 1eed018..02f34d6 100644 --- a/templates/blogindex.rs.html +++ b/templates/blogindex.rs.html @@ -14,7 +14,7 @@

diff --git a/templates/blogpost.rs.html b/templates/blogpost.rs.html index 2831b67..6b55850 100644 --- a/templates/blogpost.rs.html +++ b/templates/blogpost.rs.html @@ -24,25 +24,25 @@ @body @@ -52,6 +52,8 @@ +

This article was posted on @post.detri(). Facts and circumstances may have changed since publication. Please contact me before jumping to conclusions if something seems wrong or unclear.

+ @if post.front_matter.series.is_some() {

Series: @post.front_matter.series.as_ref().unwrap()

} diff --git a/templates/footer.rs.html b/templates/footer.rs.html index 8bdb11b..3059da7 100644 --- a/templates/footer.rs.html +++ b/templates/footer.rs.html @@ -1,10 +1,13 @@ +@use crate::APPLICATION_NAME as APP; + @() +
Copyright 2020 Christine Dodrill. Any and all opinions listed here are my own and not representative of my employers; future, past and present.
-

Looking for someone for your team? Take a look here.

+

Served by @APP running commit @env!("GITHUB_SHA"), see source code here.

diff --git a/templates/galleryindex.rs.html b/templates/galleryindex.rs.html index a9f2f71..f1d16d5 100644 --- a/templates/galleryindex.rs.html +++ b/templates/galleryindex.rs.html @@ -14,7 +14,7 @@
@post.front_matter.title
-

Posted on @post.date

+

Posted on @post.date.format("%Y-%m-%d")

} diff --git a/templates/gallerypost.rs.html b/templates/gallerypost.rs.html index eaedefb..c78ac7b 100644 --- a/templates/gallerypost.rs.html +++ b/templates/gallerypost.rs.html @@ -58,6 +58,8 @@ +

This artwork was posted on @post.detri().

+ @if post.front_matter.series.is_some() {

Series: @post.front_matter.series.as_ref().unwrap()

} diff --git a/templates/talkindex.rs.html b/templates/talkindex.rs.html index ce88be0..a582096 100644 --- a/templates/talkindex.rs.html +++ b/templates/talkindex.rs.html @@ -15,7 +15,7 @@

diff --git a/templates/talkpost.rs.html b/templates/talkpost.rs.html index 1375bca..771179c 100644 --- a/templates/talkpost.rs.html +++ b/templates/talkpost.rs.html @@ -54,6 +54,8 @@ +

This article was posted on @post.detri(). Facts and circumstances may have changed since publication. Please contact me before jumping to conclusions if something seems wrong or unclear.

+ @if post.front_matter.series.is_some() {

Series: @post.front_matter.series.as_ref().unwrap()

}