jekyll_outline 1.2.1 → 1.2.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a0c7d0f4a87a49c9f0c019221e7895750d5041eff4b0923f1fe819c79c78fa04
4
- data.tar.gz: e300cb58e1c5ad4235c8c75792e8e94f2f784cff063dbcf361a0d5f36054b1cb
3
+ metadata.gz: b279fb946cc9cd5d5fc092680a1f28c2af772dc2daa319a4d3c82f4946d5c731
4
+ data.tar.gz: 0e1f714175edd37e7b06f07f499891d365dbb2ed01d2fe90923a54d6cac613b2
5
5
  SHA512:
6
- metadata.gz: bdea785aa21f80694737f6bed9961cfa6f753bc22fdea25f0d0d20e8c73043a84a25a326e905eeaa51a4ad6b041b583394b1040300d838e9dac32c82552251c6
7
- data.tar.gz: b8ddcebea943a9a0106d9a86374a8c07fd23d6b6ed1bdd0e6f0690128fde5f7dc5d478ee7fbe56eb8b9e1e44be4eab1379b32f483c057afc2dc4a60e56fe2f09
6
+ metadata.gz: 4811c7012c0ab9fc504906886a29b4e27d83073f2a079d1cc7e1c9dcdec25acc14da1559e0b940556ba994e2edba45cfb510866c205829d92085a5fd936a02e2
7
+ data.tar.gz: b79734ebe03d8facc9034e6be26bacf038609f74b9cfca6611297f16f90891f8c12dc9a88c3b6e82d00d8656f4ba24dd33ec2d46ccefa5173fa05f750b061948
data/.rubocop.yml CHANGED
@@ -1,16 +1,17 @@
1
1
  require:
2
- - rubocop-md
3
- - rubocop-performance
4
- - rubocop-rake
5
- - rubocop-rspec
2
+ # - rubocop-jekyll
3
+ - rubocop-md
4
+ - rubocop-performance
5
+ - rubocop-rake
6
+ - rubocop-rspec
6
7
 
7
8
  AllCops:
8
9
  Exclude:
9
- - exe/**/*
10
+ - binstub/**/*
11
+ - demo/_site/*
10
12
  - vendor/**/*
11
13
  - Gemfile*
12
14
  NewCops: enable
13
- TargetRubyVersion: 2.6
14
15
 
15
16
  Gemspec/DeprecatedAttributeAssignment:
16
17
  Enabled: false
@@ -18,6 +19,9 @@ Gemspec/DeprecatedAttributeAssignment:
18
19
  Gemspec/RequireMFA:
19
20
  Enabled: false
20
21
 
22
+ Gemspec/RequiredRubyVersion:
23
+ Enabled: false
24
+
21
25
  Layout/HashAlignment:
22
26
  EnforcedColonStyle: table
23
27
  EnforcedHashRocketStyle: table
@@ -26,25 +30,45 @@ Layout/LineLength:
26
30
  Max: 150
27
31
 
28
32
  Metrics/AbcSize:
29
- Max: 30
33
+ Max: 55
30
34
 
31
35
  Metrics/BlockLength:
32
36
  Exclude:
33
- - jekyll_outline.gemspec
34
- Max: 40
37
+ - jekyll_plugin_support.gemspec
38
+ Max: 30
35
39
 
36
40
  Metrics/CyclomaticComplexity:
37
- Max: 20
41
+ Max: 25
38
42
 
39
43
  Metrics/MethodLength:
40
- Max: 30
44
+ Max: 50
41
45
 
42
46
  Metrics/PerceivedComplexity:
43
- Max: 20
47
+ Max: 25
44
48
 
45
49
  Naming/FileName:
46
50
  Exclude:
47
51
  - Rakefile
52
+ - "*.md"
53
+
54
+ RSpec/ExampleLength:
55
+ Max: 30
56
+
57
+ RSpec/SpecFilePathFormat:
58
+ Enabled: false
59
+ IgnoreMethods: true
60
+
61
+ RSpec/SpecFilePathSuffix:
62
+ Enabled: false
63
+
64
+ RSpec/IndexedLet:
65
+ Enabled: false
66
+
67
+ RSpec/MultipleExpectations:
68
+ Max: 15
69
+
70
+ Style/ClassVars:
71
+ Enabled: false
48
72
 
