jekyll-theme-nix 1.0.1 → 1.0.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (6) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +7 -1
  3. data/_layouts/default.html +1 -0
  4. data/feed.xml +112 -0
  5. data/sitemap.xml +44 -0
  6. metadata +15 -7
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8c27dad97e088566fc5f038b0b5a5172c5172e84b43e1be38aec959c879ec7c8
4
- data.tar.gz: 47cc1f7ceb2e55787f171d1d5f9f166b54a15ecb15d83e82a4e7280ac7f20e85
3
+ metadata.gz: 47e0b2c0c75f01180f751e87b5c7968090cd261892bb6d8a06ec91dfa8878076
4
+ data.tar.gz: 481f8abf6c437aebc8c31c0ed7a502ecbf17087248a334dc1b4b69cc7d459077
5
5
  SHA512:
6
- metadata.gz: 94e6dc81303c85175bed2bf8bae2c9fb2c25f3836daffcc346e1710d4220620ba244201dd683cf639faa208e4e7fb8ee6876def880133a7db16cb46d149fb59a
7
- data.tar.gz: 15f2c3fe590eceed52429ad496cdd9605f67212cd05c1bd4e3c6afa8929d91d5970b62f78dab3202b024d58ca28e0c17755fcbfebbca603e0a556b230ea546f0
6
+ metadata.gz: c324edc95b338b40a54d165031cb4c4d6d0ac0cde74b698a7847911f74f55b28d60f56c24acff796ca2b201b4fca8c24d7bb55ae21bdff4d757f5d4f271caefd
7
+ data.tar.gz: 84533d6c42dba6a82a9c205f7f734cdacf28e6088133bdc8946a73080f26eeb8bba1e55bd714ff173e28c03e222d004c65e9f6c70feab940df4dfbe7169c7f41
data/README.md CHANGED
@@ -64,7 +64,7 @@ And add this line to your Jekyll site's `_config.yml`:
64
64
  theme: jekyll-theme-nix
