removed all theme overrides and created new theme "amberterm"

This commit is contained in:
Michael Clemens 2021-07-21 17:34:16 +02:00
parent 5e0f596eb9
commit 2b4f30b08c
13 changed files with 5 additions and 303 deletions

3
.gitmodules vendored
View File

@ -10,3 +10,6 @@
[submodule "themes/smol"]
path = themes/smol
url = https://github.com/colorchestra/smol
[submodule "themes/amberterm"]
path = themes/amberterm
url = git@git.qrz.is:clemens/amberterm.git

View File

@ -3,7 +3,7 @@ languageCode = "en-us"
title = "qrz.is"
copyright = "Michael Clemens"
subtitle = "personal website of Michael Clemens / DL6MHC"
theme = "smol"
theme = "amberterm"
dateFormat = "2006-01-02" # default
publishDir = "/var/www/qrz.is"

View File

@ -1,24 +0,0 @@
<!DOCTYPE html>
<html lang="{{ .Site.LanguageCode | default "en-us" }}">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<style type=text/css>body{font-family:monospace;}</style>
<title>{{ .Site.Title }}</title>
{{ with .Site.Params.description }}<meta name="description" content="{{ . }}">{{ end }}
{{ with .Site.Params.author }}<meta name="author" content="{{ . }}">{{ end }}
<link rel="stylesheet" href="{{ "css/style.css?15" | relURL }}">
{{ range .Site.Params.customCSS -}}
<link rel="stylesheet" href="{{ . | relURL }}?rnd={{ now.Unix }}">
{{- end }}
{{ with .OutputFormats.Get "RSS" -}}
{{ printf `<link rel="%s" type="%s" href="%s" title="%s">` .Rel .MediaType.Type .RelPermalink $.Site.Title | safeHTML }}
{{- end }}
</head>
<body>
{{ partial "header" . }}
{{ block "main" . }}{{ end }}
{{ partial "footer" . }}
</body>
</html>

View File

@ -1,41 +0,0 @@
{{- $allowedRssSections := (slice "post") -}}
{{- $baseurl := .Site.BaseURL -}}
{{- $pctx := . -}}
{{- if .IsHome -}}{{ $pctx = .Site }}{{- end -}}
{{- $pages := slice -}}
{{- if or $.IsHome $.IsSection -}}
{{- $pages = $pctx.RegularPages -}}
{{- else -}}
{{- $pages = $pctx.Pages -}}
{{- end -}}
{{- $limit := .Site.Config.Services.RSS.Limit -}}
{{- if ge $limit 1 -}}
{{- $pages = $pages | first $limit -}}
{{- end -}}
{{- printf "<?xml version=\"1.0\" encoding=\"utf-8\" standalone=\"yes\"?>" | safeHTML }}
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
<title>{{ .Site.Title }}</title>
{{- $perm := replace .Permalink "/gemini" "" 1 -}}
{{- $alt := .Site.BaseURL | replaceRE `https?://(.+?)` "gemini://$1" -}}
{{ printf "<link rel=\"self\" type=\"application/atom+xml\" href=\"%s\"/>" $perm | safeHTML }}
{{ printf "<link rel=\"alternate\" type=\"text/html\" href=\"%s\"/>" $alt | safeHTML }}
<updated>{{ .Date.Format "2006-01-02T15:04:05-0700" | safeHTML }}</updated>
<author>
<name>{{ .Site.Author.name }}</name>
<uri>{{ .Site.BaseURL | replaceRE `https?://(.+?)` "gemini://$1" }}</uri>
</author>
<id>{{ $perm }}</id>
{{ range $pages }}
{{ if in $allowedRssSections .Section }}
<entry>
<title>{{ .Title }}</title>
{{- $entryperm := .Permalink | replaceRE `https?://(.+?)` "gemini://$1" -}}
{{ printf "<link rel=\"alternate\" href=\"%s\"/>" $entryperm | safeHTML }}
<id>{{ $entryperm }}</id>
<published>{{ .Date.Format "2006-01-02T15:04:05-0700" | safeHTML }}</published>
<updated>{{ .Lastmod.Format "2006-01-02T15:04:05-0700" | safeHTML }}</updated>
<summary>{{ if isset .Params "subtitle" }}{{ .Params.subtitle }}{{ else }}{{ .Summary | html }}{{ end }}</summary>
</entry>
{{ end }}
{{ end }}
</feed>

View File

