瀏覽代碼

porting blog to pastel theme, stasis

master
f0x 9 月之前
父節點
當前提交
41ce66a18a
共有 62 個文件被更改,包括 9254 次插入8424 次删除
  1. 1218
    8176
      package-lock.json
  2. 2
    1
      package.json
  3. 7320
    0
      shrinkwrap.yaml
  4. 二進制
      src/assets/Foks.png
  5. 二進制
      src/assets/Foks_transparent.png
  6. 二進制
      src/assets/ledspace/final.png
  7. 二進制
      src/assets/ledspace/final2.png
  8. 二進制
      src/assets/ledspace/psu.png
  9. 二進制
      src/assets/ledspace/rj45.png
  10. 二進制
      src/assets/ledspace/space.png
  11. 二進制
      src/assets/ledspace/strip solder update.png
  12. 二進制
      src/assets/ledspace/strip solder.png
  13. 二進制
      src/assets/ledspace/strip.png
  14. 二進制
      src/assets/ledspace/teardown.png
  15. 二進制
      src/assets/ledspace/wires.png
  16. 0
    5
      src/assets/main.scss
  17. 二進制
      src/assets/mario_box/box.mp4
  18. 二進制
      src/assets/mario_box/box.webm
  19. 二進制
      src/assets/mario_box/box1.jpg
  20. 二進制
      src/assets/mario_box/box2.jpg
  21. 二進制
      src/assets/mario_box/box2.webm
  22. 二進制
      src/assets/mario_box/box3.jpg
  23. 二進制
      src/assets/mario_box/box3.webm
  24. 二進制
      src/assets/mario_box/box4.jpg
  25. 二進制
      src/assets/mario_box/pcb.jpg
  26. 二進制
      src/assets/mudle.png
  27. 57
    0
      src/assets/rainbow.scss
  28. 二進制
      src/assets/rainbow_buttons/rect_finished.png
  29. 二進制
      src/assets/rainbow_buttons/rect_original.png
  30. 二進制
      src/assets/rainbow_buttons/rect_pcb1.jpg
  31. 二進制
      src/assets/rainbow_buttons/rect_pcb2.jpg
  32. 二進制
      src/assets/rainbow_buttons/round_finished.png
  33. 二進制
      src/assets/rainbow_buttons/round_original.png
  34. 二進制
      src/assets/rainbow_buttons/round_pcb1.png
  35. 二進制
      src/assets/rainbow_buttons/round_pcb2.png
  36. 二進制
      src/assets/rainbow_buttons/round_pcb3.png
  37. 二進制
      src/assets/rainbow_buttons/round_pcb4.png
  38. 二進制
      src/assets/rainbow_buttons/round_pcb5.png
  39. 二進制
      src/assets/rainbow_buttons/round_pcb6.png
  40. 1
    0
      src/assets/rice
  41. 1
    0
      src/assets/rice.png
  42. 201
    0
      src/assets/style.scss
  43. 7
    3
      src/graphql/index.js
  44. 6
    0
      src/helpers/daysSince.js
  45. 2
    32
      src/layouts/base.hbs
  46. 0
    35
      src/layouts/blog-archive.hbs
  47. 0
    27
      src/layouts/blog.hbs
  48. 5
    0
      src/layouts/projects.hbs
  49. 5
    5
      src/pages/404.md
  50. 0
    70
      src/pages/blog/hello-universe.md
  51. 0
    68
      src/pages/blog/hello-world.md
  52. 22
    2
      src/pages/index.md
  53. 22
    0
      src/pages/projects.md
  54. 47
    0
      src/pages/projects/lain.haus.md
  55. 38
    0
      src/pages/projects/ledspace.md
  56. 18
    0
      src/pages/projects/mario_box.md
  57. 52
    0
      src/pages/projects/rainbow_buttons.md
  58. 65
    0
      src/pages/projects/ssl.md
  59. 31
    0
      src/pages/rice.md
  60. 68
    0
      src/partials/main.hbs
  61. 66
    0
      src/static/powerlines.svg
  62. 二進制
      src/static/tile2.png

+ 1218
- 8176
package-lock.json
文件差異過大導致無法顯示
查看文件


+ 2
- 1
package.json 查看文件

@@ -29,6 +29,7 @@
29 29
     "sass": "^1.17.2"
30 30
   },
31 31
   "dependencies": {
32
-    "stasis-generator": "^0.1.0"
32
+    "stasis-generator": "^0.3.0",
33
+    "tslib": "^1.9.3"
33 34
   }
34 35
 }

+ 7320
- 0
shrinkwrap.yaml
文件差異過大導致無法顯示
查看文件


二進制
src/assets/Foks.png 查看文件


二進制
src/assets/Foks_transparent.png 查看文件


二進制
src/assets/ledspace/final.png 查看文件


二進制
src/assets/ledspace/final2.png 查看文件


二進制
src/assets/ledspace/psu.png 查看文件


二進制
src/assets/ledspace/rj45.png 查看文件


二進制
src/assets/ledspace/space.png 查看文件


二進制
src/assets/ledspace/strip solder update.png 查看文件


二進制
src/assets/ledspace/strip solder.png 查看文件


二進制
src/assets/ledspace/strip.png 查看文件


二進制
src/assets/ledspace/teardown.png 查看文件


二進制
src/assets/ledspace/wires.png 查看文件


+ 0
- 5
src/assets/main.scss 查看文件

@@ -1,5 +0,0 @@
1
-$font-color: #151515;
2
-
3
-body {
4
-	color: $font-color
5
-}

二進制
src/assets/mario_box/box.mp4 查看文件


二進制
src/assets/mario_box/box.webm 查看文件


二進制
src/assets/mario_box/box1.jpg 查看文件


二進制
src/assets/mario_box/box2.jpg 查看文件


二進制
src/assets/mario_box/box2.webm 查看文件


二進制
src/assets/mario_box/box3.jpg 查看文件


二進制
src/assets/mario_box/box3.webm 查看文件


二進制
src/assets/mario_box/box4.jpg 查看文件