49
73
  Style/Documentation:
50
74
  Enabled: false
@@ -52,9 +76,8 @@ Style/Documentation:
52
76
  Style/FrozenStringLiteralComment:
53
77
  Enabled: false
54
78
 
79
+ Style/StringConcatenation:
80
+ Enabled: false
81
+
55
82
  Style/TrailingCommaInHashLiteral:
56
83
  EnforcedStyleForMultiline: comma
57
-
58
- RSpec/FilePath:
59
- IgnoreMethods: true
60
- SpecSuffixOnly: true
data/CHANGELOG.md CHANGED
@@ -1,24 +1,49 @@
1
+ # Change Log
2
+
3
+ ## 1.2.3 / 2024-07-23
4
+
5
+ * Made compatible with jekyll_plugin_support v1.0.0
6
+
7
+
8
+ ## 1.2.2 / 2024-01-08
9
+
10
+ * Added `sort_by_title` keyword option.
11
+
12
+
1
13
  ## 1.2.1 / 2023-06-17
2
- - Updated dependencies.
3
- - No longer explodes when a value for `order` is not provided in front matter.
14
+
15
+ * Updated dependencies.
16
+ * No longer explodes when a value for `order` is not provided in front matter.
17
+
4
18
 
5
19
  ## 1.2.0 / 2023-04-23
6
- - Added optional `field` parameter.
20
+
21
+ * Added optional `field` parameter.
22
+
7
23
 
8
24
  ## 1.1.1 / 2023-04-02