@ -1,46 +0,0 @@
```
██████╗ ██████╗ ███████╗ ██╗ ██████╗
██╔═══██╗██╔══██╗╚════██║ ██║██╔════╝
██║██╗██║██████╔╝ ███╔═╝ ██║╚█████╗
╚██████╔╝██╔══██╗██╔══╝ ██║ ╚═══██╗
╚═██╔═╝ ██║ ██║███████╗██╗██║██████╔╝
╚═╝ ╚═╝ ╚═╝╚══════╝╚═╝╚═╝╚═════╝
```
# {{ .Title }}{{ $scratch := newScratch }}
{{ $content := .RawContent -}}
{{ $content := $content | replaceRE `#### ` "### " -}}
{{ $content := $content | replaceRE `\n- (.+?)` "\n* $1" -}}
{{ $content := $content | replaceRE `\n(\d+). (.+?)` "\n* $2" -}}
{{ $content := $content | replaceRE `\[\^(.+?)\]:?` "" -}}
{{ $content := $content | replaceRE `<br/??>` "\n" -}}
{{ $content := $content | replaceRE `<a .*href="(.+?)".*>(.+?)</a>` "[$2]($1)" -}}
{{ $content := $content | replaceRE `\sgemini://(\S*)` " [gemini://$1](gemini://$1)" -}}
{{ $content := $content | replaceRE `{{ < audio "(.+?)" >}}` "=> https://brainbaking.com/$1 Embedded Audio link - $1" -}}
{{ $content := $content | replaceRE `{{ < video "(.+?)" >}}` "=> https://brainbaking.com/$1 Embedded Video link - $1" -}}
{{ $content := $content | replaceRE `{{ < youtube (.+?) >}}` "=> https://www.youtube.com/watch?v=$1 YouTube Video link to $1" -}}
{{ $content := $content | replaceRE `{{ < vimeo (.+?) >}}` "=> https://vimeo.com/$1 Vimeo Video link to $1" -}}
{{ $content := $content | replaceRE "([^`])<.*?>([^`])" "$1$2" -}}
{{ $content := $content | replaceRE `\n\n!\[.*\]\((.+?) \"(.+?)\"\)` "\n\n=> $1 Image: $2" -}}
{{ $content := $content | replaceRE `\n\n!\[.*]\((.+?)\)` "\n\n=> $1 Embedded Image: $1" -}}
{{ $links := findRE `\n=> ` $content }}{{ $scratch.Set "ref" (add (len $links) 1) }}
{{ $refs := findRE `\[.+?\]\(.+?\)` $content }}
{{ $scratch.Set "content" $content }}{{ range $refs }}{{ $ref := $scratch.Get "ref" }}{{ $contentInLoop := $scratch.Get "content" }}{{ $url := (printf "%s #%d" . $ref) }}{{ $contentInLoop := replace $contentInLoop . $url -}}{{ $scratch.Set "content" $contentInLoop }}{{ $scratch.Set "ref" (add $ref 1) }}{{ end }}{{ $content := $scratch.Get "content" | replaceRE `\[(.+?)\]\((.+?)\) #(\d+)` "$1 [$3]" -}}
{{ $content | safeHTML }}
---
Written by Michael Clemens on {{ .Lastmod.Format (.Site.Params.dateFormat | default "2 January 2006") }}.
## References
{{ $scratch.Set "ref" (add (len $links) 1) }}{{ range $refs }}{{ $ref := $scratch.Get "ref" }}{{ $url := (printf "%s #%d" . $ref) }}
=> {{ $url | replaceRE `\[(.+?)\]\((.+?)\) #(\d+)` "$2 [$3] $1 ($2)" -}}
{{ $scratch.Set "ref" (add $ref 1) }}{{ end}}
{{ $related := first 3 (where (where .Site.RegularPages.ByDate.Reverse ".Params.tags" "intersect" .Params.tags) "Permalink" "!=" .Permalink) }}
{{ if $related }}
## Related articles
{{ range $related }}
=> {{ replace .RelPermalink "/gemini" "" 1}} {{ .Title }}: {{ .Params.Subtitle }}{{ end }}{{ end }}
---
=> / Back to the Index
=> https://qrz.is{{ replace (replace .RelPermalink "/gemini" "" 1) "index.gmi" "" }} View this article on the WWW

View File

@ -1,27 +0,0 @@
```
██████╗ ██████╗ ███████╗ ██╗ ██████╗
██╔═══██╗██╔══██╗╚════██║ ██║██╔════╝
██║██╗██║██████╔╝ ███╔═╝ ██║╚█████╗
╚██████╔╝██╔══██╗██╔══╝ ██║ ╚═══██╗
╚═██╔═╝ ██║ ██║███████╗██╗██║██████╔╝
╚═╝ ╚═╝ ╚═╝╚══════╝╚═╝╚═╝╚═════╝
```
# QRZ.is
This is the personal gemini capsule of Michael Clemens. Most of what you will find here is related to amateur radio, software development and hardware projects.
## Pages
=> gemini://qrz.is/projects/index.gmi Software/Hardware Projects
=> gemini://qrz.is/about/index.gmi About me
## Posts
{{ range (where (where (where .Site.Pages "Section" "in" (slice "post")) ".Params.type" "eq" "post") ".Params.concept" "ne" "true").GroupByDate "2006" "desc" }}{{ $year := .Key -}}
### {{ .Key }}
{{ range .Pages.ByDate.Reverse }}
=> {{ replace .Permalink "/gemini" "" 1}} {{ .Date.Format ("2006/01/02") }} - {{ .Title }}
{{- end }}
{{ end }}

View File