二進制
src/assets/mario_box/pcb.jpg 查看文件


二進制
src/assets/mudle.png 查看文件


+ 57
- 0
src/assets/rainbow.scss 查看文件

@@ -0,0 +1,57 @@
1
+$red: #e81d1d;
2
+$orange: #e8b71d;
3
+$yellow: #e3e81d;
4
+$green: #1de840;
5
+$cyan: #1ddde8;
6
+$blue: #2b1de8;
7
+$purple: #dd00f3;
8
+
9
+
10
+$grey: #3b4252;
11
+$red: #bf616a;
12
+$green: #a3be8c;
13
+$yellow: #ebcb8b;
14
+$orange: darken($yellow, 15);
15
+$blue: #81a1c1;
16
+$purple: #b48ead;
17
+$cyan: #88c0d0;
18
+$white: #e5e9f0;
19
+
20
+@mixin rainbow($property) {
21
+  0% { /* red */
22
+    #{$property}: $red;
23
+  }
24
+  14% { /* orange */
25
+    #{$property}: $orange;
26
+  }
27
+  28% { /* yellow */
28
+    #{$property}: $yellow;
29
+  }
30
+  42% { /* green */
31
+    #{$property}: $green;
32
+  }
33
+  57% { /* cyan */
34
+    #{$property}: $cyan;
35
+  }
36
+  71% { /* blue */
37
+    #{$property}: $blue;
38
+  }
39
+  85% { /* purple */
40
+    #{$property}: $purple;
41
+  }
42
+  100% { /* red */
43
+    #{$property}: $red;
44
+  }
45
+}
46
+
47
+@keyframes rainbow-bg {
48
+  @include rainbow('background');
49
+}
50
+
51
+@keyframes rainbow-border {
52
+  @include rainbow('border-color');
53
+}
54
+
55
+@keyframes rainbow-fg {
56
+  @include rainbow('color');
57
+}

二進制
src/assets/rainbow_buttons/rect_finished.png 查看文件


二進制
src/assets/rainbow_buttons/rect_original.png 查看文件


二進制
src/assets/rainbow_buttons/rect_pcb1.jpg 查看文件


二進制
src/assets/rainbow_buttons/rect_pcb2.jpg 查看文件


二進制
src/assets/rainbow_buttons/round_finished.png 查看文件


二進制
src/assets/rainbow_buttons/round_original.png 查看文件


二進制
src/assets/rainbow_buttons/round_pcb1.png 查看文件


二進制
src/assets/rainbow_buttons/round_pcb2.png 查看文件


二進制
src/assets/rainbow_buttons/round_pcb3.png 查看文件


二進制
src/assets/rainbow_buttons/round_pcb4.png 查看文件


二進制
src/assets/rainbow_buttons/round_pcb5.png 查看文件


二進制
src/assets/rainbow_buttons/round_pcb6.png 查看文件


+ 1
- 0
src/assets/rice 查看文件

@@ -0,0 +1 @@
1
+/home/f0x/documents/rice

+ 1
- 0
src/assets/rice.png 查看文件

@@ -0,0 +1 @@
1
+rice/2019-03-08.png

+ 201
- 0
src/assets/style.scss 查看文件

@@ -0,0 +1,201 @@
1
+@import "rainbow";
2
+
3
+$bg: #24262e;
4
+$fg: mix($bg, white, 5%);
5
+
6
+/* Nord Palette */
7
+$grey: #3b4252;
8
+$red: #bf616a;
9
+$green: #a3be8c;
10
+$yellow: #ebcb8b;
11
+$blue: #81a1c1;
12
+$purple: #b48ead;
13
+$cyan: #88c0d0;
14
+$white: #e5e9f0;
15
+
16
+html, body {
17
+  background: $bg;
18
+  color: $fg;
19
+  margin: 0;
20
+  padding: 0;
21
+}
22
+
23
+.header {
24
+  margin-top: 3rem;
25
+  text-align: center;
26
+  .name {
27
+    display: inline-flex;
28
+    height: 4rem;
29
+    font-size: 4rem;
30
+
31
+    img {
32
+      margin-right: 1rem;
33
+      height: 100%;
34
+    }
35
+    margin-bottom: 1rem;
36
+  }
37
+
38
+  a {
39
+    font-size: 1.75rem;
40
+    padding: 0.5rem;
41
+  }
42
+}
43
+
44
+a {
45
+  color: $fg;
46
+  animation: rainbow-fg 8s ease infinite;
47
+}
48
+
49
+.content, .footer {
50
+  margin-top: 3rem;
51
+  box-sizing: border-box;
52
+  width: 80%;
53
+  margin-left: auto;
54
+  margin-right: auto;
55
+
56
+  border-left: 0.4rem solid transparent;
57
+  animation: rainbow-border 8s ease infinite;
58
+  background: lighten($bg, 10);
59
+  padding: 2.1rem;
60
+}
61
+
62
+.content {
63
+  h1 {
64
+    margin-top: 0;
65
+  }
66
+
67
+  .table {
68
+    background: lighten($bg, 5);
69
+    display: inline-grid;
70
+    grid-template-columns: 1fr 1fr;
71
+    border: 1px solid $fg;
72
+    border-right: none;
73
+    margin: 2rem 0;
74
+    position: relative;
75
+
76
+    .rotate {
77
+      display: inline-block;
78
+      position: absolute;
79
+      top: -2rem;
80
+      animation: circle 18s linear infinite;
81
+
82
+      img {
83
+        height: 2rem;
84
+        width: 2rem;
85
+        animation: wiggle 0.4s linear infinite;
86
+        margin: 0;
87
+      }
88
+    }
89
+
90
+    span, a {
91
+      border-bottom: 1px solid $fg;
92
+      border-right: 1px solid $fg;
93
+      padding: 1rem;
94
+      animation: none;
95
+
96
+      &:nth-child(odd) {
97
+        background: $bg;
98
+      }
99
+
100
+      &:last-of-type {
101
+        border-bottom: none;
102
+      }
103
+    }
104
+  }
105
+
106
+  pre {
107
+    overflow-x: auto;
108
+  }
109
+
110
+  img {
111
+    width: 100%;
112
+    margin: 1rem 0;
113
+  }
114
+
115
+  p {
116
+    margin-bottom: 0;
117
+  }
118
+
119
+  ul {
120
+    margin: 0;
121
+  }
122
+}
123
+
124
+.footer {
125
+  padding: 1rem;
126
+  margin-bottom: 3rem;
127
+  line-height: 1.6rem;
128
+
129
+  #daysSince b {
130
+    background: $fg;
131
+    color: black;
132
+    padding: 0.3rem;
133
+  }
134
+}
135
+
136
+@keyframes wiggle {
137
+  0%, 100% {
138
+    transform: rotate(10deg);
139
+  }
140
+  25% {
141
+    transform: rotate(0deg);
142
+  }
143
+
144
+  50% {
145
+    transform: rotate(-10deg);
146
+  }
147
+
148
+  75% {
149
+    transform: rotate(0deg);
150
+  }
151
+}
152
+
153
+@keyframes circle {
154
+  $size: 2rem;
155
+
156
+  0%, 100% {
157
+    top: -$size;
158
+    left: -$size;
159
+  }
160
+  22% {
161
+    transform: rotate(0deg);
162
+  }
163
+
164
+  25% {
165
+    top: -$size;
166
+    left: 100%;
167
+  }
168
+
169
+  28%, 47% {
170
+    transform: rotate(90deg);
171
+  }
172
+
173
+  50% {
174
+    top: 100%;
175
+    left: 100%;
176
+  }
177
+
178
+  53%, 72% {
179
+    transform: rotate(180deg);
180
+  }
181
+
182
+  75% {
183
+    top: 100%;
184
+    left: -$size;
185
+  }
186
+
187
+  78%, 97% {
188
+    transform: rotate(270deg);
189
+  }
190
+
191
+  100% {
192
+    transform: rotate(270deg);
193
+  }
194
+}
195
+
196
+@media screen and (orientation: portrait) { // mobile
197
+  .content, .footer {
198
+    width: 95%;
199
+    margin-top: 2rem;
200
+  }
201
+}

