diff options
author | mms <michal@sapka.me> | 2024-09-20 20:06:17 +0200 |
---|---|---|
committer | mms <michal@sapka.me> | 2024-09-20 20:06:17 +0200 |
commit | 4c09a9b465597051ffd3dd90c8e9afa28a8b39a1 (patch) | |
tree | 662df9c25c86253e7d6f7236c77bd27f68b45058 /layouts | |
parent | f10a1070096953eaa3668ca660bffac193235ed2 (diff) |
feat: emacs/bsd moved
Diffstat (limited to 'layouts')
-rw-r--r-- | layouts/bsd/baseof.html | 13 | ||||
-rw-r--r-- | layouts/bsd/list.html | 2 | ||||
-rw-r--r-- | layouts/bsd/redirect.html | 9 | ||||
-rw-r--r-- | layouts/bsd/single.html | 2 | ||||
-rw-r--r-- | layouts/cool-emacs/baseof.html | 167 | ||||
-rw-r--r-- | layouts/cool-emacs/list.html | 31 | ||||
-rw-r--r-- | layouts/cool-emacs/redirect.html | 9 | ||||
-rw-r--r-- | layouts/cool-emacs/single.html | 31 |
8 files changed, 48 insertions, 216 deletions
diff --git a/layouts/bsd/baseof.html b/layouts/bsd/baseof.html new file mode 100644 index 0000000..8bed0a0 --- /dev/null +++ b/layouts/bsd/baseof.html @@ -0,0 +1,13 @@ +{{ block "main" . }} +{{ end }} + +<!DOCTYPE html> +<html> + <head> + <title>{{ .Title }}</title> + <link rel="canonical" href="/unix-history/"/> + <meta http-equiv="content-type" content="text/html; charset=utf-8"/> + <meta http-equiv="refresh" content="0; url=https://bsd.crys.site/{{ replace .RelPermalink "/bsd/" ""}}"/> + </head> + +</html> diff --git a/layouts/bsd/list.html b/layouts/bsd/list.html new file mode 100644 index 0000000..e4e4a83 --- /dev/null +++ b/layouts/bsd/list.html @@ -0,0 +1,2 @@ +{{ define "main" }} +{{ end }} diff --git a/layouts/bsd/redirect.html b/layouts/bsd/redirect.html new file mode 100644 index 0000000..599d57b --- /dev/null +++ b/layouts/bsd/redirect.html @@ -0,0 +1,9 @@ +<!DOCTYPE html> +<html> + <head> + <title>{{ .Title }}</title> + <link rel="canonical" href="/unix-history/"/> + <meta http-equiv="content-type" content="text/html; charset=utf-8"/> + <meta http-equiv="refresh" content="0; url=/unix-history/#{{ .Page.Params.link }}"/> + </head> +</html> diff --git a/layouts/bsd/single.html b/layouts/bsd/single.html new file mode 100644 index 0000000..e4e4a83 --- /dev/null +++ b/layouts/bsd/single.html @@ -0,0 +1,2 @@ +{{ define "main" }} +{{ end }} diff --git a/layouts/cool-emacs/baseof.html b/layouts/cool-emacs/baseof.html index f9c60e4..944354d 100644 --- a/layouts/cool-emacs/baseof.html +++ b/layouts/cool-emacs/baseof.html @@ -1,156 +1,13 @@ -<!DOCTYPE html> -<html lang="en"> -<head> - <meta name="viewport" content="width=device-width, initial-scale=1"> - <meta charset="utf-8"> - <title> {{ .Page.Title }} | Cool Emacs </title> - - <meta name="viewport" content="width=device-width, initial-scale=1"> - - {{- $header_rect := resources.Get "cool-emacs/header-rect.png" }} - {{- $header_rect_180 := $header_rect.Resize "180x webp q90"}} - <link rel="apple-touch-icon" sizes="180x180" href="{{ $header_rect_180.Permalink }}"> - - {{- $header_rect_32 := $header_rect.Resize "32x webp q90"}} - <link rel="icon" type="image/png" sizes="32x32" href="{{ $header_rect_32.Permalink }}"> - - {{- $header_rect_16 := $header_rect.Resize "16x webp q90"}} - <link rel="icon" type="image/png" sizes="16x16" href="{{ $header_rect_16.Permalink }}"> - - <meta name="description" content="{{ .Params.Abstract | default .Site.Params.DefaultDescription}}"> - - <meta property="og:title" content="{{ .Page.Title }}"> - <meta property="og:type" content="website"> - <meta property="og:url" content="{{ .Permalink }}"> - <meta property="og:image" content="{{ $header_rect.Permalink }}"> - <meta property="og:description" content="{{ .Params.Abstract | default .Site.Params.DefaultDescription}}"> - - <link rel="canonical" href="{{ .Permalink }}"> - <link rel='alternate' type='application/rss+xml' title="Feed with all changes" href='/index.xml'> - <link rel='alternate' type='application/rss+xml' title="Feed with Cool Emacs changes" href='/cool-emacs/index.xml'> - <meta name="robots" content="index, follow"> - <link rel="me" href="https://emacs.ch/@mms"> - - <link rel="webmention" href="https://webmention.io/d-s.sh/webmention"> - <link rel="pingback" href="https://webmention.io/d-s.sh/xmlrpc"> - - {{- $bg := resources.Get "cool-emacs/bg.gif" -}} - <style> - :root { - --bg-color: #F5F5F5; - --text-color: #000; - --heading-color: #9b0000; - --heading-shadow: 14px 7px 16px rgba(166, 168, 191, 1); - } - body { - font-family: serif; - background-color: #B2BEB5; - font-size: 1em; - background-image: url({{ $bg.Permalink }}); - background-repeat: repeat-y; - background-size: 30px; - background-color: var(--bg-color); - color: var(--text-color); - } - - .site { - width: 800px; - max-width: 80%; - margin-top: 0; - margin-bottom: 0; - padding: 20px; - margin-left: 50px; - } - @media only screen and (max-width: 600px) { - .site { - margin-left: 10px; - } - } - - article figure { - text-align: center; - margin: 0; - max-width: 100%; - font-size: 0.8em; - } - - img { - max-width: 60%; - height: auto; - } - - figure img { - border-width: 5px; - border-style: solid; - border-color: var(--heading-color); - } - - - p, ul { - line-height: 1.4em; - text-align: justify; - } - p, ul, .highlight, pre code { - margin-left: 40px; - } - @media only screen and (max-width: 600px) { - p, ul, .highlight, pre code { - margin-left: 20px; - } - } - .highlight { - display: block; - max-width: 90%; - overflow-x: scroll; - width: 750px; - } - pre { - padding: 10px; - } - h1 { - padding-bottom: 50px; - text-shadow: var(--heading-shadow); - } - h2, h3 { - text-shadow: var(--heading-shadow); - font-family: monospace; - color: var(--heading-color); - } - .no-border img { - border: 0; - } - .right { - float: right; - max-width: 40%; - } +{{ block "main" . }} +{{ end }} - </style> - - -</head> -<body> - <div class="site"> - <header> - {{ block "head" . }} - {{ end }} - - </header> - <article> - <h1>{{ .Title }}</h1> - - {{ block "main" . }} - {{ end }} - </article> - - <footer> - <hr> - Website created and operated by <a href="https://michal.sapka.me">MichaĆ</a> - <div style="padding: 15px; text-align: center;"> - {{ partial "buttons/valid_html" . }} - {{ partial "button-31" (dict "file" "rss.gif" "alt" "RSS Feed" "href" "https://michal.sapka.me/cool-emacs/index.xml") }} - {{ partial "buttons/emacs" . }} - {{ partial "buttons/openbsd" . }} - </div> - </footer> - </div> -</body> +<!DOCTYPE html> +<html> + <head> + <title>{{ .Title }}</title> + <link rel="canonical" href="/unix-history/"/> + <meta http-equiv="content-type" content="text/html; charset=utf-8"/> + <meta http-equiv="refresh" content="0; url=https://emacs.crys.site/{{ replace .RelPermalink "/cool-emacs/" ""}}"/> + </head> + +</html> diff --git a/layouts/cool-emacs/list.html b/layouts/cool-emacs/list.html index 6295d15..e4e4a83 100644 --- a/layouts/cool-emacs/list.html +++ b/layouts/cool-emacs/list.html @@ -1,33 +1,2 @@ -{{ define "head"}} -<a href="/">Back</a> -<hr> -{{end}} - - - {{ define "main" }} - -{{if .Page.Content}} - {{ .Page.Content }} - {{- if .Params.primary_menu }} - {{ partial "single/bottom_nav.html" (dict "menuID" .Page.Params.primary_menu "page" .) }} - {{- end }} - - {{ partial "single/dates.html" . }} -{{ else }} - - {{ if in .Page.Params.Categories "blog" }} - {{ partial "partials/blog_index.html" . }} - {{ else if in .Page.Params.Categories "article" }} - {{ partial "partials/article_index.html" . }} - {{ else }} - - <h2>Articles</h2> - {{ range .Data.Pages }} - {{ partial "partials/article_list_item.html" . }} - {{ end }} - - {{ end }} -{{end}} - {{ end }} diff --git a/layouts/cool-emacs/redirect.html b/layouts/cool-emacs/redirect.html new file mode 100644 index 0000000..599d57b --- /dev/null +++ b/layouts/cool-emacs/redirect.html @@ -0,0 +1,9 @@ +<!DOCTYPE html> +<html> + <head> + <title>{{ .Title }}</title> + <link rel="canonical" href="/unix-history/"/> + <meta http-equiv="content-type" content="text/html; charset=utf-8"/> + <meta http-equiv="refresh" content="0; url=/unix-history/#{{ .Page.Params.link }}"/> + </head> +</html> diff --git a/layouts/cool-emacs/single.html b/layouts/cool-emacs/single.html index 855124b..e4e4a83 100644 --- a/layouts/cool-emacs/single.html +++ b/layouts/cool-emacs/single.html @@ -1,31 +1,2 @@ -{{ define "head" }} -<a href="/cool-emacs"> -{{- $header_rect := resources.Get "unix-history/header-top.png" }} -{{- $header_rect_180 := $header_rect.Resize "50x webp q90"}} -<!-- <img --> -<!-- style=" --> -<!-- height: 1.5em; --> -<!-- width: auto; --> -<!-- margin-right: 0.5em; --> -<!-- " --> -<!-- src="{{ $header_rect_180.Permalink }}" --> -<!-- ></a> --> - -<b><i>Cool Emacs</i></b></a> -<hr> - -{{ end }} - {{ define "main" }} - -<article> - {{ .Page.Content }} -</article> - -{{- if .Params.primary_menu }} - {{ partial "single/bottom_nav.html" (dict "menuID" .Page.Params.primary_menu "page" .) }} -{{- end }} - -{{ partial "single/dates.html" . }} - -{{- end }} +{{ end }} |