@ -1,10 +0,0 @@
<footer>
<hr>
<nav>
<p>&copy; {{ now.Year }} <a href="{{ .Site.BaseURL }}"><b>{{ if .Site.Copyright }}{{ .Site.Copyright }}{{ else }}{{ .Site.Title }}{{ end }}</b></a>
{{- range .Site.Menus.footer }}
- <a rel="me" href="{{ .URL }}"><b>{{ .Name }}</b></a>
{{- end }}
</p>
</nav>
</footer>

View File

@ -1,22 +0,0 @@
<header>
<div class="ascii-art">
<a href="/">
██████╗ ██████╗ ███████╗ ██╗ ██████╗
██╔═══██╗██╔══██╗╚════██║ ██║██╔════╝
██║██╗██║██████╔╝ ███╔═╝ ██║╚█████╗
╚██████╔╝██╔══██╗██╔══╝ ██║ ╚═══██╗
╚═██╔═╝ ██║ ██║███████╗██╗██║██████╔╝
╚═╝ ╚═╝ ╚═╝╚══════╝╚═╝╚═╝╚═════╝
</a>
</div>
<hr>
<nav>
<a href="/"><b>Home</b></a>
{{ with .Site.Menus.main }}
{{ range . }} - <a href="{{ .URL | relURL }}"><b>{{ .Name }}</b></a> {{ end }}
</nav>
{{ end }}
</header>
<hr>
</p>

View File

@ -1,40 +0,0 @@
<!DOCTYPE html>
<html lang="en-us">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<title>qrz.is</title>
<link rel="stylesheet" href="/css/style.css?21">
</head>
<body>
<div class="ascii-art">
</br>
</br>
</br>
</br>
<a href="/">
██╗██╗ █████╗ ██╗██╗
██╔╝██║██╔══██╗ ██╔╝██║
██╔╝ ██║██║ ██║██╔╝ ██║
███████║██║ ██║███████║
╚════██║╚█████╔╝╚════██║
╚═╝ ╚════╝ ╚═╝
██████╗ █████╗ ██████╗ ███████╗  ███╗ ██╗ █████╗ ████████╗  ███████╗ █████╗ ██╗ ██╗███╗ ██╗██████╗
██╔══██╗██╔══██╗██╔════╝ ██╔════╝  ████╗ ██║██╔══██╗╚══██╔══╝  ██╔════╝██╔══██╗██║ ██║████╗ ██║██╔══██╗
██████╔╝███████║██║ ██╗ █████╗   ██╔██╗██║██║ ██║ ██║   █████╗ ██║ ██║██║ ██║██╔██╗██║██║ ██║
██╔═══╝ ██╔══██║██║ ╚██╗██╔══╝   ██║╚████║██║ ██║ ██║   ██╔══╝ ██║ ██║██║ ██║██║╚████║██║ ██║
██║ ██║ ██║╚██████╔╝███████╗  ██║ ╚███║╚█████╔╝ ██║   ██║ ╚█████╔╝╚██████╔╝██║ ╚███║██████╔╝
╚═╝ ╚═╝ ╚═╝ ╚═════╝ ╚══════╝  ╚═╝ ╚══╝ ╚════╝ ╚═╝   ╚═╝ ╚════╝ ╚═════╝ ╚═╝ ╚══╝╚═════╝
</a>
</div>
</body>
</html>

View File

@ -1,5 +0,0 @@
/*
X-Frame-Options: DENY
X-XSS-Protection: 1; mode=block
Referrer-Policy: no-referrer
X-Content-Type-Options: nosniff

View File

@ -1,87 +0,0 @@
html {
overflow-y: scroll;
}
:root {
--bgcolor: #222;
--fontcolor: orange;
--linkcolor: orange;
--visitedcolor: orange;
--precolor: orange;
--prebgcolor: #222;
}
body{
max-width:800px;
margin:40px auto;
padding:0 10px;
font:14px/1.5 monospace;
color:var(--fontcolor); background: var(--bgcolor)
}
a:link{
color: var(--linkcolor)
}
a:visited{
color: var(--visitedcolor)
}
a:active{
color: var(--visitedcolor)
}
h1,h2,h3{
line-height:1.2;
}
nav a{
text-decoration: none;
}
h1 a,h2 a,h3 a{
text-decoration: none;
}
h1 a:hover,h2 a:hover,h3 a:hover,nav a:hover{
text-decoration: underline;
}
hr {
border-style: solid; size: 1px; border-color: orange;
}
p > code{
color: var(--precolor); background: var(--prebgcolor);
padding:2px;
border: 1px solid orange;
}
pre{
color: var(--precolor);
background: var(--prebgcolor);
padding:24px;
overflow-x: auto;
border: 1px solid orange;
}
article{
padding:24px 0
}
.center {
display: block;
margin-left: auto;
margin-right: auto;
width: 100%;
}
img {
display: block;
max-width: 100%;
height: auto;
}
figcaption {
color: #888;
font: 12px/1.5 monospace;
text-align: center;
}
figure {
margin: auto
}
.ascii-art {
font-family: monospace;
white-space: pre;
line-height: 1;
}
div.ascii-art a{
text-decoration: none;
}
div.nav a {
text-decoration: none;
}

1
themes/amberterm Submodule

@ -0,0 +1 @@
Subproject commit a3521745216a20db4a8bdd6cd45072f52cef4aab