+ 7
- 3
src/graphql/index.js 查看文件

@@ -5,14 +5,17 @@ module.exports = {
5 5
         pageByIndex(index: Int!): Page
6 6
 		    pageByTitle(title: String!): Page
7 7
         pages: [Page]
8
+        linkedPages: [Page]
9
+        projectPages: [Page]
8 10
         posts: [Page]
9 11
     }
10 12
     type Page {
11 13
         html: String
12
-		frontmatter: Frontmatter
14
+		    frontmatter: Frontmatter
13 15
         excerpt: String
14 16
         relativePath: String
15 17
         active: Boolean
18
+        nolink: Boolean
16 19
     }
17 20
 	type Frontmatter {
18 21
 		title: String
@@ -23,10 +26,11 @@ module.exports = {
23 26
   } ,
24 27
   createRoot: (pages, config) => {
25 28
     return {
26
-      pages: () => pages,
29
+      pages: () => pages.filter(p => p.frontmatter.nolink != true),
27 30
       pageByIndex: args => pages[args.index],
28 31
       pageByTitle: args => pages.filter(p => p.frontmatter.tile === args.title),
32
+      projectPages: () => pages.filter(p => p.relativePath.startsWith("/projects/") && !p.relativePath.startsWith("/projects/index.html")),
29 33
       posts: args => pages.filter(p => p.frontmatter.type === 'blog')
30 34
     }
31 35
   }
32
-}
36
+}

+ 6
- 0
src/helpers/daysSince.js 查看文件

@@ -0,0 +1,6 @@
1
+module.exports = (args) => {
2
+  let since = new Date(args.fn(this).trim())
3
+  let now = new Date()
4
+  let timediff = now.getTime() - since.getTime()
5
+  return Math.ceil(timediff / (1000 * 60 * 60 * 24))
6
+}

+ 2
- 32
src/layouts/base.hbs 查看文件

