jekyll-recker 1.12.0 → 1.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/_includes/nav.html +5 -3
- data/assets/jekyll-recker.scss +121 -0
- data/lib/jekyll_recker/commands.rb +1 -1
- data/lib/jekyll_recker/mixins.rb +0 -19
- data/lib/jekyll_recker/social.rb +7 -8
- data/lib/jekyll_recker/version.rb +1 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e9a5e5beecbe76dfb1a709044a22e681c1d2c17efbe295a169f83ece21b9f127
|
4
|
+
data.tar.gz: 7f0eb9d447f94fad07235c91675dab1b333a03d8fe47c102fada49547cd455c6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ed6e9a3464edd7a9986abdd755d567b12c11c0eb587b9699168d7dd2492a33b0ec85eddb473520fafb21e4cfab11d4aae8e08bb2b2f36294ebd53215eb49c681
|
7
|
+
data.tar.gz: caa4a564c65dcc69593f3f3ff8976f7de24b4c016fd7f68d14c1161ea9a9d67c247755071e09e3d5454d623f6e74ab53f393f9eaa8c501075bf8b77dff55c809
|
data/_includes/nav.html
CHANGED
@@ -1,5 +1,7 @@
|
|
1
1
|
<nav>
|
2
|
-
<a href="{{ site.baseurl }}/" class="{% if page.active == 'index' %}active{% endif %}">
|
3
|
-
|
4
|
-
|
2
|
+
<a href="{{ site.baseurl }}/" class="{% if page.active == 'index' %}active{% endif %} lowercase">
|
3
|
+
🏠 Home
|
4
|
+
</a>
|
5
|
+
<a class="lowercase" href="{{ site.baseurl }}/feed.xml">🛰️ RSS</a>
|
6
|
+
<a class="lowercase" href="https://cookbook.reckerfamily.com">👨🍳 Cookbook</a>
|
5
7
|
</nav>
|
@@ -0,0 +1,121 @@
|
|
1
|
+
---
|
2
|
+
---
|
3
|
+
@import "https://fonts.googleapis.com/css?family=Inconsolata|Open+Sans&display=swap";
|
4
|
+
|
5
|
+
// color
|
6
|
+
$color-accent: #008083;
|
7
|
+
$color-black: #444;
|
8
|
+
$color-passive: #6f7370;
|
9
|
+
|
10
|
+
// font
|
11
|
+
$font-regular: Open Sans, sans-serif;
|
12
|
+
$font-regular-color: $color-black;
|
13
|
+
$font-regular-size: 20px;
|
14
|
+
$font-caption-size: 18px;
|
15
|
+
$font-code: monospace;
|
16
|
+
$font-code-size: 18px;
|
17
|
+
|
18
|
+
.float {
|
19
|
+
&-right {
|
20
|
+
float: right;
|
21
|
+
}
|
22
|
+
|
23
|
+
&-left {
|
24
|
+
float: left;
|
25
|
+
}
|
26
|
+
}
|
27
|
+
|
28
|
+
.lowercase {
|
29
|
+
text-transform: lowercase;
|
30
|
+
}
|
31
|
+
|
32
|
+
@media (max-width: 600px) {
|
33
|
+
.hide-on-mobile {
|
34
|
+
display: none;
|
35
|
+
}
|
36
|
+
}
|
37
|
+
|
38
|
+
.clearfix::after {
|
39
|
+
content: "";
|
40
|
+
clear: both;
|
41
|
+
display: block;
|
42
|
+
}
|
43
|
+
|
44
|
+
body {
|
45
|
+
|
46
|
+
-webkit-font-smoothing: antialiased;
|
47
|
+
-moz-osx-font-smoothing: grayscale;
|
48
|
+
|
49
|
+
color: $font-regular-color;
|
50
|
+
font-family: $font-regular;
|
51
|
+
font-size: $font-regular-size;
|
52
|
+
margin: 40px auto;
|
53
|
+
max-width: 800px;
|
54
|
+
line-height: 1.6;
|
55
|
+
padding: 0 10px;
|
56
|
+
|
57
|
+
header {
|
58
|
+
h1 {
|
59
|
+
margin-bottom: 9px;
|
60
|
+
}
|
61
|
+
}
|
62
|
+
|
63
|
+
nav {
|
64
|
+
a {
|
65
|
+
margin-right: 10px
|
66
|
+
}
|
67
|
+
|
68
|
+
span {
|
69
|
+
color: $color-passive;
|
70
|
+
}
|
71
|
+
}
|
72
|
+
|
73
|
+
a {
|
74
|
+
color: $color-accent;
|
75
|
+
text-decoration: none;
|
76
|
+
|
77
|
+
&.active {
|
78
|
+
color: $color-black;
|
79
|
+
}
|
80
|
+
}
|
81
|
+
|
82
|
+
h1, h2, h3 {
|
83
|
+
line-height: 1.2
|
84
|
+
}
|
85
|
+
|
86
|
+
p {
|
87
|
+
margin-top: 9px;
|
88
|
+
}
|
89
|
+
|
90
|
+
ul {
|
91
|
+
list-style-type: none;
|
92
|
+
margin: 0;
|
93
|
+
padding: 0;
|
94
|
+
}
|
95
|
+
|
96
|
+
figure {
|
97
|
+
img {
|
98
|
+
display: block;
|
99
|
+
margin-left: auto;
|
100
|
+
margin-right: auto;
|
101
|
+
vertical-align: top;
|
102
|
+
height: auto;
|
103
|
+
max-width: 100%;
|
104
|
+
}
|
105
|
+
}
|
106
|
+
|
107
|
+
figcaption {
|
108
|
+
color: $color-passive;
|
109
|
+
font-size: $font-caption-size;
|
110
|
+
text-align: center;
|
111
|
+
}
|
112
|
+
|
113
|
+
blockquote {
|
114
|
+
color: $color-passive;
|
115
|
+
}
|
116
|
+
|
117
|
+
code, pre, pre span {
|
118
|
+
font-family: $font-code;
|
119
|
+
font-size: $font-code-size;
|
120
|
+
}
|
121
|
+
}
|
data/lib/jekyll_recker/mixins.rb
CHANGED
@@ -4,25 +4,6 @@ require 'logger'
|
|
4
4
|
|
5
5
|
module JekyllRecker
|
6
6
|
module Mixins
|
7
|
-
# Introspection
|
8
|
-
#
|
9
|
-
# Adds functions which let the class see things about itself.
|
10
|
-
module Introspection
|
11
|
-
def self.included(base)
|
12
|
-
base.extend(self)
|
13
|
-
end
|
14
|
-
|
15
|
-
# Get the class instance
|
16
|
-
def class_name
|
17
|
-
self.class.name.split('::').last
|
18
|
-
end
|
19
|
-
|
20
|
-
# Get a list of all classes which inherit from this class
|
21
|
-
def descendants
|
22
|
-
ObjectSpace.each_object(Class).select { |klass| klass < self }
|
23
|
-
end
|
24
|
-
end
|
25
|
-
|
26
7
|
# Logging
|
27
8
|
module Logging
|
28
9
|
def self.included(base)
|
data/lib/jekyll_recker/social.rb
CHANGED
@@ -16,7 +16,6 @@ module JekyllRecker
|
|
16
16
|
# Backend base class for social sharing backends.
|
17
17
|
# @abstract
|
18
18
|
class Share
|
19
|
-
include Mixins::Introspection
|
20
19
|
include Mixins::Logging
|
21
20
|
|
22
21
|
def self.share(site, dry: false)
|
@@ -42,9 +41,9 @@ module JekyllRecker
|
|
42
41
|
end
|
43
42
|
|
44
43
|
def config_key
|
45
|
-
|
44
|
+
self.class.const_get(:KEY)
|
46
45
|
end
|
47
|
-
alias name config_key
|
46
|
+
alias name :config_key
|
48
47
|
|
49
48
|
def post_body
|
50
49
|
url = File.join @site.config['url'], latest.url
|
@@ -76,6 +75,8 @@ module JekyllRecker
|
|
76
75
|
#
|
77
76
|
# Slack social sharing backend
|
78
77
|
class Slack < Share
|
78
|
+
KEY = 'slack'
|
79
|
+
|
79
80
|
def configure!
|
80
81
|
@creds = {}
|
81
82
|
workspaces.each do |key, data|
|
@@ -123,6 +124,8 @@ module JekyllRecker
|
|
123
124
|
#
|
124
125
|
# Twitter social sharing backend
|
125
126
|
class Twitter < Share
|
127
|
+
KEY = 'twitter'
|
128
|
+
|
126
129
|
def configure!
|
127
130
|
creds = extract_from_env || extract_from_config
|
128
131
|
raise 'cannot find twitter credentials!' if creds.nil?
|
@@ -156,7 +159,7 @@ module JekyllRecker
|
|
156
159
|
|
157
160
|
def extract_from_config
|
158
161
|
values = cred_fieldnames.map do |k|
|
159
|
-
Shell.run(
|
162
|
+
Shell.run(config["#{k}_cmd"]).strip
|
160
163
|
end
|
161
164
|
|
162
165
|
return nil if values.any? { |v| v.nil? || v.empty? }
|
@@ -164,10 +167,6 @@ module JekyllRecker
|
|
164
167
|
Hash[cred_fieldnames.zip(values)]
|
165
168
|
end
|
166
169
|
|
167
|
-
def twitter_config
|
168
|
-
@site.config.fetch('recker', {}).fetch('twitter', {})
|
169
|
-
end
|
170
|
-
|
171
170
|
def cred_fieldnames
|
172
171
|
%w[
|
173
172
|
access_token_secret
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jekyll-recker
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.14.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Alex Recker
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-07-
|
11
|
+
date: 2020-07-16 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bump
|
@@ -182,6 +182,7 @@ files:
|
|
182
182
|
- _layouts/home.html
|
183
183
|
- _layouts/page.html
|
184
184
|
- _layouts/post.html
|
185
|
+
- assets/jekyll-recker.scss
|
185
186
|
- lib/jekyll-recker.rb
|
186
187
|
- lib/jekyll_recker/commands.rb
|
187
188
|
- lib/jekyll_recker/filters.rb
|