65
65
  ```
66
66
 
67
- Make sure that this is the only `theme:` in `_config.yml`. Afterwards run `bundle update`.
67
+ Make sure that this is the only `theme:` in `_config.yml`. Afterwards run `bundle install`.
68
68
 
69
69
  ### Installation as Remote Theme
70
70
 
@@ -83,3 +83,9 @@ remote_theme: michaelnordmeyer/jekyll-theme-nix
83
83
  Make sure that this is the only `remote_theme:` in `_config.yml`, and that there are no other `theme:`.
84
84
 
85
85
  Finally, add `jekyll-remote-theme` to your plugin section in `_config.yml` as well.
86
+
87
+ ## Feed.xml and Sitemap.xml
88
+
89
+ Both are included in the theme and don't need dependencies to `jekyll-feed` or `jekyll-sitemap`. For a standard Jekyll installation, they work out-of-the-box.
90
+
91
+ If hosted with the Github pages plugin, those plugins are already included and will automatically be used instead. To overwrite this, both files have to be copied manually from the theme's repository root to the site's repository root.
@@ -5,6 +5,7 @@
5
5
  <meta name="viewport" content="width=device-width, initial-scale=1">
6
6
  <link rel="icon" type="image/webp" href="{{ '/icon.webp' | relative_url }}">
7
7
  <style>
8
+ :root { color-scheme: light dark; }
8
9
  html {
9
10
  max-width: 43rem;
10
11
  margin: 0 auto;
data/feed.xml ADDED
@@ -0,0 +1,112 @@
1
+ ---
2
+ permalink: /feed.xml
3
+ redirect_from: /feed
4
+ sitemap: false
5
+ layout: none
6
+ ---
7
+ <?xml version="1.0" encoding="utf-8"?>
8
+ {% if page.xsl %}
9
+ <?xml-stylesheet type="text/xml" href="{{ '/feed.xslt.xml' | absolute_url }}"?>
10
+ {% endif %}
11
+ <feed xmlns="http://www.w3.org/2005/Atom" {% if site.lang %}xml:lang="{{ site.lang }}"{% endif %}>
12
+ <link href="{{ page.url | absolute_url }}" rel="self" type="application/atom+xml" />
13
+ <link href="{{ '/' | absolute_url }}" rel="alternate" type="text/html" {% if site.lang %}hreflang="{{ site.lang }}" {% endif %}/>
14
+ <updated>{{ site.time | date_to_xmlschema }}</updated>
15
+ <id>{{ page.url | absolute_url | xml_escape }}</id>
16
+ {%- assign title = site.title | default: site.name -%}
17
+ {%- if page.collection and page.collection != "posts" -%}
18
+ {%- assign collection = page.collection | capitalize -%}
19
+ {%- assign title = title | append: site.title_separator | append: collection -%}
20
+ {%- endif -%}
21
+ {%- if page.category -%}
22
+ {%- assign category = page.category | capitalize -%}
23
+ {%- assign title = title | append: site.title_separator | append: category -%}
24
+ {%- endif -%}
25
+ {%- if title %}
26
+ <title type="html">{{ title | smartify | xml_escape }}</title>
27
+ {%- endif -%}
28
+ {%- if site.description %}
29
+ <subtitle>{{ site.description | smartify }}</subtitle>
30
+ {%- endif -%}
31
+ {%- if site.author %}
32
+ <author>
33
+ <name>{{ site.author.name | default: site.author | xml_escape }}</name>
34
+ {%- if site.author.email %}
35
+ <email>{{ site.author.email | xml_escape }}</email>
36
+ {%- endif -%}
37
+ {%- if site.author.uri %}
38
+ <uri>{{ site.author.uri | xml_escape }}</uri>
39
+ {%- endif %}
40
+ </author>
41
+ {%- endif -%}
42
+ {%- comment -%}
43
+ {%- if page.tags -%}
44
+ {%- assign posts = site.tags[page.tags] -%}
45
+ {%- else -%}
46
+ {%- assign posts = site[page.collection] -%}
47
+ {%- endif -%}
48
+ {%- if page.category -%}
49
+ {%- assign posts = posts | where: "categories", page.category -%}
50
+ {%- endif -%}
51
+ {%- endcomment -%}
52
+ {%- unless posts -%}
53
+ {%- assign posts = site.posts -%}
54
+ {%- endunless -%}
55
+ {%- unless site.show_drafts -%}
56
+ {%- assign posts = posts | where_exp: "post", "post.draft != true" -%}
57
+ {%- endunless -%}
58
+ {%- assign posts = posts | sort: "date" | reverse -%}
59
+ {%- assign posts_limit = site.feed.posts_limit | default: 10 -%}
60
+ {%- for post in posts limit: posts_limit %}
61
+ <entry{% if post.lang %}{{" "}}xml:lang="{{ post.lang }}"{% endif %}>
62
+ {%- assign post_title = post.title | smartify | strip_html | normalize_whitespace %}
63
+ <title type="html">{{ post_title }}</title>
64
+ <link href="{{ post.url | absolute_url }}" rel="alternate" type="text/html" title="{{ post_title }}" />
65
+ <published>{{ post.date | date_to_xmlschema }}</published>
66
+ <updated>{{ post.last_modified_at | default: post.date | date_to_xmlschema }}</updated>
67
+ <id>{{ post.id | absolute_url | xml_escape }}</id>
68
+
69
+ {%- assign post_author = post.author | default: post.authors[0] | default: site.author -%}
70
+ {%- assign post_author = site.data.authors[post_author] | default: post_author -%}
71
+ {%- assign post_author_email = post_author.email | default: nil -%}
72
+ {%- assign post_author_uri = post_author.uri | default: nil -%}
73
+ {%- assign post_author_name = post_author.name | default: post_author %}
74
+ <author>
75
+ <name>{{ post_author_name | default: "" | xml_escape }}</name>
76
+ {%- if post_author_email %}
77
+ <email>{{ post_author_email | xml_escape }}</email>
78
+ {%- endif -%}
79
+ {%- if post_author_uri %}
80
+ <uri>{{ post_author_uri | xml_escape }}</uri>
81
+ {%- endif %}
82
+ </author>
83
+ {%- if post.category %}
84
+ <category term="{{ post.category | xml_escape }}" />
85
+ {%- elsif post.categories -%}
86
+ {%- for category in post.categories %}
87
+ <category term="{{ category | xml_escape }}" />
88
+ {%- endfor -%}
89
+ {%- endif %}
90
+ {%- for tag in post.tags %}
91
+ <category term="{{ tag | xml_escape }}" />
92
+ {%- endfor -%}
93
+ {%- assign post_summary = post.description | default: post.excerpt -%}
94
+ {%- if post_summary and post_summary != empty %}
95
+ <summary type="html"><![CDATA[{{ post_summary | strip_html | normalize_whitespace | smartify }}]]></summary>
96
+ {%- endif -%}
97
+
98
+ {%- assign post_image = post.image.path | default: post.image -%}
99
+ {%- if post_image -%}
100
+ {%- unless post_image contains "://" -%}
101
+ {%- assign post_image = post_image | absolute_url | xml_escape -%}
102
+ {%- endunless %}
103
+ <media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="{{ post_image | xml_escape }}" />
104
+ <media:content xmlns:media="http://search.yahoo.com/mrss/" url="{{ post_image | xml_escape }}" medium="image" />
105
+ {%- endif -%}
106
+ {%- assign excerpt_only = post.feed.excerpt_only | default: site.feed.excerpt_only -%}
107
+ {%- unless excerpt_only %}
108
+ <content type="html" xml:base="{{ post.url | absolute_url | xml_escape }}"><![CDATA[{{ post.content | strip | smartify }}]]></content>
109
+ {%- endunless %}
110
+ </entry>
111
+ {%- endfor %}
112
+ </feed>
data/sitemap.xml ADDED
@@ -0,0 +1,44 @@
1
+ ---
2
+ permalink: /sitemap.xml
3
+ sitemap: false
4
+ layout: none
5
+ ---
6
+ <?xml version="1.0" encoding="UTF-8"?>
7
+ {%- if page.xsl %}
8
+ <?xml-stylesheet type="text/xsl" href="{{ "/sitemap.xsl" | absolute_url }}"?>
9
+ {%- endif %}
10
+ <urlset
11
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
12
+ xsi:schemaLocation="http://www.sitemaps.org/schemas/sitemap/0.9 http://www.sitemaps.org/schemas/sitemap/0.9/sitemap.xsd"
13
+ xmlns="http://www.sitemaps.org/schemas/sitemap/0.9">
14
+ {%- assign collections = site.collections | where_exp:'collection','collection.output != false' -%}
15
+ {%- for collection in collections -%}
16
+ {%- assign docs = collection.docs | where_exp:'doc','doc.sitemap != false' -%}
17
+ {%- for doc in docs %}
18
+ <url>
19
+ <loc>{{ doc.url | replace:'/index.html','/' | absolute_url | xml_escape }}</loc>
20
+ {%- if doc.last_modified_at or doc.date %}
21
+ <lastmod>{{ doc.last_modified_at | default: doc.date | date_to_xmlschema }}</lastmod>
22
+ {%- endif %}
23
+ </url>
24
+ {% endfor -%}
25
+ {%- endfor -%}
26
+
27
+ {%- assign pages = site.html_pages | where_exp:'doc','doc.sitemap != false' | where_exp:'doc','doc.url != "/404.html"' -%}
28
+ {%- for page in pages %}
29
+ <url>
30
+ <loc>{{ page.url | replace:'/index.html','/' | absolute_url | xml_escape }}</loc>
31
+ {%- if page.last_modified_at %}
32
+ <lastmod>{{ page.last_modified_at | date_to_xmlschema }}</lastmod>
33
+ {%- endif %}
34
+ </url>
35
+ {% endfor -%}
36
+
37
+ {%- assign static_files = page.static_files | where_exp:'page','page.sitemap != false' | where_exp:'page','page.name != "404.html"' -%}
38
+ {%- for file in static_files %}
39
+ <url>
40
+ <loc>{{ file.path | absolute_url | xml_escape }}</loc>
41
+ <lastmod>{{ file.modified_time | date_to_xmlschema }}</lastmod>
42
+ </url>
43
+ {% endfor %}
44
+ </urlset>
metadata CHANGED
@@ -1,29 +1,35 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll-theme-nix
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Nordmeyer
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-02-26 00:00:00.000000000 Z
11
+ date: 2023-04-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
17
+ - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: '4.3'
19
+ version: 3.9.3
20
+ - - "<"
21
+ - !ruby/object:Gem::Version
22
+ version: '5.0'
20
23
  type: :runtime
21
24
  prerelease: false
22
25
  version_requirements: !ruby/object:Gem::Requirement
23
26
  requirements:
24
- - - "~>"
27
+ - - ">="
28
+ - !ruby/object:Gem::Version
29
+ version: 3.9.3
30
+ - - "<"
25
31
  - !ruby/object:Gem::Version
26
- version: '4.3'
32
+ version: '5.0'
27
33
  description:
28
34
  email:
29
35
  - michaelnordmeyer@users.noreply.github.com
@@ -39,6 +45,8 @@ files:
39
45
  - _layouts/home.html
40
46
  - _layouts/page.html
41
47
  - _layouts/post.html
48
+ - feed.xml
49
+ - sitemap.xml
42
50
  homepage: https://github.com/michaelnordmeyer/jekyll-theme-nix
43
51
  licenses:
44
52
  - MIT
@@ -58,7 +66,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
58
66
  - !ruby/object:Gem::Version
59
67
  version: '0'
60
68
  requirements: []
61
- rubygems_version: 3.4.7
69
+ rubygems_version: 3.4.12
62
70
  signing_key:
63
71
  specification_version: 4
64
72
  summary: A very minimalistic, single-author Jekyll theme with almost default browser