Commit 28f32915 authored by Aral Balkan's avatar Aral Balkan

Fixes #171: Display development-time version better

parent 3fc56b1b
......@@ -99,6 +99,10 @@ class Site {
static get hugoVersion () { return this.getFromManifest('hugoVersion') }
static binaryVersionToHumanReadableDateString (binaryVersion) {
// Is this the dummy version that signals a development build?
if (binaryVersion === '20000101000000') {
return 'Dev'
}
const m = moment(binaryVersion, 'YYYYMMDDHHmmss')
return `${m.format('MMMM Do, YYYY')} at ${m.format('HH:mm:ss')}`
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment