Skip to content

Commit 68834b5

Browse files
committed
start rewrite
1 parent c7112ae commit 68834b5

File tree

13 files changed

+164
-170
lines changed

13 files changed

+164
-170
lines changed

Gemfile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
source 'https://rubygems.org'
2-
gem 'github-pages'
2+
gem "github-pages", group: :jekyll_plugins
3+
gem "webrick"

Gemfile.lock

Lines changed: 49 additions & 63 deletions
Original file line numberDiff line numberDiff line change
@@ -1,63 +1,48 @@
11
GEM
22
remote: https://rubygems.org/
33
specs:
4-
activesupport (6.0.4.1)
4+
activesupport (6.0.6)
55
concurrent-ruby (~> 1.0, >= 1.0.2)
66
i18n (>= 0.7, < 2)
77
minitest (~> 5.1)
88
tzinfo (~> 1.1)
99
zeitwerk (~> 2.2, >= 2.2.2)
10-
addressable (2.8.0)
11-
public_suffix (>= 2.0.2, < 5.0)
10+
addressable (2.8.1)
11+
public_suffix (>= 2.0.2, < 6.0)
1212
coffee-script (2.4.1)
1313
coffee-script-source
1414
execjs
1515
coffee-script-source (1.11.1)
1616
colorator (1.1.0)
17-
commonmarker (0.17.13)
18-
ruby-enum (~> 0.5)
19-
concurrent-ruby (1.1.9)
20-
dnsruby (1.61.7)
17+
commonmarker (0.23.6)
18+
concurrent-ruby (1.1.10)
19+
dnsruby (1.61.9)
2120
simpleidn (~> 0.1)
2221
em-websocket (0.5.3)
2322
eventmachine (>= 0.12.9)
2423
http_parser.rb (~> 0)
25-
ethon (0.15.0)
24+
ethon (0.16.0)
2625
ffi (>= 1.15.0)
2726
eventmachine (1.2.7)
2827
execjs (2.8.1)
29-
faraday (1.8.0)
30-
faraday-em_http (~> 1.0)
31-
faraday-em_synchrony (~> 1.0)
32-
faraday-excon (~> 1.1)
33-
faraday-httpclient (~> 1.0.1)
34-
faraday-net_http (~> 1.0)
35-
faraday-net_http_persistent (~> 1.1)
36-
faraday-patron (~> 1.0)
37-
faraday-rack (~> 1.0)
38-
multipart-post (>= 1.2, < 3)
28+
faraday (2.7.2)
29+
faraday-net_http (>= 2.0, < 3.1)
3930
ruby2_keywords (>= 0.0.4)
40-
faraday-em_http (1.0.0)
41-
faraday-em_synchrony (1.0.0)
42-
faraday-excon (1.1.0)
43-
faraday-httpclient (1.0.1)
44-
faraday-net_http (1.0.1)
45-
faraday-net_http_persistent (1.2.0)
46-
faraday-patron (1.0.0)
47-
faraday-rack (1.0.0)
48-
ffi (1.15.4)
31+
faraday-net_http (3.0.2)
32+
ffi (1.15.5)
4933
forwardable-extended (2.6.0)
5034
gemoji (3.0.1)
51-
github-pages (221)
35+
github-pages (227)
5236
github-pages-health-check (= 1.17.9)
53-
jekyll (= 3.9.0)
37+
jekyll (= 3.9.2)
5438
jekyll-avatar (= 0.7.0)
5539
jekyll-coffeescript (= 1.1.1)
56-
jekyll-commonmark-ghpages (= 0.1.6)
40+
jekyll-commonmark-ghpages (= 0.2.0)
5741
jekyll-default-layout (= 0.1.4)
5842
jekyll-feed (= 0.15.1)
5943
jekyll-gist (= 1.5.0)
6044
jekyll-github-metadata (= 2.13.0)
45+
jekyll-include-cache (= 0.2.1)
6146
jekyll-mentions (= 1.6.0)
6247
jekyll-optional-front-matter (= 0.3.2)
6348
jekyll-paginate (= 1.1.0)
@@ -66,7 +51,7 @@ GEM
6651
jekyll-relative-links (= 0.6.1)
6752
jekyll-remote-theme (= 0.4.3)
6853
jekyll-sass-converter (= 1.5.2)
69-
jekyll-seo-tag (= 2.7.1)
54+
jekyll-seo-tag (= 2.8.0)
7055
jekyll-sitemap (= 1.4.0)
7156
jekyll-swiss (= 1.0.0)
7257
jekyll-theme-architect (= 0.2.0)
@@ -84,12 +69,12 @@ GEM
8469
jekyll-theme-time-machine (= 0.2.0)
8570
jekyll-titles-from-headings (= 0.5.3)
8671
jemoji (= 0.12.0)
87-
kramdown (= 2.3.1)
72+
kramdown (= 2.3.2)
8873
kramdown-parser-gfm (= 1.1.0)
8974
liquid (= 4.0.3)
9075
mercenary (~> 0.3)
9176
minima (= 2.5.1)
92-
nokogiri (>= 1.12.5, < 2.0)
77+
nokogiri (>= 1.13.6, < 2.0)
9378
rouge (= 3.26.0)
9479
terminal-table (~> 1.4)
9580
github-pages-health-check (1.17.9)
@@ -98,13 +83,13 @@ GEM
9883
octokit (~> 4.0)
9984
public_suffix (>= 3.0, < 5.0)
10085
typhoeus (~> 1.3)
101-
html-pipeline (2.14.0)
86+
html-pipeline (2.14.3)
10287
activesupport (>= 2)
10388
nokogiri (>= 1.4)
10489
http_parser.rb (0.8.0)
10590
i18n (0.9.5)
10691
concurrent-ruby (~> 1.0)
107-
jekyll (3.9.0)
92+
jekyll (3.9.2)
10893
addressable (~> 2.4)
10994
colorator (~> 1.0)
11095
em-websocket (~> 0.5)
@@ -122,12 +107,12 @@ GEM
122107
jekyll-coffeescript (1.1.1)
123108
coffee-script (~> 2.2)
124109
coffee-script-source (~> 1.11.1)
125-
jekyll-commonmark (1.3.1)
126-
commonmarker (~> 0.14)
127-
jekyll (>= 3.7, < 5.0)
128-
jekyll-commonmark-ghpages (0.1.6)
129-
commonmarker (~> 0.17.6)
130-
jekyll-commonmark (~> 1.2)
110+
jekyll-commonmark (1.4.0)
111+
commonmarker (~> 0.22)
112+
jekyll-commonmark-ghpages (0.2.0)
113+
commonmarker (~> 0.23.4)
114+
jekyll (~> 3.9.0)
115+
jekyll-commonmark (~> 1.4.0)
131116
rouge (>= 2.0, < 4.0)
132117
jekyll-default-layout (0.1.4)
133118
jekyll (~> 3.0)
@@ -138,6 +123,8 @@ GEM
138123
jekyll-github-metadata (2.13.0)
139124
jekyll (>= 3.4, < 5.0)
140125
octokit (~> 4.0, != 4.4.0)
126+
jekyll-include-cache (0.2.1)
127+
jekyll (>= 3.7, < 5.0)
141128
jekyll-mentions (1.6.0)
142129
html-pipeline (~> 2.3)
143130
jekyll (>= 3.7, < 5.0)
@@ -157,7 +144,7 @@ GEM
157144
rubyzip (>= 1.3.0, < 3.0)
158145
jekyll-sass-converter (1.5.2)
159146
sass (~> 3.4)
160-
jekyll-seo-tag (2.7.1)
147+
jekyll-seo-tag (2.8.0)
161148
jekyll (>= 3.8, < 5.0)
162149
jekyll-sitemap (1.4.0)
163150
jekyll (>= 3.7, < 5.0)
@@ -210,41 +197,38 @@ GEM
210197
gemoji (~> 3.0)
211198
html-pipeline (~> 2.2)
212199
jekyll (>= 3.0, < 5.0)
213-
kramdown (2.3.1)
200+
kramdown (2.3.2)
214201
rexml
215202
kramdown-parser-gfm (1.1.0)
216203
kramdown (~> 2.0)
217204
liquid (4.0.3)
218-
listen (3.7.0)
205+
listen (3.7.1)
219206
rb-fsevent (~> 0.10, >= 0.10.3)
220207
rb-inotify (~> 0.9, >= 0.9.10)
221208
mercenary (0.3.6)
222-
mini_portile2 (2.6.1)
209+
mini_portile2 (2.8.0)
223210
minima (2.5.1)
224211
jekyll (>= 3.5, < 5.0)
225212
jekyll-feed (~> 0.9)
226213
jekyll-seo-tag (~> 2.1)
227-
minitest (5.14.4)
228-
multipart-post (2.1.1)
229-
nokogiri (1.12.5)
230-
mini_portile2 (~> 2.6.1)
214+
minitest (5.16.3)
215+
nokogiri (1.13.10)
216+
mini_portile2 (~> 2.8.0)
231217
racc (~> 1.4)
232-
nokogiri (1.12.5-x86_64-linux)
218+
nokogiri (1.13.10-x86_64-linux)
233219
racc (~> 1.4)
234-
octokit (4.21.0)
235-
faraday (>= 0.9)
236-
sawyer (~> 0.8.0, >= 0.5.3)
220+
octokit (4.25.1)
221+
faraday (>= 1, < 3)
222+
sawyer (~> 0.9)
237223
pathutil (0.16.2)
238224
forwardable-extended (~> 2.6)
239-
public_suffix (4.0.6)
240-
racc (1.6.0)
241-
rb-fsevent (0.11.0)
225+
public_suffix (4.0.7)
226+
racc (1.6.2)
227+
rb-fsevent (0.11.2)
242228
rb-inotify (0.10.1)
243229
ffi (~> 1.0)
244230
rexml (3.2.5)
245231
rouge (3.26.0)
246-
ruby-enum (0.9.0)
247-
i18n
248232
ruby2_keywords (0.0.5)
249233
rubyzip (2.3.2)
250234
safe_yaml (1.0.5)
@@ -253,30 +237,32 @@ GEM
253237
sass-listen (4.0.0)
254238
rb-fsevent (~> 0.9, >= 0.9.4)
255239
rb-inotify (~> 0.9, >= 0.9.7)
256-
sawyer (0.8.2)
240+
sawyer (0.9.2)
257241
addressable (>= 2.3.5)
258-
faraday (> 0.8, < 2.0)
242+
faraday (>= 0.17.3, < 3)
259243
simpleidn (0.2.1)
260244
unf (~> 0.1.4)
261245
terminal-table (1.8.0)
262246
unicode-display_width (~> 1.1, >= 1.1.1)
263247
thread_safe (0.3.6)
264248
typhoeus (1.4.0)
265249
ethon (>= 0.9.0)
266-
tzinfo (1.2.9)
250+
tzinfo (1.2.10)
267251
thread_safe (~> 0.1)
268252
unf (0.1.4)
269253
unf_ext
270-
unf_ext (0.0.8)
254+
unf_ext (0.0.8.2)
271255
unicode-display_width (1.8.0)
272-
zeitwerk (2.5.1)
256+
webrick (1.8.1)
257+
zeitwerk (2.6.6)
273258

