From 455534d43801bbebf54937ad0c6d4409fc0fc70b Mon Sep 17 00:00:00 2001 From: Kevin Mok Date: Thu, 31 Jan 2019 08:58:16 -0500 Subject: [PATCH] Added navigation bar and relative page title Made baseof layout and deleted public build. --- .gitignore | 1 + archetypes/default.md | 2 +- config.toml | 4 +- content/_index.md | 8 + content/{credits.md => credits/_index.md} | 4 +- ideas.md | 6 + layouts/_default/baseof.html | 8 + layouts/_default/list.html | 10 +- layouts/_default/single.html | 4 +- layouts/credits.html | 5 + layouts/{index.html => index-old.html} | 2 +- layouts/partials/article.html | 11 +- layouts/partials/footer.html | 2 +- layouts/partials/header.html | 13 +- layouts/partials/hero.html | 22 +- layouts/partials/homepage.html | 2 - public/404.html | 52 --- public/categories/index.html | 42 -- public/categories/index.xml | 14 - public/css/style.css | 500 ---------------------- public/img/base16-eighties.svg | 21 - public/index.html | 75 ---- public/index.xml | 14 - public/sitemap.xml | 20 - public/tags/index.html | 42 -- public/tags/index.xml | 14 - static/css/style.css | 46 +- 27 files changed, 115 insertions(+), 829 deletions(-) create mode 100644 content/_index.md rename content/{credits.md => credits/_index.md} (93%) create mode 100644 ideas.md create mode 100644 layouts/_default/baseof.html create mode 100644 layouts/credits.html rename layouts/{index.html => index-old.html} (60%) delete mode 100644 public/404.html delete mode 100644 public/categories/index.html delete mode 100644 public/categories/index.xml delete mode 100644 public/css/style.css delete mode 100644 public/img/base16-eighties.svg delete mode 100644 public/index.html delete mode 100644 public/index.xml delete mode 100644 public/sitemap.xml delete mode 100644 public/tags/index.html delete mode 100644 public/tags/index.xml diff --git a/.gitignore b/.gitignore index dd4b2a6..0966645 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ +public/* themes/base16* commit-msg.txt diff --git a/archetypes/default.md b/archetypes/default.md index e788d7c..2175eb8 100644 --- a/archetypes/default.md +++ b/archetypes/default.md @@ -1,6 +1,6 @@ --- title: "{{ replace .Name "-" " " | title }}" date: {{ .Date }} -draft: true +draft: false layout: --- diff --git a/config.toml b/config.toml index 747c85a..028f5bc 100644 --- a/config.toml +++ b/config.toml @@ -1,5 +1,5 @@ -# baseURL = "file:///home/kevin/coding/mf-site/public/" -baseURL = "https://kevin-mok.gitlab.io/my-site-hugo" +# baseURL = "http://localhost:1313/" +baseURL = "https://kevin-mok.gitlab.io/my-site-hugo/" languageCode = "en-us" title = "Kevin Mok" # theme = "base16" diff --git a/content/_index.md b/content/_index.md new file mode 100644 index 0000000..ac9bf71 --- /dev/null +++ b/content/_index.md @@ -0,0 +1,8 @@ +--- +date: 2019-01-31T03:10:25-05:00 +draft: false +layout: baseof +--- + + + diff --git a/content/credits.md b/content/credits/_index.md similarity index 93% rename from content/credits.md rename to content/credits/_index.md index 0e0a71a..8f7a7aa 100644 --- a/content/credits.md +++ b/content/credits/_index.md @@ -1,8 +1,8 @@ --- title: "Credits" date: 2019-01-31T03:10:25-05:00 -draft: true -layout: article +draft: false +layout: single --- Icons made by +{{ define "main" }} + + + +{{ end }} diff --git a/layouts/_default/single.html b/layouts/_default/single.html index b9ff539..c151931 100644 --- a/layouts/_default/single.html +++ b/layouts/_default/single.html @@ -1,7 +1,7 @@ -{{ partial "header.html" . }} +{{ define "main" }}
{{ partial "article.html" . }}
-{{ partial "footer.html" . }} +{{ end }} diff --git a/layouts/credits.html b/layouts/credits.html new file mode 100644 index 0000000..46c82c0 --- /dev/null +++ b/layouts/credits.html @@ -0,0 +1,5 @@ +{{ define "main" }} + +{{ .Content }} + +{{ end }} diff --git a/layouts/index.html b/layouts/index-old.html similarity index 60% rename from layouts/index.html rename to layouts/index-old.html index 2744d98..a18a2bf 100644 --- a/layouts/index.html +++ b/layouts/index-old.html @@ -1,5 +1,5 @@ {{ partial "header.html" . }} -{{ partial "homepage.html" . }} + {{ partial "footer.html" . }} diff --git a/layouts/partials/article.html b/layouts/partials/article.html index c69a76f..c6dadfb 100644 --- a/layouts/partials/article.html +++ b/layouts/partials/article.html @@ -1,18 +1,26 @@ {{ $page := .Page }}

{{ .Title }}

diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html index fcf172c..edfcd05 100644 --- a/layouts/partials/footer.html +++ b/layouts/partials/footer.html @@ -6,7 +6,7 @@ © {{ now.Year }} {{ .Site.Title }} · CC BY 4.0 · - Credits + Credits diff --git a/layouts/partials/header.html b/layouts/partials/header.html index dc69d5f..6cc6267 100644 --- a/layouts/partials/header.html +++ b/layouts/partials/header.html @@ -16,13 +16,22 @@ -{{ $isHomePage := eq .Title .Site.Title }}{{ .Title }}{{ if eq $isHomePage false }} - {{ .Site.Title }}{{ end }} + + + ~{{ .Page.RelPermalink }} · {{ .Site.Title }} + + + +
+
+ -
+ +
Live, love and Linux.
diff --git a/layouts/partials/homepage.html b/layouts/partials/homepage.html index 5698dc6..cb42fb8 100644 --- a/layouts/partials/homepage.html +++ b/layouts/partials/homepage.html @@ -1,8 +1,6 @@ {{ $baseurl := .Site.BaseURL }}
- {{ partial "hero.html" . }} -