aboutsummaryrefslogtreecommitdiff
path: root/example-site
diff options
context:
space:
mode:
authorMitchell Riedstra <mitch@riedstra.dev>2021-07-18 16:04:06 -0400
committerMitchell Riedstra <mitch@riedstra.dev>2021-07-18 16:04:06 -0400
commitf2082a0d72f9359be02182883a1e1190d8b1b215 (patch)
tree7856590caa92fe0e71861c85546cdabe0bea16ca /example-site
parent8b1d8bf26452f3ce8b38228a39755a6b8e18775a (diff)
downloadgo-website-f2082a0d72f9359be02182883a1e1190d8b1b215.tar.gz
go-website-f2082a0d72f9359be02182883a1e1190d8b1b215.tar.xz
More changes to how the website functions
Diffstat (limited to 'example-site')
-rw-r--r--example-site/blog/first-post.md5
-rw-r--r--example-site/blog/second-post.md1
-rw-r--r--example-site/blog/unpublished-post.md22
-rw-r--r--example-site/checkup.md62
-rw-r--r--example-site/inc/base.html16
-rw-r--r--example-site/index.md5
-rw-r--r--example-site/multi-tag-page.md1
-rw-r--r--example-site/untagged-page.md1
8 files changed, 100 insertions, 13 deletions
diff --git a/example-site/blog/first-post.md b/example-site/blog/first-post.md
index 42ef931..f9c5ea2 100644
--- a/example-site/blog/first-post.md
+++ b/example-site/blog/first-post.md
@@ -1,13 +1,10 @@
---
title: 'Blog Post #1'
-# head: "This is optional"
description: My example description
-
date: 07.02.2021 15:00:00 EDT
-
+published: true
tags:
Blog:
-
|---
`{{.Date.Time.Format "Monday January 2 2006"}}`
diff --git a/example-site/blog/second-post.md b/example-site/blog/second-post.md
index f8abef2..34fe318 100644
--- a/example-site/blog/second-post.md
+++ b/example-site/blog/second-post.md
@@ -2,6 +2,7 @@
title: 'Blog Post #2'
description: My example description for blog post #2
date: 07.14.2021 15:00:00 EDT
+published: true
tags:
Blog:
|---
diff --git a/example-site/blog/unpublished-post.md b/example-site/blog/unpublished-post.md
new file mode 100644
index 0000000..3088250
--- /dev/null
+++ b/example-site/blog/unpublished-post.md
@@ -0,0 +1,22 @@
+---
+title: 'Unpublished Blog Post'
+description: My example description for an unpublished blog post
+date: 07.15.2021 15:00:00 EDT
+
+# Defaults to false
+# published: false
+
+tags:
+ Blog:
+|---
+
+`{{.Date.Time.Format "Monday January 2 2006"}}`
+
+# {{.Title}}
+
+This is an example unpublished blog post.
+
+Description:
+
+> {{.Description}}
+
diff --git a/example-site/checkup.md b/example-site/checkup.md
new file mode 100644
index 0000000..f7d7a88
--- /dev/null
+++ b/example-site/checkup.md
@@ -0,0 +1,62 @@
+---
+title: Example checkup page
+description: Showing the output of one of the internal checkup mechanisms
+
+|---
+
+# {{.Title}}
+
+# Status
+
+{{range $key, $val := .Checkup}}
+## {{$key}}:
+{{range $page := $val}}
+```
+{{$page}}
+{{$page.EncodeYaml nil}}
+```
+{{end}}
+{{end}}
+## Raw
+
+```
+{{.EncodeYaml .Checkup}}
+```
+
+## Recent Blog Entries:
+
+[Atom Feed](/{{.Global.App.FeedPrefix}}/Blog?limit=5&content)
+
+{{range $val := .Index.Blog.SortDate}}
+ * [{{$val.Date.Time.Format "2006-01-02"}} {{$val.Title}}]({{$val.Path}}){{end}}
+
+## Published Blog Entries:
+
+{{range $val := .Index.Blog.SortDate}}{{if $val.Published}}
+ * [{{$val.Date.Time.Format "2006-01-02"}} * {{$val.Title}}]({{$val.Path}}){{end}}{{end}}
+
+## Some internals
+
+
+#### Global vars:
+
+```
+{{.Global}}
+
+"App" under Global vars:
+{{.Global.App}}
+```
+
+#### Page Index
+
+{{range $key, $val := .Index}}
+```
+### {{$key}}:
+
+{{range $v2 := $val}}
+{{$v2.StringDetail}}{{end}}
+```
+
+
+{{end}}
+
diff --git a/example-site/inc/base.html b/example-site/inc/base.html
index 959c7d6..2f93ec7 100644
--- a/example-site/inc/base.html
+++ b/example-site/inc/base.html
@@ -6,15 +6,13 @@
<link id="maincss" rel="stylesheet" href="/static/style.css" defer>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
- <meta name="author" content="{{.Global.App.Author.Name}}">
- <meta name="description" content="{{.Global.App.Description}}">
-
- <!--
- <link rel="apple-touch-icon" sizes="180x180" href="/static/apple-touch-icon.png">
- <link rel="icon" type="image/png" sizes="32x32" href="/static/favicon-32x32.png">
- <link rel="icon" type="image/png" sizes="16x16" href="/static/favicon-16x16.png">
- <link rel="manifest" href="/static/site.webmanifest">
- -->
+
+ {{if .AuthorName }}
+ <meta name="author" content="{{.AuthorName}}">
+ {{else if .Global.App.Author.Name }}
+ <meta name="author" content="{{.Global.App.Author.Name}}">
+ {{else}}
+ {{end}}
{{if .Title}}
<title>{{.Title}}</title>
diff --git a/example-site/index.md b/example-site/index.md
index 6d292b5..42b0181 100644
--- a/example-site/index.md
+++ b/example-site/index.md
@@ -21,6 +21,11 @@ it.
{{range $val := .Index.Blog.SortDate}}
* [{{$val.Date.Time.Format "2006-01-02"}} {{$val.Title}}]({{$val.Path}}){{end}}
+## Published Blog Entries:
+
+{{range $val := .Index.Blog.SortDate}}{{if $val.Published}}
+ * [{{$val.Date.Time.Format "2006-01-02"}} * {{$val.Title}}]({{$val.Path}}){{end}}{{end}}
+
## Some internals
diff --git a/example-site/multi-tag-page.md b/example-site/multi-tag-page.md
index a1a61d2..6e3b4f6 100644
--- a/example-site/multi-tag-page.md
+++ b/example-site/multi-tag-page.md
@@ -4,6 +4,7 @@ description: A page with several tags added to it
date: 07.02.2021 15:00:00 EDT
authorname: Someone Else
# authoremail: someoneelse@example.com
+published: true
tags:
Blog:
Automotive:
diff --git a/example-site/untagged-page.md b/example-site/untagged-page.md
index aa8400f..c55274e 100644
--- a/example-site/untagged-page.md
+++ b/example-site/untagged-page.md
@@ -2,6 +2,7 @@
title: Untagged page
description: A page with no tags added to it
date: 07.02.2021 15:00:00 EDT
+published: true
tags:
|---