274259
PLATFORMS
275260
ruby
276261
x86_64-linux
277262

278263
DEPENDENCIES
279264
github-pages
265+
webrick
280266

281267
BUNDLED WITH
282268
2.2.31

_config.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,5 @@
11
description: >-
22
Random thoughts about my passions.
33
4-
sass:
5-
style: compact
6-
74
theme: null
85
url: "henrylang.net"

_includes/footer.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
<footer>
2-
<p>2021, Henry Langmack</p>
2+
<p>{{ site.time | date: '%Y' }}, Henry Langmack</p>
33
<a href="https://github.com/henry-lang">github</a>
44
</footer>

_includes/nav.html

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
1-
<nav>
1+
<nav class="navbar">
22
<p>henrylang.net</p>
3-
<a href="/">index</a>
4-
<a href="/about">about</a>
3+
<a href="/">home</a>
54
<a href="/posts">posts</a>
65
</nav>

_layouts/default.html

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,14 @@
88
<meta http-equiv="X-UA-Compatible" content="IE=edge">
99
<meta name="viewport" content="width=device-width, initial-scale=1.0">
1010
<link rel="preload" as="font" href="/assets/fonts/iosevka-regular.woff2" type="font/woff2" crossorigin="anonymous">
11-
<link rel="stylesheet" href="/assets/styles/style.css">
11+
<link rel="preload" as="script" href="/assets/scripts/palette.js" >
12+
<link rel="stylesheet" href="/assets/styles/styles.css">
1213
</head>
1314
<body>
15+
{% include nav.html %}
16+
<script src="/assets/scripts/palette.js" defer></script>
17+
1418
<div class="wrapper">
15-
{% include nav.html %}
1619
<div class="content">
1720
{{ content }}
1821
</div>