@@ -1,32 +1,2 @@
1
-<!DOCTYPE html>
2
-<html lang="en">
3
-<head>
4
-	<meta charset="UTF-8">
5
-	<meta name="viewport" content="width=device-width, initial-scale=1.0">
6
-	<meta http-equiv="X-UA-Compatible" content="ie=edge">
7
-	<link rel="stylesheet" href="https://unpkg.com/terminal.css@0.6.6/dist/terminal.min.css" />
8
-	<title>{{meta.title}}</title>
9
-</head>
10
-<body class="terminal">
11
-	<div class="container">
12
-		<div class="terminal-nav">
13
-			<div class="terminal-logo">
14
-			<div class="logo terminal-prompt"><a href="/" class="no-style">Stasis Example Project</a></div>
15
-			</div>
16
-			<nav class="terminal-menu">
17
-			<ul>
18
-				<li><a class="menu-item" href="/blog">Blog</a></li>
19
-			</ul>
20
-			</nav>
21
-		</div>
22
-		<main>
23
-            <h1>Loop over all your pages using GraphQL</h1>
24
-            <ul>
25
-                {{#each this.query.data.pages}}
26
-                    <li><a href="{{this.relativePath}}">{{this.frontmatter.title}}</a></li>
27
-                {{/each}}
28
-            </ul>
29
-		</main>
30
-	</div>
31
-</body>
32
-</html>
1
+{{#> main }}
2
+{{/main}}

+ 0
- 35
src/layouts/blog-archive.hbs 查看文件

@@ -1,35 +0,0 @@
1
-
2
-<!DOCTYPE html>
3
-<html lang="en">
4
-<head>
5
-	<meta charset="UTF-8">
6
-	<meta name="viewport" content="width=device-width, initial-scale=1.0">
7
-	<meta http-equiv="X-UA-Compatible" content="ie=edge">
8
-	<link rel="stylesheet" href="https://unpkg.com/terminal.css@0.6.6/dist/terminal.min.css" />
9
-	<title>{{meta.title}}</title>
10
-</head>
11
-<body class="terminal">
12
-	<div class="container">
13
-		<div class="terminal-nav">
14
-			<div class="terminal-logo">
15
-			<div class="logo terminal-prompt"><a href="/" class="no-style">Stasis Example Project</a></div>
16
-			</div>
17
-			<nav class="terminal-menu">
18
-			<ul>
19
-				<li><a class="menu-item" href="/blog">Blog</a></li>
20
-			</ul>
21
-			</nav>
22
-		</div>
23
-		<main>
24
-            <div>
25
-                {{{body}}}
26
-            </div>
27
-			<ol class="terminal-toc">
28
-                {{#each this.query.data.posts}}
29
-                    <li><a href="{{this.relativePath}}">{{this.frontmatter.title}}</a></li>
30
-                {{/each}}
31
-			</ol>
32
-		</main>
33
-	</div>
34
-</body>
35
-</html>

+ 0
- 27
src/layouts/blog.hbs 查看文件

@@ -1,27 +0,0 @@
1
-<!DOCTYPE html>
2
-<html lang="en">
3
-<head>
4
-	<meta charset="UTF-8">
5
-	<meta name="viewport" content="width=device-width, initial-scale=1.0">
6
-	<meta http-equiv="X-UA-Compatible" content="ie=edge">
7
-	<link rel="stylesheet" href="https://unpkg.com/terminal.css@0.6.6/dist/terminal.min.css" />
8
-	<title>{{meta.title}}</title>
9
-</head>
10
-<body class="terminal">
11
-	<div class="container">
12
-		<div class="terminal-nav">
13
-			<div class="terminal-logo">
14
-			<div class="logo terminal-prompt"><a href="/" class="no-style">Stasis Example Project</a></div>
15
-			</div>
16
-			<nav class="terminal-menu">
17
-			<ul>
18
-				<li><a class="menu-item active" href="/blog">Blog</a></li>
19
-			</ul>
20
-			</nav>
21
-		</div>
22
-		<main>
23
-			{{{body}}}
24
-		</main>
25
-	</div>
26
-</body>
27
-</html>

+ 5
- 0
src/layouts/projects.hbs 查看文件

@@ -0,0 +1,5 @@
1
+{{#> main }}
2
+  {{#each this.query.data.projectPages}}
3
+    <a href={{this.relativePath}}>{{this.frontmatter.title}}</a><br>
4
+  {{/each}}
5
+{{/main}}

src/pages/blog/index.md → src/pages/404.md 查看文件

@@ -1,14 +1,14 @@
1 1
 ---
2
-layout: blog-archive
3
-title: All Blog Posts
2
+layout: base
3
+title: 404
4 4
 query: '{
5
-    posts {
5
+    pages {
6 6
         frontmatter {
7 7
             title
8 8
         }
9 9
         relativePath
10 10
     }
11 11
 }'
12
+nolink: true
12 13
 ---
13
-
14
-## All blog post
14
+whoopsies, that doesn't exist!

+ 0
- 70
src/pages/blog/hello-universe.md 查看文件

@@ -1,70 +0,0 @@
1
----
2
-layout: blog
3
-title: Hello Universe
4
-type: blog
5
----
6
-
7
-## Hello Universe.
8
-
9
-Lorem markdownum Ulixem non animam relicta, mite pectus: **a** quam cupidine
10
-clausa undae, nec quid sonuere sedes. Inhaerebat nudaque flammaque exclamant
11
-nostrum servata optandi caput illo attollens comes sollertia unxit descendat,
12
-Helenamque crebros obruta male. Saeviat et flammis accipe sedibus nervis
13
-spolioque in molem *reparabile sulco* et brevi, et et, pro caedis. Ex te, rerum
14
-ab cecinisse totas timeto reccidat tantumque *quoque dominoque* venti.
15
-
16
-- Quassasque in servat cernitis cernentem extremas
17
-- Fieri laetitiae undis
18
-- Aqua aurea laetis invidiosus inculpata
19
-- Armo traherent Hectore deos rursus
20
-
21
-In in *rogum colebat*, est noxque vetustas pariter reticere, et tempora et
22
-frustra extemplo. Dixere movit meta terrae [sopistis
23
-est](http://mansura-nostraque.net/gurgitefelixque.php); lustrat regni, destituit
24
-lacrimas propiore noctes animus poenas concurrere.
25
-
26
-## Et solebat missa dubitet mea tam
27
-
28
-Indice siccis vestrum dum manifesta arsit stimuletur utinam guttura recentes.
29
-Meum praecingitur nurus?
30
-
31
-Unus flammis pater. Est possit Achille ponitque adspicias temeraria terrent
32
-sororis capiti.
33
-
34
-## Premebat plura nostris nova cum infirmos mihi
35
-
36
-Fuso pubis tollere ripae ponti res protinus, frustra [amat](http://www.una.io/),
37
-potiturque. Metus quam flammas manu Triptolemus ante: mitis casusque sacrilega
38
-deprendit contra stipe; hasta agmen quamquam? Deflent luminibus Numici ab
39
-remissis iacentem sonantia.
40
-
41
-Quae tulit dea, *pecudis nos* medias fastigia, veste. Fecit medio virgam pecoris
42
-tamen: si [nurusque iuvabat](http://gavisus.com/) tu effugit calido Calydonius
43
-Subaris inexpugnabile his.
44
-
45
-    if (zeroDbmsIntellectual == e_netbios) {
46
-        tutorialScareware -= nanometer_processor_finder / yahooHocWpa(
47
-                personal_virus, mirrored);
48
-        default_ide_intranet += lanDaemon + 2;
49
-        big_bar_banner.data_dial(mail(pipeline_domain_smm, 1,
50
-                virus_yottabyte_backup), disk_visual_wep.ruby_parallel(
51
-                lossless_io_internic));
52
-    } else {
53
-        megabyte_storage_matrix.module = nntp - logic_lpi_drive;
54
-        telecommunications.cpm.isp(-3);
55
-    }
56
-    if (bank(bit_code - 5, error_computer_stack)) {
57
-        wordConstant(diskMacStorage(google_aiff_circuit), word.standby(dpi,
58
-                copy_document_definition, 1), e_wireless - bittorrent);
59
-    } else {
60
-        cd(start, -5);
61
-        gps_disk_orientation += spider;
62
-        blob.software += 2;
63
-    }
64
-    var friend = characterScraping + partition_analyst;
65
-
66
-Rettulit repetunt natus. Sic feris me vultus, e veribus ignaro, Hecaten in hanc,
67
-cum cognoscenda. Quotiens sonum, o respicit est Aeneae venerat io solvit vesica.
68
-Premunt respice violenta *animoque locum* inguinibus habebat summa suos aurum
69
-opacas dives pharetratae Ixione essent. *Non nostri damnans* pondus cum possent
70
-est.

+ 0
- 68
src/pages/blog/hello-world.md 查看文件

@@ -1,68 +0,0 @@
1
----
2
-layout: blog
3
-title: Hello World
4
-type: blog
5
----
6
-
7
-## Hello world.
8
-
9
-Lorem markdownum spumisque sponte Aurora, si luminis dilexit sub pello harena,
10
-nec, colebatur hausi obvertere illa. Dum Pelion, ictu impetus, fores coniunctior
11
-rogat, laude. Leto fortuna, si lactentem illa natura tam; adhuc *villo
12
-cruentior* eratis. Gradive iuvenum. Huc exaudi testis vindexque mundum.
13
-
14
-    var fat = mashup_lpi_boot(io, rippingGpuAddress);
15
-    resources.troubleshooting(page_publishing_motherboard.data(soundFile, plugXp
16
-            - idePhpInterface, internic));
17
-    if (multicasting) {
18
-        p_system(gigo + textCybersquatterDeprecated, cable.compiler(tween_dbms,
19
-                bar_system_capacity));
20
-    } else {
21
-        servletFile = 2;
22
-    }
23
-    var key = vle_halftone_android;
24
-    if (rdf_pharming(ip_pci_card, compression + avatarJfs, remote_biometrics)) {
25
-        formatUpload += cd_wysiwyg_module;
26
-        samba_unit_smartphone = native;
27
-        hashtag_ipx.newbie_printer_spider(post_view(memory_repeater));
28
-    } else {
29
-        desktop += -4;
30
-        barAd += 4 - banner + rjNetiquetteHard.android(nasRom, irq);
31
-        number_art_pseudocode(aiff_web, tagSliLogic);
32
-    }
33
-
34
-## Umeris sine
35
-
36
-Contemptor subitae ortus precor illa, deorum accipe? In epulis ab pietas putat,
37
-ab **addunt** a dicta undam atque mentem decursa Paeonis.
38
-
39
-Pedesque gemma ab Cassiope caedit admota. Montes bracchia securae Atlantiades
40
-adde pectusque. Sed maris quoque, est magis hominesque tenebat ignes ornant:
41
-casus lapsa promunturiumque pervenit se cumque pudorem!
42
-
43
-## Tum donavi tetigit Phineu procul
44
-
45
-Rursus hinc, ut latoque segetes deme invideatis potest igne tactis Actaea dabat
46
-erat orbus hi numinis resistunt falsa obscenas. Vitreis suspiria, monitis
47
-nomina, veniat. Lapsasque gratus tremit ima viget diximus paulatim undis colorem
48
-subnixa **subposuisse cruciata** tantum se serae habenas. Negare in alis, ire
49
-huc!
50
-
51
-## Ferebat generosos lustrat concipias genuisse humus iaculum
52
-
53
-Elimat dominasque avenis virgo meos rogabat nullam novissima hostes, et
54
-harundine tamen; crudelis subita quam, **acu credere**. Saepe in iaculis quoque
55
-ait est inter suam fontana lancea foret? Tenentem ab laeta; est postquam tura
56
-hactenus pascua certis, litora.
57
-
58
-## Est putat instabat et copia liquitur occubuisse
59
-
60
-Retinet laudibus modo tristia adveniens angue mersitque resolvit perque tardae.
61
-Arma imoque, matris sive modo **pedibus**!
62
-
63
-Lumina egredere et virgo obliquis, *vita* chlamydem augebat secus id mediusve:
64
-ferunt mortuaque urbe tuae scopulis officiis. A num matrem glaebam Cyllaron
65
-lanificae ova prius adfixa uda specus seque cunas aut navale causa Tyrrhenaque
66
-ambo; oblitis. Secum favorque sustinui manus. Sociati filia exstat temptat
67
-refugit vero, et a coniunx intres. Virgineo additus mutatis ausorum; ipsa, ora
68
-dixisse mutavit, sceleri!

+ 22
- 2
src/pages/index.md 查看文件

@@ -1,6 +1,6 @@
1 1
 ---
2 2
 layout: base
3
-title: Stasis Basic Example
3
+title: home
4 4
 query: '{
5 5
     pages {
6 6
         frontmatter {
@@ -11,4 +11,24 @@ query: '{
11 11
 }'
12 12
 ---
13 13
 
14
-# Hello World
14
+# Hello there!
15
+## Welcome to my corner of the wired
16
+I write free software, solder rgb leds and fly quads.  
17
+I also run [lain.haus](https://lain.haus), where I provide services such as chat and git hosting.  
18
+If you like what I do, you can donate to my <a href="https://liberapay.com/f0x/donate">Liberapay</a>
19
+
20
+## Links
21
+<div class="table">
22
+  <div class="rotate">
23
+    <img src="/assets/Foks_transparent.png" alt="fox running around the table">
24
+  </div>
25
+  <span>Matrix: </span> <a href="https://matrix.to/#/@f0x:lain.haus">@f0x:lain.haus</a>
26
+  <span>Mastodon: </span><a href="https://cyberia.social/@foks" rel="me">@foks@cyberia.social</a>
27
+  <span>Twitter: </span><a href="https://twitter.com/f0x52">@f0x52</a>
28
+  <span>WriteFreely</span><a href="https://write.lain.haus/f0x/">write.lain.haus</a>
29
+  <span>Git: </span><a href="https://git.lain.haus/f0x">git.lain.haus/f0x</a>
30
+  <span>Github: </span><a href="https://github.com/f0x52">f0x52</a>
31
+  <span>Keybase: </span><a href="https://keybase.io/f0x52">f0x52</a>
32
+  <span>Freenode: </span><span>f0x, f0x2</span>
33
+  <span>Email: </span><a href="mailto:f@0x52.eu">f@0x52.eu</a>
34
+</div>

+ 22
- 0
src/pages/projects.md 查看文件

@@ -0,0 +1,22 @@
1
+---
2
+layout: projects
3
+title: projects
4
+query: '{
5
+    pages {
6
+        frontmatter {
7
+            title
8
+        }
9
+        relativePath
10
+    }
11
+    projectPages {
12
+      frontmatter {
13
+        title
14
+      }
15
+      relativePath
16
+    }
17
+}'
18
+---
19
+# My Projects:
20
+I'm bad at writing actual pages for my project, and if you're interested in my new stuff you're probably better off following me [on Mastodon](https://cyberia.social/@foks).  
21
+I also participate in [tilde.industries](https://tilde.industries) so make sure to check that out as well.  
22
+Here's a list of projects I *have* written a page about: <br>

+ 47
- 0
src/pages/projects/lain.haus.md 查看文件

@@ -0,0 +1,47 @@
1
+---
2
+layout: base
3
+title: lain.haus
4
+query: '{
5
+    pages {
6
+        frontmatter {
7
+            title
8
+        }
9
+        relativePath
10
+    }
11
+}'
12
+nolink: true
13
+---
14
+
15
+# What is lain.haus
16
+
17
+I used to be quite active in the lainchan imageboard community, themed around the Serial Experiments Lain anime, and focussed on Cyberpunk, tech, politics and (glitch)art. The communities have since went to shit (tl;dr: drama), and I wouldn't recommend either of the lain-connected imageboards that are available now.
18
+
19
+This started somewhere in 2017, running a few services for myself: Matrix and Pleroma. After a while I invited some of my friends (most of whom I met through the lainchan community (site(s) are now bad :/), hence the name (oof that's a lot of parenthesis)).
20
+Inspired by service providers such as [Disroot](https://disroot.org), [Wehost](https://weho.st) and [Riseup](https://riseup.net). I decided to open up my services to the public a while later.
21
+
22
+I volunteer to run everything, but I do get some donations (not enough to cover)
23
+
24
+## Finances
25
+
26
+My services don't cost any money, but I do ask everyone to consider donating to my [Liberapay](http://liberapay.com/f0x/donate)
27
+
28
+## How it's run
29
+
30
+The domain is courtesy of [Thufie](https://cyberia.social/@lunaterra/). The services are spread out over three servers:
31
+
32
+Akropolis: main Hetzner VPS
33
+Leviathan: beefy gamer laptop that's now a server, doing all the heavy lifting
34
+Aecor: new DigitalOcean droplet because I got education credit for 10months
35
+
36
+All Leviathan traffic is routed through Akropolis using wireguard to protect my home ip.
37
+
38
+I run:  
39
+  [Matrix](https://matrix.org) for federated chat  
40
+  [Mastodon](https://joinmastodon.org) for federated microblogging  
41
+  [WriteFreely](https://writefreely.org/) for blogging  
42
+  [Gitea](https://gitea.io) for git hosting  
43
+  [Mumble](https://mumble.info) for voice chat
44
+
45
+
46
+For Matrix I also run an irc and Telegram bridge.  
47
+More info can be found on [lain.haus](https://lain.haus)

+ 38
- 0
src/pages/projects/ledspace.md 查看文件

@@ -0,0 +1,38 @@
1
+---
2
+layout: base
3
+title: ledspace
4
+query: '{
5
+    pages {
6
+        frontmatter {
7
+            title
8
+        }
9
+        relativePath
10
+    }
11
+}'
12
+nolink: true
13
+
14
+---
15
+
16
+# Ledspace
17
+
18
+To color up my local hackerspace, I proposed to make 13 RGB tube lights. After getting a budget and waiting for Aliexpress, the fun could begin.  
19
+
20
+As a base I'm using Hornbach's <a href="https://www.hornbach.nl/shop/LED-Armatuur-20-Watt-1200-mm-koel-wit-Energieklasse-A/5825358/artikel.html"> White LED Tube Light</a>, which offer a beautiful diffuser with aluminium heatsink. Sadly Hornbach discontinued these. Their new design is more expensive and all plastic :(  
21
+We start by tearing it down, which is surprisingly easy:
22
+<img id="img" src="/assets/ledspace/teardown.png">
23
+After removing the white led pcb, it's time to glue 1.2 meters of APA102 strip in it's place.
24
+<img id="img" src="/assets/ledspace/strip.png">
25
+For connecting the tubes, I'm using RJ45 connectors. the TX pair (orange) for data, and the Power pair (brown) for clock. They are both twisted with a ground.
26
+<img id="img" src="/assets/ledspace/strip solder update.png">
27
+The RJ45 connector fits snuggly inside the casing
28
+<img id="img" src="/assets/ledspace/wires.png">
29
+The PSU consists of 2 USB plugs, and an IKEA KOPLA power supply
30
+<img id="img" src="/assets/ledspace/psu.png">
31
+On the other side of the tube is another RJ45, which transfers ground, clock and data to the next tube
32
+With two connected togeather, it already looks great!
33
+<img id="img" src="/assets/ledspace/final.png">
34
+Here I installed the first two, driven by an Arduino Nano. Later on, a Raspberry Pi Zero W will take it's place.
35
+<img id="img" src="/assets/ledspace/final2.png">
36
+
37
+Here's half of them hanging. The Arduino was upgraded to a Raspberry 3B+, running an SPI driver in C, controlled over STDIN by a bunch of Perl, which can all be found [here](https://github.com/revspace/ledspace)
38
+<img src="/assets/ledspace/space.png">

+ 18
- 0
src/pages/projects/mario_box.md 查看文件

@@ -0,0 +1,18 @@
1
+---
2
+layout: base
3
+title: mario box
4
+permalink: /projects/mario_box/
5
+nolink: true
6
+---
7
+
8
+# Mario Box
9
+
10
+For a friends birthday I made a NodeMCU box. The NodeMCU runs micropython, it has a speaker, a sha badge lipo with charging circuit, and a rainbow button with 4 SK6812 RGBW led's. It comes preloaded with a boot.py that plays a mario tune when you start it/press the button.<br><br>
11
+<div class="gallery">
12
+<video src='/assets/mario_box/box2.webm' controls></video>
13
+<img class="double" class="double" src='/assets/mario_box/box1.jpg' alt='top view, led on'>
14
+<img class="double" src='/assets/mario_box/box2.jpg' alt='top view, led off'>
15
+<img class="double" src='/assets/mario_box/pcb.jpg' alt='modded button pcb'><br>
16
+<img src='/assets/mario_box/box3.jpg' alt='barrel jack for charging'>
17
+<img src='/assets/mario_box/box4.jpg' alt='power button'>
18
+</div>

+ 52
- 0
src/pages/projects/rainbow_buttons.md 查看文件

@@ -0,0 +1,52 @@
1
+---
2
+layout: base
3
+title: rainbow buttons
4
+permalink: /projects/rainbow_buttons/
5
+nolink: true
6
+---
7
+
8
+# Rainbow Buttons
9
+
10
+I've recently started upgrading old elevator buttons, with LED's, which makes them look great. I started
11
+with a rectangular one, for a button in our hackerspace. After that the challenge continued with a
12
+round version.
13
+<div class="gallery">
14
+    <img src="/assets/rainbow_buttons/rect_finished.png" alt="Rectangular RGBW Button">
15
+    <img src="/assets/rainbow_buttons/round_finished.png" alt="Round RGBW Button">
16
+</div>
17
+
18
+These are the original internal pcb's of both:
19
+<div class="gallery">
20
+    <img src="/assets/rainbow_buttons/rect_original.png" alt="Original Rectangular PCB">
21
+    <img src="/assets/rainbow_buttons/round_original.png" alt="Original Round PCB">
22
+</div>
23
+I've done quite a few iterations of the rectangular pcb, breaking some of the LED's or having other trouble.
24
+<div class="gallery">
25
+    <img src="/assets/rainbow_buttons/rect_pcb1.jpg" alt="Rectangular PCB">
26
+    <img src="/assets/rainbow_buttons/rect_pcb2.jpg" alt="Rectangular PCB">
27
+</div>
28
+It has 4 addressable SK6812 RGBW LED's, in comparison to the default 4 orange ones in series. A 2x2 header on the back exposes 5v, ground, data pin and the button lead, which connects to ground when pressed.
29
+This is the finished frontpanel, a huge improvement in my opinion:
30
+<img id="img" src="/assets/rainbow_buttons/rect_finished.png" alt="Finished Rectangular frontpanel">
31
+
32
+After this, it was time for the round one.  
33
+This proved a bit more of a challenge, because of the limited pcb space, and getting the round shape.
34
+My first finished round button went into the <a href="/projects/mario_box">mario box</a>, and I only made pictures of the back and front, when it was already assembled. For our hackerspace's light switches, I decided to document the process a lot better.
35
+First got 2 square protoboards, by cutting with a boxcutter, and then breaking
36
+<img id="img" src="/assets/rainbow_buttons/round_pcb1.png">
37
+Then I made them round by cutting, filing and sanding, and drilled 2 holes to fit the button's plastic extruders.
38
+<img id="img" src="/assets/rainbow_buttons/round_pcb2.png">
39
+After that I fit the 4 LED's, and soldered them in place
40
+<img id="img" src="/assets/rainbow_buttons/round_pcb3.png">
41
+The button goes in the middle, and to fit the stem, I had to cut it a bit, and then add some hotglue
42
+<img id="img" src="/assets/rainbow_buttons/round_pcb4.png">
43
+Then I laid out the wires to connect everything. Because it fits better, the LED's are connected a bit unintuitively, like this:
44
+    2  1
45
+    3  4
46
+Which has to be corrected in software.
47
+<div class="gallery">
48
+    <img src="/assets/rainbow_buttons/round_pcb5.png">
49
+    <img src="/assets/rainbow_buttons/round_pcb6.png">
50
+</div>
51
+Which gives the finished buttons:
52
+<img id="img" src="/assets/rainbow_buttons/round_finished.png">

+ 65
- 0
src/pages/projects/ssl.md 查看文件

@@ -0,0 +1,65 @@
1
+---
2
+layout: base
3
+title: ssl
4
+permalink: /projects/ssl/
5
+nolink: true
6
+---
7
+
8
+# SSL
9
+
10
+Good SSL is important for **any** site. Over time I've combined bits of other configs, giving me this setup (which also gives a perfect [ssltest](https://www.ssllabs.com/ssltest/analyze.html?d=f.0x52.eu) score):  
11
+
12
+First generate /etc/ssl/certs/dhparam.pem:  
13
+<code>
14
+sudo openssl dhparam -dsaparam -out /etc/ssl/certs/dhparam.pem 8192
15
+</code>
16
+<br>
17
+Nginx config:
18
+<pre><code>server {
19
+    listen 443 ssl;
20
+    listen [::]:443 ssl;
21
+    server_name f.0x52.eu, 0x52.eu, www.0x52.eu;
22
+    ssl_certificate /etc/letsencrypt/live/f.0x52.eu/fullchain.pem; # managed by Certbot
23
+    ssl_certificate_key /etc/letsencrypt/live/f.0x52.eu/privkey.pem; # managed by Certbot
24
+
25
+    ssl_dhparam /etc/ssl/certs/dhparam.pem;
26
+    ssl_protocols TLSv1.2;
27
+    ssl_prefer_server_ciphers on;
28
+    ssl_ciphers AES256+EECDH:AES256+EDH:!aNULL;
29
+    ssl_ecdh_curve secp384r1; # Requires nginx >= 1.1.0
30
+    ssl_session_cache shared:SSL:10m;
31
+    ssl_session_timeout 10m;
32
+
33
+    ssl_session_tickets off; # Requires nginx >= 1.5.9
34
+    ssl_stapling on; # Requires nginx >= 1.3.7
35
+    ssl_stapling_verify on; # Requires nginx => 1.3.7
36
+    resolver 87.98.175.85 5.9.49.12 193.183.98.154 5.135.183.146 valid=300s;
37
+    resolver_timeout 5s;
38
+    add_header Strict-Transport-Security "max-age=63072000; includeSubDomains; preload";
39
+    add_header X-Frame-Options DENY;
40
+    add_header X-Content-Type-Options nosniff;
41
+    gzip off;
42
+
43
+    root /var/www/f.0x52.eu;
44
+}
45
+
46
+server {
47
+    listen 80;
48
+    server_name f.0x52.eu, 0x52.eu, www.0x52.eu;
49
+
50
+    location / {
51
+        if ($scheme != "https"){
52
+            return 301 https://$host$request_uri;
53
+        }
54
+        return 404;
55
+    }
56
+}
57
+</code></pre>
58
+<br>
59
+You'll need to comment out the 443 block before generating the first cert, otherwise nginx complains about the nonexistent cert files.<br><br>
60
+Get letsencrypt certs:
61
+<code>
62
+sudo certbot --authenticator webroot --installer nginx -d f.0x52.eu -d 0x52.eu -d www.0x52.eu --rsa-key-size 4096
63
+</code>
64
+<br>
65
+Remove the 443 block comments, restart nginx and all should be great!

+ 31
- 0
src/pages/rice.md 查看文件

@@ -0,0 +1,31 @@
1
+---
2
+layout: base
3
+title: rice
4
+query: '{
5
+    pages {
6
+        frontmatter {
7
+            title
8
+        }
9
+        relativePath
10
+    }
11
+}'
12
+---
13
+
14
+# My rice
15
+I Really like ricing, and I change stuff around quite often.<br>
16
+Basically all my systems run [Debian Sid](https://www.debian.org/releases/sid/), and I use:<br>
17
+**wm:** bspwm<br>
18
+**terminal:** st<br>
19
+**browser:** firefox nightly<br>
20
+**editor:** Atom<br>
21
+**chat:**<br>
22
+  * telegram<br>
23
+  * <a href="https://riot.im">riot</a><br>
24
+
25
+
26
+
27
+You can find all my dotfiles [here](https://git.lain.haus/f0x/dots)
28
+### Current rice:
29
+<div class="gallery">
30
+  <a href="/assets/rice.png"><img src="/assets/rice.png" alt="My current rice"></a>
31
+</div>

+ 68
- 0
src/partials/main.hbs 查看文件

@@ -0,0 +1,68 @@
1
+<!DOCTYPE html>
2
+<html lang="en">
3
+  <head>
4
+    <meta charset="utf-8" />
5
+    <meta name="viewport" content="width=device-width" />
6
+    <title>{{this.frontmatter.title}}</title>
7
+    <link href="/assets/style.css" rel="stylesheet" type="text/css">
8
+    <script>
9
+    /*
10
+      @licstart  The following is the entire license notice for the
11
+      JavaScript code in this page.
12
+
13
+      Copyright (C) 2019 Foks
14
+
15
+      The JavaScript code in this page is free software: you can
16
+      redistribute it and/or modify it under the terms of the GNU
17
+      General Public License (GNU GPL) as published by the Free Software
18
+      Foundation, either version 3 of the License, or (at your option)
19
+      any later version.  The code is distributed WITHOUT ANY WARRANTY;
20
+      without even the implied warranty of MERCHANTABILITY or FITNESS
21
+      FOR A PARTICULAR PURPOSE.  See the GNU GPL for more details.
22
+
23
+      As additional permission under GNU GPL version 3 section 7, you
24
+      may distribute non-source (e.g., minimized or compacted) forms of
25
+      that code without the copy of the GNU GPL normally required by
26
+      section 4, provided you include this license notice and a URL
27
+      through which recipients can access the Corresponding Source.
28
+
29
+      @licend The above is the entire license notice
30
+      for the JavaScript code in this page.
31
+    */
32
+    </script>
33
+  </head>
34
+  <body>
35
+    <div class="header">
36
+      <div class="name">
37
+        <img src="/assets/Foks_transparent.png" align="center">
38
+        Foks
39
+      </div><br>
40
+      {{#each this.query.data.pages}}
41
+      <a href="{{this.relativePath}}">{{this.frontmatter.title}}</a>
42
+      {{/each}}
43
+    </div>
44
+    <div class="content">
45
+			{{{body}}}
46
+      {{> @partial-block}}
47
+    </div>
48
+    <div class="footer">
49
+      it has been <span id="daysSince">approximately <b>{{#daysSince}}2019-03-08T21:25:11+00:00{{/daysSince}}</b> days</span> since last using frontend JavaScript on this site<br>
50
+      This site is built with <a href="https://github.com/Gioni06/stasis-generator">Stasis</a>, a static site generator written in TypeScript.<br>
51
+      The source can be found <a href="">here</a>.
52
+    </div>
53
+    <script>
54
+      // this is obviously a joke. My static site generator will update the html on compile,
55
+      // but to get it updated you do need JS :P
56
+      // Furthermore, not all JS is bad
57
+
58
+      let daysSince = document.getElementById("daysSince")
59
+
60
+      let since = new Date("2019-03-08T21:25:11+00:00")
61
+      let now = new Date()
62
+      let timediff = now.getTime() - since.getTime()
63
+      let days = Math.ceil(timediff / (1000 * 60 * 60 * 24))
64
+      let plural = days != 1 ? 'days' : 'day'
65
+      daysSince.innerHTML = `<b>${days}</b> ${plural}`
66
+    </script>
67
+  </body>
68
+</html>

+ 66
- 0
src/static/powerlines.svg
文件差異過大導致無法顯示
查看文件


二進制
src/static/tile2.png 查看文件


Loading…
取消
儲存