aboutsummaryrefslogtreecommitdiff
path: root/templates
diff options
context:
space:
mode:
authorMitja Felicijan <m@mitjafelicijan.com>2023-07-08 23:25:41 +0200
committerMitja Felicijan <m@mitjafelicijan.com>2023-07-08 23:25:41 +0200
commitcd6644ea4ddc78597934ab0ef5ba50e3c3daa927 (patch)
tree03de331a8db6386dfd6fa75155bfbcea6b4feaf3 /templates
parent84ed124529ffeee1590295b8de3a8faf51848680 (diff)
downloadmitjafelicijan.com-cd6644ea4ddc78597934ab0ef5ba50e3c3daa927.tar.gz
Moved to a simpler SSG
Diffstat (limited to 'templates')
-rw-r--r--templates/base.html156
-rw-r--r--templates/index.html105
-rw-r--r--templates/index.xml21
-rw-r--r--templates/note.html14
-rw-r--r--templates/notes.xml21
-rw-r--r--templates/page.html13
-rw-r--r--templates/post.html14
7 files changed, 344 insertions, 0 deletions
diff --git a/templates/base.html b/templates/base.html
new file mode 100644
index 0000000..8bc20be
--- /dev/null
+++ b/templates/base.html
@@ -0,0 +1,156 @@
1<!DOCTYPE html>
2<html lang="{{ .Config.Language }}">
3 <head>
4 <meta charset="utf-8">
5 <meta name="viewport" content="width=device-width,initial-scale=1">
6
7 <link href="data:image/x-icon;base64,AAABAAEAEBAAAAEAIABoBAAAFgAAACgAAAAQAAAAIAAAAAEAIAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAL69vf8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAv76+/8LBwQkAAAAAAAAAAAAAAAC+vb3/AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAL+9vf/Bv78JAAAAAAAAAAAAAAAAu7q6/wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAC7ubr/vr29CAAAAAAAAAAAy8nJAZ6foP8AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAnqGj/6G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f+wAA3/sAAAAAAAAAAAAAAAAAAN/7AAAAAAAAAAAAAAAAAAAAAAAAj/EAAI/5AACP8QAA3/sAAA==" rel="icon" type="image/x-icon" />
8
9 <title>{{ block "title" . }}{{ .Config.Title }}{{ end }}</title>
10
11 <meta name="description" content="{{ block "description" . }}{{ .Config.Description }}{{ end }}">
12
13 <link rel="alternate" type="application/rss+xml" title="Mitja Felicijan's posts" href="{{ .Config.BaseURL }}/index.xml">
14 <link rel="alternate" type="application/rss+xml" title="Mitja Felicijan's notes" href="{{ .Config.BaseURL }}/notes.xml">
15
16 <style>
17 body {
18 padding: 1rem;
19 max-width: 760px;
20 background: white;
21 font-family: "Times New Roman", Times, serif;
22 line-height: 1.35rem;
23 }
24
25 hr {
26 margin-block-start: 1.5rem;
27 }
28
29 h1, h2, h3 {
30 line-height: initial;
31 }
32
33 footer {
34 margin-block-start: 3rem;
35 }
36
37 table {
38 max-width: 100%;
39 border-collapse: separate;
40 border-spacing: 2px;
41 border: 1px solid black;
42 border-left: 1px solid #999;
43 border-top: 1px solid #999;
44 }
45
46 blockquote {
47 font-style: italic;
48 }
49
50 table thead {
51 background: #eee;
52 }
53
54 td, th {
55 border: 1px solid black;
56 padding: 4px;
57 border-right: 1px solid #999;
58 border-bottom: 1px solid #999;
59 text-align: left;
60 }
61
62 pre {
63 text-wrap: nowrap;
64 overflow-x: auto;
65 margin-block-start: 1.5rem;
66 margin-block-end: 1.5rem;
67 padding: 0.5rem 0;
68 border-top: 1px solid black;
69 border-bottom: 1px solid black;
70 }
71
72 pre code {
73 line-height: 1.3em;
74 }
75
76 pre, code, pre *, code * {
77 font-family: monospace;
78 font-size: initial !important;
79 }
80
81 img, video, audio {
82 max-width: 100%;
83 }
84
85 header {
86 display: flex;
87 flex-direction: row;
88 gap: 3rem;
89 }
90
91 nav {
92 display: flex;
93 gap: 0.75rem;
94 }
95
96 .pstatus-orange {
97 background: gold;
98 }
99 .pstatus-green {
100 background: yellowgreen;
101 }
102 .pstatus-red {
103 background: indianred;
104 }
105
106 @media only screen and (max-width: 600px) {
107 header {
108 flex-direction: column;
109 gap: 1rem;
110 }
111
112 a {
113 word-wrap: break-word;
114 }
115 }
116 </style>
117 </head>
118 <body>
119
120 <header>
121 <nav class="main">
122 <a href="/">Home</a>
123 <a href="https://git.mitjafelicijan.com/" target="_blank">Git</a>
124 <a href="https://files.mitjafelicijan.com/" target="_blank">Files</a>
125 <a href="/mitjafelicijan.pgp.pub.txt" target="_blank">PGP</a>
126 <a href="/curriculum-vitae.html">CV</a>
127 <a href="/index.xml" target="_blank">RSS</a>
128 </nav>
129
130 {{ block "add-navigation" . }}{{ end }}
131 </header>
132
133 <main>
134 {{ block "content" . }}{{ end }}
135 </main>
136
137 <footer>
138 <hr>
139 <div>
140 <h3>Want to comment or have something to add?</h3>
141 You can write me an email at
142 <a href="mailto:m@mitjafelicijan.com">m@mitjafelicijan.com</a> or catch up
143 with me
144 <a href="https://telegram.me/mitjafelicijan" target="_blank">on Telegram</a>.
145 </div>
146 <hr>
147 <p>This website does not track you. Content is made available under
148 the <a href="https://creativecommons.org/licenses/by/4.0/"
149 target="_blank" rel="noreferrer">CC BY 4.0 license</a> unless specified
150 otherwise. Blog feed is available as <a href="/index.xml"
151 target="_blank">RSS feed</a>.</p>
152 </footer>
153
154 <script src="https://cdn.usefathom.com/script.js" data-site="XHQARKXP" defer></script>
155 </body>
156</html>
diff --git a/templates/index.html b/templates/index.html
new file mode 100644
index 0000000..affec2d
--- /dev/null
+++ b/templates/index.html
@@ -0,0 +1,105 @@
1{{ template "base.html" . }}
2
3{{ define "add-navigation" }}
4<nav class="additional">
5 <a href="#current">current</a>
6 <a href="#posts">posts</a>
7 <a href="#notes">notes</a>
8 <a href="#sideprojects">side projects</a>
9</nav>
10{{ end }}
11
12{{ define "content" }}
13<div>
14 <h1>A place where I experiment and have fun!</h1>
15 <p>{{ .Config.Description }}</p>
16 <p>Please <b><i>stop offering me a redesign</i></b> of this webpage. This site
17 intentionally looks like it does!</p>
18
19 <h2><a name="current"></a>What I am currently working on</h2>
20 <p>Semi-live status of things to keep myself honest!</p>
21 <table>
22 <thead>
23 <tr>
24 <th width="5"></th>
25 <th>Project name</th>
26 <th>What is being worked on?</th>
27 <th>Last updated</th>
28 </tr>
29 </thead>
30 <tbody>
31 <tr>
32 <td class="pstatus-orange" title="Somewhat works"></td>
33 <td><a href="https://github.com/mitjafelicijan/errand" target="_blank">Errand - Task runner</a></td>
34 <td>Working on re-implementating the whole thing in C.</td>
35 <td>7th of June, 2023</td>
36 </tr>
37 <tr>
38 <td class="pstatus-green" title="Kinda works"></td>
39 <td><a href="https://github.com/mitjafelicijan/jbmafp" target="_blank">JBMAFP - Generates static sites</a></td>
40 <td>Fixing minor issues and writing docs.</td>
41 <td>8th of June, 2023</td>
42 </tr>
43 <tr>
44 <td class="pstatus-red" title="Still in initial stage"></td>
45 <td><a href="https://github.com/mitjafelicijan/marionette" target="_blank">Marionette - UI testing tool</a></td>
46 <td>Implementing HTTP server for viewing reports.</td>
47 <td>6th of June, 2023</td>
48 </tr>
49 </tbody>
50 </table>
51
52 <h2><a name="posts"></a>More long form, blog type of content</h2>
53 <ul>
54 {{ range .Pages }}
55 {{ if eq .Type "post" }}
56 <li><a href="/{{ .RelPermalink }}">{{ .Title }}</a></li>
57 {{ end }}
58 {{ end }}
59 </ul>
60
61 <h2><a name="notes"></a>Notes?! Maybe useful</h2>
62 <h2></h2>
63 <ul>
64 {{ range .Pages }}
65 {{ if eq .Type "note" }}
66 <li><a href="/{{ .RelPermalink }}">{{ .Title }}</a></li>
67 {{ end }}
68 {{ end }}
69 </ul>
70
71 <h2><a name="sideprojects"></a>Side projects I work/worked on</h2>
72 <table>
73 <tbody>
74 <tr>
75 <td><a href="https://git.mitjafelicijan.com/cord.h.git/" target="_blank">cord.h</a></td>
76 <td>Small C library for handling strings</td>
77 </tr>
78 <tr>
79 <td><a href="https://git.mitjafelicijan.com/mprogress.git/" target="_blank">mprogress</a></td>
80 <td>Tiny utility that displays progress bar in terminal</td>
81 </tr>
82 <tr>
83 <td><a href="https://git.mitjafelicijan.com/journalctl-proxy.git/" target="_blank">journalctl-proxy</a></td>
84 <td>Exposes your systemd logs to web via web interface</td>
85 </tr>
86 <tr>
87 <td><a href="https://git.mitjafelicijan.com/redis-marshal.git/" target="_blank">redis-marshal</a></td>
88 <td>Lightweight Redis data exploration tool</td>
89 </tr>
90 <tr>
91 <td><a href="https://git.mitjafelicijan.com/dna-encoding.git/" target="_blank">dna-encoding</a></td>
92 <td>Tools for encoding files to DNA sequence</td>
93 </tr>
94 <tr>
95 <td><a href="https://git.mitjafelicijan.com/vertex.git/" target="_blank">vertex</a></td>
96 <td>Create mock API's and add basic logic to simplify prototyping</td>
97 </tr>
98 <tr>
99 <td><a href="https://git.mitjafelicijan.com/scarecrow.git/" target="_blank">scarecrow</a></td>
100 <td>Minimal configuration reverse proxy</td>
101 </tr>
102 </tbody>
103 </table>
104</div>
105{{ end }}
diff --git a/templates/index.xml b/templates/index.xml
new file mode 100644
index 0000000..830dd90
--- /dev/null
+++ b/templates/index.xml
@@ -0,0 +1,21 @@
1<rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0">
2 <channel>
3 <title>{{ .Config.Title }}'s posts</title>
4 <link>{{ .Config.BaseURL }}</link>
5 <description>{{ .Config.Description }}</description>
6 <language>{{ .Config.Language }}</language>
7
8 {{ range $idx, $page := .Pages }}
9 {{ if eq $page.Type "post" }}
10 <item>
11 <title>{{ $page.Title }}</title>
12 <link>{{ $.Config.BaseURL }}/{{ $page.RelPermalink }}</link>
13 <pubDate>{{ $page.Created.Format "Mon, 02 Jan 2006 15:04:05 -0700" }}</pubDate>
14 <guid>{{ $.Config.BaseURL }}/{{ $page.RelPermalink }}</guid>
15 <description>{{ $page.Summary }}</description>
16 <content:encoded>{{ $page.Raw }}</content:encoded>
17 </item>
18 {{ end }}
19 {{ end }}
20 </channel>
21</rss>
diff --git a/templates/note.html b/templates/note.html
new file mode 100644
index 0000000..28ffad2
--- /dev/null
+++ b/templates/note.html
@@ -0,0 +1,14 @@
1{{ template "base.html" . }}
2
3{{ define "title" }}{{ .Page.Title }}{{ end }}
4{{ define "description" }}{{ .Page.Summary }}{{ end }}
5
6{{ define "content" }}
7<div>
8 <h1>{{ .Page.Title }}</h1>
9 <p>{{ .Page.Created.Format "Jan 2, 2006" }}</p>
10 <div>
11 {{ .Page.HTML }}
12 </div>
13</div>
14{{ end }}
diff --git a/templates/notes.xml b/templates/notes.xml
new file mode 100644
index 0000000..e314667
--- /dev/null
+++ b/templates/notes.xml
@@ -0,0 +1,21 @@
1<rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0">
2 <channel>
3 <title>{{ .Config.Title }}'s notes</title>
4 <link>{{ .Config.BaseURL }}</link>
5 <description>{{ .Config.Description }}</description>
6 <language>en-us</language>
7
8 {{ range $idx, $page := .Pages }}
9 {{ if eq $page.Type "note" }}
10 <item>
11 <title>{{ $page.Title }}</title>
12 <link>{{ $.Config.BaseURL }}/{{ $page.RelPermalink }}</link>
13 <pubDate>{{ $page.Created.Format "Mon, 02 Jan 2006 15:04:05 -0700" }}</pubDate>
14 <guid>{{ $.Config.BaseURL }}/{{ $page.RelPermalink }}</guid>
15 <description>{{ $page.Summary }}</description>
16 <content:encoded>{{ $page.Raw }}</content:encoded>
17 </item>
18 {{ end }}
19 {{ end }}
20 </channel>
21</rss>
diff --git a/templates/page.html b/templates/page.html
new file mode 100644
index 0000000..9303b68
--- /dev/null
+++ b/templates/page.html
@@ -0,0 +1,13 @@
1{{ template "base.html" . }}
2
3{{ define "title" }}{{ .Page.Title }}{{ end }}
4{{ define "description" }}{{ .Page.Summary }}{{ end }}
5
6{{ define "content" }}
7<div>
8 <h1>{{ .Page.Title }}</h1>
9 <div>
10 {{ .Page.HTML }}
11 </div>
12</div>
13{{ end }}
diff --git a/templates/post.html b/templates/post.html
new file mode 100644
index 0000000..28ffad2
--- /dev/null
+++ b/templates/post.html
@@ -0,0 +1,14 @@
1{{ template "base.html" . }}
2
3{{ define "title" }}{{ .Page.Title }}{{ end }}
4{{ define "description" }}{{ .Page.Summary }}{{ end }}
5
6{{ define "content" }}
7<div>
8 <h1>{{ .Page.Title }}</h1>
9 <p>{{ .Page.Created.Format "Jan 2, 2006" }}</p>
10 <div>
11 {{ .Page.HTML }}
12 </div>
13</div>
14{{ end }}