_layouts/post.html

Lines changed: 0 additions & 9 deletions
This file was deleted.

_posts/2021-11-17-testing.md

Lines changed: 0 additions & 7 deletions
This file was deleted.

about.html

Lines changed: 0 additions & 3 deletions
This file was deleted.

assets/scripts/palette.js

Lines changed: 37 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
function getUserPalette() {
2+
return localStorage.getItem('palette') || 'dark'
3+
}
4+
5+
function setUserPalette(palette) {
6+
localStorage.setItem('palette', palette)
7+
}
8+
9+
function rotateUserPalette() {
10+
let userPalette = getUserPalette();
11+
12+
return userPalette == 'light'
13+
? 'dark'
14+
: 'light'
15+
}
16+
17+
function getAppliedPalette(palette) {
18+
if (palette === 'light') {
19+
return 'light'
20+
}
21+
22+
if (palette === 'dark') {
23+
return 'dark'
24+
}
25+
}
26+
27+
function setAppliedPalette(palette) {
28+
document.documentElement.dataset.palette = palette
29+
}
30+
31+
const userPalette = getUserPalette()
32+
setAppliedPalette(getAppliedPalette(userPalette))
33+
document.querySelector("#toggle-palette").addEventListener("click", () => {
34+
const newPalette = rotateUserPalette(getUserPalette());
35+
setAppliedPalette(newPalette);
36+
setUserPalette(newPalette)
37+
});

0 commit comments

Comments
 (0)