9
- * Added [`attribution` support](https://github.com/mslinn/jekyll_plugin_support#subclass-attribution).
25
+
26
+ * Added [`attribution` support](https://github.com/mslinn/jekyll_plugin_support#subclass-attribution).
27
+
10
28
 
11
29
  ## 1.1.0 / 2023-03-14
12
- * `outline_js` tag added, for including Javascript necessary to position images relating to the outline.
13
- * Now generates a series of divs, instead of one big div.
14
- * Now interprets numbers as decimal instead of octal.
15
- * CSS documented and new `post_title` class defined.
30
+
31
+ * `outline_js` tag added, for including Javascript necessary to position images relating to the outline.
32
+ * Now generates a series of divs, instead of one big div.
33
+ * Now interprets numbers as decimal instead of octal.
34
+ * CSS documented and new `post_title` class defined.
35
+
16
36
 
17
37
  ## 1.0.2 / 2023-02-16
18
- * Updated to `jekyll_plugin_support` v0.5.1
38
+
39
+ * Updated to `jekyll_plugin_support` v0.5.1
40
+
19
41
 
20
42
  ## 1.0.1 / 2023-02-14
21
- * Now dependent upon `jekyll_plugin_support`
43
+
44
+ * Now dependent upon `jekyll_plugin_support`
45
+
22
46
 
23
47
  ## 1.0.0 / 2022-04-02
24
- * Initial version, this Jekyll plugin defines a block tag called `outline`.
48
+
49
+ * Initial version, this Jekyll plugin defines a block tag called `outline`.
data/README.md CHANGED
@@ -1,11 +1,35 @@
1
- `jekyll_outline`
2
- [![Gem Version](https://badge.fury.io/rb/jekyll_outline.svg)](https://badge.fury.io/rb/jekyll_outline)
3
- ===========
1
+ # `jekyll_outline` [![Gem Version](https://badge.fury.io/rb/jekyll_outline.svg)](https://badge.fury.io/rb/jekyll_outline)
4
2
 
5
3
  `jekyll_outline` Jekyll tag plugin that creates a clickable table of contents.
6
4
 
7
5
 
6
+ ## Usage
7
+
8
+ These examples are taken from [`demo/index.html`](demo/index.html).
9
+
10
+ Sort by `order` field:
11
+
12
+ ```html
13
+ {% outline attribution fields="<b> title </b> &ndash; <i> description </i>" stuff %}
14
+ 000: A Topic 0..19
15
+ 020: A Topic 20..39
16
+ 040: A Topic 40..
17
+ {% endoutline %}
18
+ ```
19
+
20
+ Sort by `title` field:
21
+
22
+ ```html
23
+ {% outline attribution sort_by_title fields="<b> title </b> &ndash; <i> description </i>" stuff %}
24
+ 000: B Topic 0..19
25
+ 020: B Topic 20..39
26
+ 040: B Topic 40..
27
+ {% endoutline %}
28
+ ```
29
+
30
+
8
31
  ## Installation
32
+
9
33
  Add the following line to your Jekyll project's Gemfile, within the `jekyll_plugins` group:
10
34
 
11
35
  ```ruby
@@ -16,20 +40,24 @@ end
16
40
 
17
41
  And then execute:
18
42
 
19
- $ bundle
43
+ ```shell
44
+ $ bundle
45
+ ```
20
46
 
21
47
 
22
48
  ## Fields
49
+
23
50
  By default, each displayed entry consists of a document title,
24
51
  wrapped within an &lt;a href&gt; HTML tag that links to the page for that entry,
25
52
  followed by an indication of whether the document is visible (a draft) or not.
26
53
 
27
54
  Entry can also include following fields:
28
- `draft`, `categories`, `description`, `date`, `last_modified` or `last_modified_at`, `layout`, `order`, `title`, `slug`, `ext`, `tags`, and `excerpt`.
55
+ `draft`, `categories`, `description`, `date`, `last_modified` or `last_modified_at`, `layout`, `order`, `title`, `slug`,
56
+ `ext`, `tags`, and `excerpt`.
29
57
 
30
58
  Specify the fields like this:
31
59
 
32
- ```
60
+ ```html
33
61
  {% outline fields="title &ndash; <i> description </i>" %}
34
62
  000: Topic 0..19
35
63
  020: Topic 20..39
@@ -45,8 +73,10 @@ Tokens are separated by white space.
45
73
 
46
74
 
47
75
  ### CSS
76
+
48
77
  The CSS used for the demo website should be copied to your project.
49
- See the sections of [`demo/assets/css/styles.css`](/mslinn/jekyll_outline/blob/master/demo/assets/css/style.css#L252-L315) as shown:
78
+ See the sections of
79
+ [`demo/assets/css/styles.css`](/mslinn/jekyll_outline/blob/master/demo/assets/css/style.css#L252-L315) as shown:
50
80
 
51
81
  ```css
52
82
  /* Start of jekyll_plugin_support css */
@@ -59,6 +89,7 @@ See the sections of [`demo/assets/css/styles.css`](/mslinn/jekyll_outline/blob/m
59
89
  ```
60
90
 
61
91
  ### JavaScript
92
+
62
93
  This project's `outline_js` tag returns the Javascript necessary to position images relating to the outline.
63
94
  If used without parameters it just returns the JavaScript.
64
95
  Use the tag this way:
@@ -78,7 +109,9 @@ Use the tag this way:
78
109
 
79
110
 
80
111
  ## Explanation
112
+
81
113
  Given an outline that looks like this:
114
+
82
115
  ```html
83
116
  {% outline stuff %}
84
117
  000: Topic 0..19
@@ -89,11 +122,12 @@ Given an outline that looks like this:
89
122
 
90
123
  ...and given pages in the `stuff` collection with the following names:
91
124
 
92
- - `010-published.html` has title **Published Stuff Post 010**
93
- - `020-unpublished.html` has title **Unpublished Post 020**
94
- - `030-unpublished.html` has title **Unpublished Post 030**
125
+ - `010-published.html` has title **Published Stuff Post 010**
126
+ - `020-unpublished.html` has title **Unpublished Post 020**
127
+ - `030-unpublished.html` has title **Unpublished Post 030**
95
128
 
96
129
  Then links to the pages in the `stuff` collection's pages are interleaved into the generated outline like this:
130
+
97
131
  ```html
98
132
  <div class="outer_posts">
99
133
  <h3 class='post_title clear' id="title_0">Topic 0..19</h3>
@@ -121,6 +155,7 @@ Note that leading zeros in the first column above are not present in the `id`s b
121
155
 
122
156
  If you want to provide images to embed at appropriate locations within the outline,
123
157
  wrap them within an invisible `div` so the web page does not jump around as the images are loaded.
158
+
124
159
  ```html
125
160
  <div style="display: none;">
126
161
  {% img align="right"
@@ -146,30 +181,34 @@ wrap them within an invisible `div` so the web page does not jump around as the
146
181
  %}
147
182
  </div>
148
183
  ```
184
+
149
185
  The JavaScript identifies the images and repositions them in the DOM such that they follow the appropriate heading.
150
186
  If no image corresponds to a heading, no error or warning is generated.
151
187
  The images can be located anywhere on the page; they will be relocated appropriately.
152
188
  If an image does not correspond to a heading, it is deleted.
153
189
 
154
190
 
155
-
156
-
157
191
  ## Attribution
192
+
158
193
  See [`jekyll_plugin_support` for `attribution`](https://github.com/mslinn/jekyll_plugin_support#subclass-attribution)
159
194
 
160
195
 
161
196
  ## Additional Information
197
+
162
198
  More information is available on
163
199
  [Mike Slinn&rsquo;s website](https://www.mslinn.com/jekyll/3000-jekyll-plugins.html#outline).
164
200
 
165
201
 
166
202
  ## Development
203
+
167
204
  After checking out the repo, run `bin/setup` to install development dependencies.
168
205
 
169
206
  Then you can run `bin/console` for an interactive prompt that will allow you to experiment using `irb`.
170
207
 
171
208
  ### Build and Install Locally
209
+
172
210
  To build and install this gem onto your local machine, run:
211
+
173
212
  ```shell
174
213
  $ bundle exec rake install
175
214
  jekyll_outline 0.1.0 built to pkg/jekyll_outline-0.1.0.gem.
@@ -191,45 +230,56 @@ jekyll_outline (0.1.0)
191
230
 
192
231
 
193
232
  ## Demo
233
+
194
234
  A demo / test website is provided in the `demo` directory.
195
235
  It can be used to debug the plugin or to run freely.
196
236
 
237
+
197
238
  ### Run Freely
198
- 1. Run from the command line:
199
- ```shell
200
- $ demo/_bin/debug -r
201
- ```
202
239
 
203
- 2. View the generated website at [`http://localhost:4444`](http://localhost:4444)
240
+ 1. Run from the command line:
241
+
242
+ ```shell
243
+ $ demo/_bin/debug -r
244
+ ```
245
+
246
+ 2. View the generated website at [`http://localhost:4444`](http://localhost:4444)
247
+
204
248
 
205
249
  ### Plugin Debugging
206
- 1. Set breakpoints in Visual Studio Code.
207
250
 
208
- 2. Initiate a debug session from the command line:
209
- ```shell
210
- $ demo/_bin/debug
211
- ```
251
+ 1. Set breakpoints in Visual Studio Code.
212
252
 
213
- 3. Once the `Fast Debugger` signon appears, launch the Visual Studio Code launch
214
- configuration called `Attach rdebug-ide`.
253
+ 2. Initiate a debug session from the command line:
215
254
 
216
- 4. View the generated website at [`http://localhost:4444`](http://localhost:4444)
255
+ ```shell
256
+ $ demo/_bin/debug
257
+ ```
258
+
259
+ 3. Once the `Fast Debugger` signon appears, launch the Visual Studio Code launch
260
+ configuration called `Attach rdebug-ide`.
261
+ 4. View the generated website at [`http://localhost:4444`](http://localhost:4444)
217
262
 
218
263
 
219
264
  ## Release
265
+
220
266
  To release a new version,
221
- 1. Update the version number in `version.rb`.
222
- 2. Describe the changes in `CHANGELOG.md`.
223
- 3. Commit all changes to git; if you don't the next step might fail with an unexplainable error message.
224
- 4. Run the following:
225
- ```shell
226
- $ bundle exec rake release
227
- ```
228
- The above creates a git tag for the version, commits the created tag,
229
- and pushes the new `.gem` file to [RubyGems.org](https://rubygems.org).
267
+
268
+ 1. Update the version number in `version.rb`.
269
+ 2. Describe the changes in `CHANGELOG.md`.
270
+ 3. Commit all changes to git; if you don't the next step might fail with an unexplainable error message.
271
+ 4. Run the following:
272
+
273
+ ```shell
274
+ $ bundle exec rake release
275
+ ```
276
+
277
+ The above creates a git tag for the version, commits the created tag,
278
+ and pushes the new `.gem` file to [RubyGems.org](https://rubygems.org).
230
279
 
231
280
 
232
281
  ## Contributing
282
+
233
283
  Bug reports and pull requests are welcome on GitHub at https://github.com/mslinn/jekyll_outline.
234
284
 
235
285
  1. Fork the project
@@ -239,4 +289,5 @@ Bug reports and pull requests are welcome on GitHub at https://github.com/mslinn
239
289
 
240
290
 
241
291
  ## License
292
+
242
293
  The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
@@ -36,5 +36,5 @@ Gem::Specification.new do |spec|
36
36
 
37
37
  spec.add_dependency 'jekyll', '>= 3.5.0'
38
38
  spec.add_dependency 'jekyll_draft', '>= 1.1.2'
39
- spec.add_dependency 'jekyll_plugin_support', '>= 0.7.0'
39
+ spec.add_dependency 'jekyll_plugin_support', '>= 1.0.0'
40
40
  end
@@ -1,3 +1,3 @@
1
1
  module JekyllOutlineVersion
2
- VERSION = '1.2.1'.freeze
2
+ VERSION = '1.2.3'.freeze
3
3
  end
@@ -1,5 +1,5 @@
1
- require_relative './outline_js'
2
- require_relative './outline_tag'
1
+ require_relative 'outline_js'
2
+ require_relative 'outline_tag'
3
3
 
4
4
  module Outline
5
5
  include OutlineTag
data/lib/outline_js.rb CHANGED
@@ -35,6 +35,6 @@ module OutlineJsTag
35
35
  .join("\n")
36
36
  end
37
37
 
38
- JekyllPluginHelper.register(self, PLUGIN_JS_NAME)
38
+ ::JekyllSupport::JekyllPluginHelper.register(self, PLUGIN_JS_NAME)
39
39
  end
40
40
  end
data/lib/outline_tag.rb CHANGED
@@ -6,10 +6,38 @@ require 'jekyll_plugin_support'
6
6
  require 'yaml'
7
7
  require_relative 'jekyll_outline/version'
8
8
 
9
+ # This class generates output of the form, where NNN is an order value:
10
+ # <div class="outer_posts">
11
+ # <h3 class="post_title clear" id="title_0">Django / Oscar Evaluation</h3>
12
+ # <div id="posts_wrapper_0" class="clearfix">
13
+ # <div id="posts_0" class="posts">
14
+ # <span>2021-02-11</span> <span><a href="/collection/page1.html">Title 1</a></span>
15
+ # <span>2023-12-09</span> <span><a href="/collection/page2.html">Title 2</a></span>
16
+ # </div>
17
+ # <h3 class="post_title clear" id="title_NNN">Notes</h3>
18
+ # <div id="posts_wrapper_NNN" class="clearfix">
19
+ # <div id="posts_400" class="posts">
20
+ # <span>2021-04-14</span> <span><a href="/collection/page3.html">Title 3</a></span>
21
+ # <span>2021-03-29</span> <span><a href="/collection/page4.html">Title 4</a></span>
22
+ # </div>
23
+ # </div>
24
+ # <div id="jps_attribute_570007" class="jps_attribute">
25
+ # <div>
26
+ # <a href="https://www.mslinn.com/jekyll_plugins/jekyll_outline.html" target="_blank" rel="nofollow">
27
+ # Generated by the jekyll_outline v1.2.1 Jekyll plugin, written by Mike Slinn 2024-01-09.
28
+ # </a>
29
+ # </div>
30
+ # </div>
31
+ # </div>
32
+ # </div>
33
+ #
34
+ # Subclasses, such as jekyll_toc.rb, might generate other output.
35
+
9
36
  module OutlineTag
10
37
  PLUGIN_NAME = 'outline'.freeze
11
38
 
12
39
  # Interleaves with docs
40
+ # Duck type compatible with Jekyll doc
13
41
  class Header
14
42
  attr_accessor :order, :title
15
43
 
@@ -33,13 +61,18 @@ module OutlineTag
33
61
  headers = make_headers(super) # Process the block content.
34
62
 
35
63
  @helper.gem_file __FILE__
36
- @fields = @helper.parameter_specified?('fields')&.split(' ') || ['title']
64
+ @fields = @helper.parameter_specified?('fields')&.split || ['title']
65
+ @sort_by = @helper.parameter_specified?('sort_by_title') ? 'title' : 'order'
37
66
  @collection_name = @helper.remaining_markup
38
67
  abort 'OutlineTag: collection_name was not specified' unless @collection_name
39
68
 
40
69
  @docs = obtain_docs(@collection_name)
41
70
  collection = headers + @docs
71
+ render_outline collection
72
+ end
42
73
 
74
+ # Overload this for a subclass
75
+ def render_outline(collection)
43
76
  <<~HEREDOC
44
77
  <div class="outer_posts">
45
78
  #{make_entries collection}
@@ -48,6 +81,8 @@ module OutlineTag
48
81
  HEREDOC
49
82
  end
50
83
 
84
+ def open_head; end
85
+
51
86
  private
52
87
 
53
88
  def header?(variable)
@@ -63,14 +98,18 @@ module OutlineTag
63
98
  # @param collection Array of Jekyll::Document and Outline::Header
64
99
  # @return Array of String
65
100
  def make_entries(collection)
66
- sorted = collection.sort_by(&obtain_order)
101
+ sorted = if @sort_by == 'order'
102
+ collection.sort_by(&obtain_order)
103
+ else
104
+ collection.sort_by(&obtain_field)
105
+ end
67
106
  pruned = remove_empty_headers sorted
68
107
  @section_state = :head
69
108
  @section_id = 0
70
109
  result = pruned.map do |entry|
71
110
  handle entry
72
111
  end
73
- result << " </div>\n </div>" if @section_state == :in_body
112
+ result << " </div>\n </div>" if @section_state == :in_body # Modify this for TOC
74
113
  result&.join("\n")
75
114
  end
76
115
 
@@ -85,14 +124,16 @@ module OutlineTag
85
124
  entry
86
125
  else
87
126
  if @section_state == :head
88
- section_start = "<div id='posts_wrapper_#{@header_order}' class='clearfix'>\n " \
89
- "<div id='posts_#{@header_order}' class='posts'>\n"
127
+ section_start = <<~ENDTEXT # Modify this for TOC
128
+ <div id="posts_wrapper_#{@header_order}" class='clearfix'>
129
+ <div id="posts_#{@header_order}" class='posts'>
130
+ ENDTEXT
90
131
  end
91
132
  @section_state = :in_body
92
133
  date = entry.data['last_modified_at'] # "%Y-%m-%d"
93
134
  draft = Jekyll::Draft.draft_html(entry)
94
135
  visible_line = handle_entry entry
95
- result = " <span>#{date}</span> <span><a href='#{entry.url}'>#{visible_line.strip}</a>#{draft}</span>"
136
+ result = " <span>#{date}</span> <span><a href='#{entry.url}'>#{visible_line.strip}</a>#{draft}</span>" # Modify this for TOC
96
137
  result = section_start + result if section_start
97
138
  result
98
139
  end
@@ -132,12 +173,24 @@ module OutlineTag
132
173
  .reject { |doc| doc.path.end_with? 'index.html' }
133
174
  end
134
175
 
135
- # Sort entries without an order property at the end
176
+ # Sort entries within the outline tag which do not have the property specified by @sort_by at the end
177
+ def obtain_field
178
+ sort_by = @sort_by.to_s
179
+ proc do |entry|
180
+ if entry.respond_to? :data # page
181
+ entry.data.key?(sort_by) ? entry.data[sort_by] || 'zzz' : 'zzz'
182
+ else # heading
183
+ entry.respond_to?(sort_by) ? entry.send(sort_by) || 'zzz' : 'zzz'
184
+ end
185
+ end
186
+ end
187
+
188
+ # Sort entries within the outline tag which do not have an order property at the end
136
189
  def obtain_order
137
190
  proc do |entry|
138
- if entry.respond_to? :data
191
+ if entry.respond_to? :data # page
139
192
  entry.data.key?('order') ? entry.data['order'] || FIXNUM_MAX : FIXNUM_MAX
140
- else
193
+ else # heading
141
194
  entry.order || FIXNUM_MAX
142
195
  end
143
196
  end
@@ -165,6 +218,6 @@ module OutlineTag
165
218
  .join("\n")
166
219
  end
167
220
 
168
- JekyllPluginHelper.register(self, PLUGIN_NAME)
221
+ ::JekyllSupport::JekyllPluginHelper.register(self, PLUGIN_NAME)
169
222
  end
170
223
  end
data/spec/outline_spec.rb CHANGED
@@ -4,10 +4,7 @@ require_relative '../lib/jekyll_outline'
4
4
  RSpec.describe(Outline) do
5
5
  include Jekyll
6
6
 
7
- it 'is created properly' do
8
- pending 'This is just a placeholder'
9
- run_tag = RunTag.new('run', 'echo asdf')
10
- output = run_tag.render(context)
11
- expect(output).to eq('asdf')
7
+ it 'never works first time', skip: 'Just a placeholder' do
8
+ expect(true).to be_truthy
12
9
  end
13
10
  end
data/spec/spec_helper.rb CHANGED
@@ -2,9 +2,8 @@ require 'jekyll'
2
2
  require_relative '../lib/jekyll_outline'
3
3
 
4
4
  RSpec.configure do |config|
5
- config.filter_run :focus
5
+ config.filter_run_when_matching focus: true
6
6
  config.order = 'random'
7
- config.run_all_when_everything_filtered = true
8
7
 
9
8
  # See https://relishapp.com/rspec/rspec-core/docs/command-line/only-failures
10
9
  config.example_status_persistence_file_path = 'spec/status_persistence.txt'
@@ -1,3 +1,3 @@
1
- example_id | status | run_time |
2
- ---------------------------------- | ------ | --------------- |
3
- ./spec/jekyll_outline_spec.rb[1:1] | passed | 0.00023 seconds |
1
+ example_id | status | run_time |
2
+ --------------------------- | ------- | --------------- |
3
+ ./spec/outline_spec.rb[1:1] | pending | 0.00001 seconds |
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jekyll_outline
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.1
4
+ version: 1.2.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mike Slinn
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-06-17 00:00:00.000000000 Z
11
+ date: 2024-07-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: jekyll
@@ -44,14 +44,14 @@ dependencies:
44
44
  requirements:
45
45
  - - ">="
46
46
  - !ruby/object:Gem::Version
47
- version: 0.7.0
47
+ version: 1.0.0
48
48
  type: :runtime
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
52
  - - ">="
53
53
  - !ruby/object:Gem::Version
54
- version: 0.7.0
54
+ version: 1.0.0
55
55
  description: 'Jekyll tag plugin that creates a clickable table of contents.
56
56
 
57
57
  '
@@ -102,7 +102,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
102
102
  - !ruby/object:Gem::Version
103
103
  version: '0'
104
104
  requirements: []
105
- rubygems_version: 3.3.3
105
+ rubygems_version: 3.5.16
106
106
  signing_key:
107
107
  specification_version: 4
108
108
  summary: Jekyll tag plugin that creates a clickable table of contents.