middleman-blog 4.0.3 → 4.1.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.
Files changed (89) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/ci.yml +25 -0
  3. data/.github/workflows/stale.yml +21 -0
  4. data/CHANGELOG.md +72 -60
  5. data/Gemfile +15 -24
  6. data/README.md +20 -30
  7. data/Rakefile +8 -14
  8. data/features/support/env.rb +2 -0
  9. data/features/support/time_steps.rb +9 -7
  10. data/features/tags.feature +4 -0
  11. data/fixtures/article-dirs-app/config-directory-indexes.rb +2 -0
  12. data/fixtures/article-dirs-app/config-permalink-with-dot.rb +2 -0
  13. data/fixtures/article-dirs-app/config.rb +2 -0
  14. data/fixtures/blog-sources-app/config.rb +2 -0
  15. data/fixtures/blog-sources-no-date-app/config.rb +2 -0
  16. data/fixtures/blog-sources-no-day-app/config.rb +2 -0
  17. data/fixtures/blog-sources-no-title-app/config.rb +2 -0
  18. data/fixtures/blog-sources-subdirs-app/config.rb +2 -0
  19. data/fixtures/calendar-and-tag-app/config-directory-indexes.rb +2 -0
  20. data/fixtures/calendar-and-tag-app/config.rb +2 -0
  21. data/fixtures/calendar-app/config-directory-indexes.rb +2 -0
  22. data/fixtures/calendar-app/config-only-year.rb +2 -0
  23. data/fixtures/calendar-app/config.rb +2 -0
  24. data/fixtures/calendar-multiblog-app/config.rb +2 -0
  25. data/fixtures/custom-article-template-app/config.rb +2 -0
  26. data/fixtures/custom-collections-app/config-blog-prefix.rb +2 -0
  27. data/fixtures/custom-collections-app/config-directory-indexes.rb +2 -0
  28. data/fixtures/custom-collections-app/config.rb +2 -0
  29. data/fixtures/custom-collections-multiblog-app/config.rb +2 -0
  30. data/fixtures/custom-collections-sources-app/config.rb +2 -0
  31. data/fixtures/custom-permalinks-app/config-directory-indexes.rb +2 -0
  32. data/fixtures/custom-permalinks-app/config.rb +2 -0
  33. data/fixtures/filename-date-app/config.rb +2 -0
  34. data/fixtures/future-date-app/config.rb +2 -0
  35. data/fixtures/indexes-app/config.rb +2 -0
  36. data/fixtures/lang-path-app/config.rb +2 -0
  37. data/fixtures/language-app/config.rb +3 -1
  38. data/fixtures/layouts-app/config.rb +2 -0
  39. data/fixtures/paginate-app/config-directory-indexes.rb +2 -0
  40. data/fixtures/paginate-app/config-paginate-off.rb +2 -0
  41. data/fixtures/paginate-app/config.rb +2 -0
  42. data/fixtures/paginate-multiblog-app/config.rb +2 -0
  43. data/fixtures/permalink-app/config.rb +2 -0
  44. data/fixtures/preview-app/config.rb +2 -0
  45. data/fixtures/published-app/config.rb +2 -0
  46. data/fixtures/summary-app/config.rb +2 -0
  47. data/fixtures/tags-app/config-directory-indexes.rb +2 -0
  48. data/fixtures/tags-app/config-filters.rb +2 -0
  49. data/fixtures/tags-app/config-no-tags.rb +2 -0
  50. data/fixtures/tags-app/config.rb +2 -0
  51. data/fixtures/tags-app/source/blog/2011-01-01-new-article.html.markdown +1 -1
  52. data/fixtures/tags-app/source/blog/2011-01-02-another-article.html.markdown +1 -0
  53. data/fixtures/tags-multiblog-app/config.rb +2 -0
  54. data/fixtures/time-zone-app/config.rb +2 -0
  55. data/lib/middleman-blog/blog_article.rb +6 -7
  56. data/lib/middleman-blog/blog_data.rb +3 -7
  57. data/lib/middleman-blog/calendar_pages.rb +8 -6
  58. data/lib/middleman-blog/commands/article.rb +7 -5
  59. data/lib/middleman-blog/commands/article.tt +2 -2
  60. data/lib/middleman-blog/custom_pages.rb +2 -0
  61. data/lib/middleman-blog/extension.rb +16 -12
  62. data/lib/middleman-blog/helpers.rb +4 -2
  63. data/lib/middleman-blog/paginator.rb +3 -1
  64. data/lib/middleman-blog/tag_pages.rb +2 -0
  65. data/lib/middleman-blog/truncate_html.rb +7 -5
  66. data/lib/middleman-blog/uri_templates.rb +8 -2
  67. data/lib/middleman-blog/version.rb +3 -1
  68. data/lib/middleman-blog.rb +2 -0
  69. data/lib/middleman_extension.rb +2 -0
  70. data/middleman-blog.gemspec +15 -22
  71. data/spec/spec_helper.rb +3 -1
  72. data/spec/uri_templates_spec.rb +2 -0
  73. metadata +11 -34
  74. data/.rubocop.yml +0 -69
  75. data/.travis.yml +0 -30
  76. data/Gemfile-4.x +0 -38
  77. data/fixtures/default-template-app/Gemfile +0 -6
  78. data/fixtures/default-template-app/config.rb +0 -35
  79. data/fixtures/default-template-app/source/2013-04-01-new-article.html.markdown +0 -25
  80. data/fixtures/default-template-app/source/about-me.html.erb +0 -0
  81. data/fixtures/default-template-app/source/archives.html.erb +0 -10
  82. data/fixtures/default-template-app/source/index.html.erb +0 -11
  83. data/fixtures/default-template-app/source/javascripts/_zepto.pjax.js +0 -744
  84. data/fixtures/default-template-app/source/javascripts/app.js +0 -11
  85. data/fixtures/default-template-app/source/javascripts/modernizr.js +0 -1
  86. data/fixtures/default-template-app/source/layouts/layout.erb +0 -62
  87. data/fixtures/default-template-app/source/stylesheets/app.css.scss +0 -109
  88. /data/{CONTRIBUTING.md → .github/CONTRIBUTING.md} +0 -0
  89. /data/{ISSUE_TEMPLATE.md → .github/ISSUE_TEMPLATE.md} +0 -0
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  activate :blog do |blog|
2
4
  blog.sources = ':category/:year-:month-:day-:title.html'
3
5
  blog.permalink = 'blog/:year-:month-:day-:title.html'
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'middleman-blog'
2
4
  activate :blog do |blog|
3
5
  blog.sources = 'blog/:year-:month-:day-:title.html'
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'middleman-blog'
2
4
  activate :blog do |blog|
3
5
  blog.sources = 'blog/:year-:month-:day-:title.html'
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  Time.zone = 'Pacific Time (US & Canada)'
2
4
 
3
5
  activate :blog
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  Time.zone = 'Pacific Time (US & Canada)'
2
4
 
3
5
  activate :blog do |blog|
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  activate :blog do |blog|
2
4
  blog.sources = ':year/:month/:day/:title.html'
3
5
  end
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  activate :i18n
2
4
 
3
5
  activate :blog do |blog|
@@ -1,2 +1,4 @@
1
- activate :i18n
1
+ # frozen_string_literal: true
2
+
3
+ activate :i18n
2
4
  activate :blog
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  activate :blog do |blog|
2
4
  blog.sources = ':year/:month/:day/:title.html'
3
5
  end
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  activate :blog do |blog|
2
4
  blog.sources = 'blog/:year-:month-:day-:title.html'
3
5
  blog.permalink = 'blog/:year-:month-:day-:title.html'
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  activate :blog do |blog|
2
4
  blog.sources = 'blog/:year-:month-:day-:title.html'
3
5
  blog.permalink = 'blog/:year-:month-:day-:title.html'
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  activate :blog do |blog|
2
4
  blog.sources = 'blog/:year-:month-:day-:title.html'
3
5
  blog.permalink = 'blog/:year-:month-:day-:title.html'
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  activate :blog do |blog|
2
4
  blog.name = 'blog_name_1'
3
5
  blog.prefix = 'blog1'
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  activate :blog do |blog|
2
4
  blog.sources = ':category/:year-:month-:day-:title.html'
3
5
  blog.permalink = ':category/:custom-:year-:month-:day-:title.html'
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  activate :blog do |blog|
2
4
  blog.sources = ':year/:month/:day/:title.html'
3
5
  end
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  activate :blog do |blog|
2
4
  blog.sources = 'blog/:year-:month-:day-:title.html'
3
5
  end
@@ -1 +1,3 @@
1
+ # frozen_string_literal: true
2
+
1
3
  activate :blog
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'middleman-blog'
2
4
 
3
5
  activate :blog do |blog|
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'middleman-blog'
2
4
 
3
5
  activate :blog do |blog|
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'middleman-blog'
2
4
 
3
5
  activate :blog do |blog|
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'middleman-blog'
2
4
 
3
5
  activate :blog do |blog|
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  title: "Newer Article"
3
3
  date: 2011-01-01
4
- tags: foo, bar
4
+ tags: foo, bar, 日本語
5
5
  ---
6
6
 
7
7
  Newer Article Content
@@ -4,6 +4,7 @@ date: 2011-01-02
4
4
  tags:
5
5
  - foo
6
6
  - 120
7
+ - 日本語
7
8
  ---
8
9
 
9
10
  Another Article Content
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  activate :blog do |blog|
2
4
  blog.name = 'blog_name_1'
3
5
  blog.prefix = 'blog1'
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  set :time_zone, 'Tokyo'
2
4
 
3
5
  activate :blog do |blog|
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'active_support/time_with_zone'
2
4
  require 'active_support/core_ext/time/acts_like'
3
5
  require 'active_support/core_ext/time/calculations'
@@ -14,9 +16,6 @@ module Middleman
14
16
  module BlogArticle
15
17
  extend Gem::Deprecate
16
18
 
17
- ##
18
- #
19
- ##
20
19
  def self.extended(base)
21
20
  base.class.send(:attr_accessor, :blog_controller)
22
21
  end
@@ -204,10 +203,10 @@ module Middleman
204
203
 
205
204
  # First get the date from frontmatter
206
205
  @_date = if frontmatter_date.is_a? Time
207
- frontmatter_date.in_time_zone
208
- else
209
- Time.zone.parse(frontmatter_date.to_s)
210
- end
206
+ frontmatter_date.in_time_zone
207
+ else
208
+ Time.zone.parse(frontmatter_date.to_s)
209
+ end
211
210
 
212
211
  # Next figure out the date from the filename
213
212
  source_vars = blog_data.source_template.variables
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'middleman-blog/uri_templates'
2
4
 
3
5
  module Middleman
@@ -49,7 +51,7 @@ module Middleman
49
51
  # @return [Array<Middleman::Sitemap::Resource>]
50
52
  ##
51
53
  def articles
52
- @_articles.select(&(options.filter || proc { |a| a })).sort_by(&:date).reverse
54
+ @_articles.select(&options.filter || proc { |a| a }).sort_by(&:date).reverse
53
55
  end
54
56
 
55
57
  ##
@@ -216,9 +218,6 @@ module Middleman
216
218
  .merge(extra)
217
219
  end
218
220
 
219
- ##
220
- #
221
- ##
222
221
  def convert_to_article(resource)
223
222
  return resource if resource.is_a?(BlogArticle)
224
223
 
@@ -232,9 +231,6 @@ module Middleman
232
231
  resource
233
232
  end
234
233
 
235
- ##
236
- #
237
- ##
238
234
  def template_path(template, article, extras = {})
239
235
  apply_uri_template template, permalink_options(article, extras)
240
236
  end
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'middleman-blog/uri_templates'
2
4
 
3
5
  module Middleman
@@ -31,12 +33,12 @@ module Middleman
31
33
  # @return [String]
32
34
  def link(year, month = nil, day = nil)
33
35
  template = if day
34
- @day_link_template
35
- elsif month
36
- @month_link_template
37
- else
38
- @year_link_template
39
- end
36
+ @day_link_template
37
+ elsif month
38
+ @month_link_template
39
+ else
40
+ @year_link_template
41
+ end
40
42
 
41
43
  apply_uri_template template, date_to_params(Date.new(year, month || 1, day || 1))
42
44
  end
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'middleman-core/cli'
2
4
  require 'date'
3
5
  require 'middleman-blog/uri_templates'
@@ -77,14 +79,14 @@ module Middleman
77
79
  end
78
80
 
79
81
  blog_inst = if options[:blog]
80
- app.extensions[:blog].find { |_key, instance| instance.options[:name] == options[:blog] }[ 1 ]
81
- else
82
- app.extensions[:blog].values.first
83
- end
82
+ app.extensions[:blog].find { |_key, instance| instance.options[:name] == options[:blog] }[ 1 ]
83
+ else
84
+ app.extensions[:blog].values.first
85
+ end
84
86
 
85
87
  unless blog_inst
86
88
  msg = 'Could not find an active blog instance'
87
- msg << " named #{options[:blog]}" if options[:blog]
89
+ msg = "#{msg} named #{options[:blog]}" if options[:blog]
88
90
  throw msg
89
91
  end
90
92
 
@@ -1,7 +1,7 @@
1
1
  ---
2
2
 
3
- title: <%= @title %>
4
- date: <%= @date.strftime('%F %R %Z') %>
3
+ title: "<%= %Q[#{@title}] %>"
4
+ date: <%= @date.strftime('%F %R %z') %>
5
5
  tags: <%= @tags.join(",") %>
6
6
 
7
7
  ---
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'middleman-blog/uri_templates'
2
4
 
3
5
  module Middleman
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'active_support/core_ext/time/zones'
2
4
  require 'middleman-blog/blog_data'
3
5
  require 'middleman-blog/blog_article'
@@ -79,18 +81,18 @@ module Middleman
79
81
  end
80
82
 
81
83
  # If "prefix" option is specified, all other paths are relative to it.
82
- if options.prefix
83
- options.prefix = "/#{options.prefix}" unless options.prefix.start_with? '/'
84
- options.permalink = File.join(options.prefix, options.permalink)
85
- options.sources = File.join(options.prefix, options.sources)
86
- options.taglink = File.join(options.prefix, options.taglink)
87
- options.year_link = File.join(options.prefix, options.year_link)
88
- options.month_link = File.join(options.prefix, options.month_link)
89
- options.day_link = File.join(options.prefix, options.day_link)
90
-
91
- options.custom_collections.each do |_key, opts|
92
- opts[:link] = File.join(options.prefix, opts[:link])
93
- end
84
+ return unless options.prefix
85
+
86
+ options.prefix = "/#{options.prefix}" unless options.prefix.start_with? '/'
87
+ options.permalink = File.join(options.prefix, options.permalink)
88
+ options.sources = File.join(options.prefix, options.sources)
89
+ options.taglink = File.join(options.prefix, options.taglink)
90
+ options.year_link = File.join(options.prefix, options.year_link)
91
+ options.month_link = File.join(options.prefix, options.month_link)
92
+ options.day_link = File.join(options.prefix, options.day_link)
93
+
94
+ options.custom_collections.each_value do |opts|
95
+ opts[:link] = File.join(options.prefix, opts[:link])
94
96
  end
95
97
  end
96
98
 
@@ -113,6 +115,8 @@ module Middleman
113
115
  @app.ignore(options.day_template) if options.day_template
114
116
  @app.ignore options.tag_template if options.tag_template
115
117
 
118
+ ActiveSupport.to_time_preserves_timezone = :zone
119
+
116
120
  # Make sure ActiveSupport's TimeZone stuff has something to work with,
117
121
  # allowing people to set their desired time zone via Time.zone or
118
122
  # set :time_zone
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module Middleman
2
4
  module Blog
3
5
  # Blog-related helpers that are available to the Middleman application in +config.rb+ and in templates.
@@ -59,7 +61,7 @@ module Middleman
59
61
  # Determine whether the currently rendering template is a {BlogArticle}.
60
62
  # This can be useful in layouts and helpers.
61
63
  # @return [Boolean]
62
- def is_blog_article? # rubocop:disable Naming/PredicateName
64
+ def is_blog_article?
63
65
  !current_article.nil?
64
66
  end
65
67
 
@@ -67,7 +69,7 @@ module Middleman
67
69
  # @return [BlogArticle]
68
70
  def current_article
69
71
  article = current_resource
70
- article if article&.is_a?(BlogArticle)
72
+ article if article.is_a?(BlogArticle)
71
73
  end
72
74
 
73
75
  # Get a path to the given tag page, based on the +taglink+ blog setting.
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'middleman-blog/uri_templates'
2
4
 
3
5
  module Middleman
@@ -149,7 +151,7 @@ module Middleman
149
151
  else
150
152
  page_url = apply_uri_template page_link, num: page_num
151
153
  index_re = %r{(^|/)#{Regexp.escape(@app.config[:index_file])}$}
152
- if res.path =~ index_re
154
+ if res.path&.match?(index_re)
153
155
  res.path.sub(index_re, "\\1#{page_url}/#{@app.config[:index_file]}")
154
156
  else
155
157
  res.path.sub(%r{(^|/)([^/]*)\.([^/]*)$}, "\\1\\2/#{page_url}.\\3")
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'middleman-blog/uri_templates'
2
4
 
3
5
  module Middleman
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  begin
2
4
  require 'nokogiri'
3
5
  rescue LoadError
@@ -48,7 +50,7 @@ module NokogiriTruncator
48
50
  module TextNode
49
51
  def truncate(max_length, ellipsis)
50
52
  # Don't break in the middle of a word
51
- trimmed_content = content.match(/(.{1,#{max_length}}[\w]*)/m).to_s
53
+ trimmed_content = content.match(/(.{1,#{max_length}}\w*)/m).to_s
52
54
  trimmed_content << ellipsis if trimmed_content.length < content.length
53
55
 
54
56
  Nokogiri::XML::Text.new(trimmed_content, parent)
@@ -63,7 +65,7 @@ module NokogiriTruncator
63
65
  end
64
66
  end
65
67
 
66
- Nokogiri::HTML::DocumentFragment.send(:include, NokogiriTruncator::NodeWithChildren)
67
- Nokogiri::XML::Element.send(:include, NokogiriTruncator::NodeWithChildren)
68
- Nokogiri::XML::Text.send(:include, NokogiriTruncator::TextNode)
69
- Nokogiri::XML::Comment.send(:include, NokogiriTruncator::CommentNode)
68
+ Nokogiri::HTML::DocumentFragment.include NokogiriTruncator::NodeWithChildren
69
+ Nokogiri::XML::Element.include NokogiriTruncator::NodeWithChildren
70
+ Nokogiri::XML::Text.include NokogiriTruncator::TextNode
71
+ Nokogiri::XML::Comment.include NokogiriTruncator::CommentNode
@@ -1,4 +1,7 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'addressable/template'
4
+ require 'active_support/all'
2
5
  require 'middleman-core/util'
3
6
  require 'active_support/inflector'
4
7
  require 'active_support/inflector/transliterate'
@@ -57,7 +60,7 @@ module Middleman
57
60
 
58
61
  # Reimplementation of http://api.rubyonrails.org/classes/ActiveSupport/Inflector.html#method-i-parameterize that preserves un-transliterate-able multibyte chars.
59
62
  parameterized_string = ::ActiveSupport::Inflector.transliterate(str.to_s).downcase
60
- parameterized_string.gsub!(/[^a-z0-9\-_\?]+/, sep)
63
+ parameterized_string.gsub!(/[^a-z0-9\-_?]+/, sep)
61
64
 
62
65
  # Check for multibytes and sub back in
63
66
  parameterized_string.chars.to_a.each_with_index do |char, i|
@@ -73,10 +76,13 @@ module Middleman
73
76
 
74
77
  # Remove leading/trailing separator.
75
78
  parameterized_string.gsub!(/^#{re_sep}|#{re_sep}$/, '')
79
+
80
+ # Replace all _ with -
76
81
  parameterized_string.tr!('_', '-')
82
+
83
+ # Delete all ?
77
84
  parameterized_string.delete!('?')
78
85
 
79
- # Replace all ?
80
86
  parameterized_string
81
87
  end
82
88
 
@@ -1,5 +1,7 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module Middleman
2
4
  module Blog
3
- VERSION = '4.0.3'.freeze
5
+ VERSION = '4.1.0'
4
6
  end
5
7
  end
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'middleman-core'
2
4
  require 'middleman-blog/version'
3
5
 
@@ -1 +1,3 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'middleman-blog'
@@ -1,25 +1,18 @@
1
- # -*- encoding: utf-8 -*-
2
- $:.push File.expand_path( "../lib", __FILE__ )
3
- require "middleman-blog/version"
1
+ require "./lib/middleman-blog/version"
4
2
 
5
3
  Gem::Specification.new do | s |
6
-
7
- s.name = "middleman-blog"
8
- s.version = Middleman::Blog::VERSION
9
- s.platform = Gem::Platform::RUBY
10
- s.authors = [ "Thomas Reynolds", "Ben Hollis", "Ian Warner" ]
11
- s.email = [ "me@tdreyno.com", "ben@benhollis.net", "ian.warner@drykiss.com" ]
12
- s.homepage = "https://github.com/middleman/middleman-blog"
13
- s.summary = %q{ Blog engine for Middleman }
14
- s.description = %q{ Blog engine for Middleman }
15
- s.license = "MIT"
16
- s.files = `git ls-files -z`.split( "\0" )
17
- s.test_files = `git ls-files -z -- {fixtures,features}/*`.split( "\0" )
18
- s.require_paths = [ "lib" ]
19
- s.required_ruby_version = '>= 2.3.0'
20
-
21
- s.add_dependency( "middleman-core", [ ">= 4.0.0" ] )
22
- s.add_dependency( "tzinfo", [ ">= 0.3.0" ] )
23
- s.add_dependency( "addressable", [ "~> 2.3" ] )
24
-
4
+ s.name = "middleman-blog"
5
+ s.version = Middleman::Blog::VERSION
6
+ s.platform = Gem::Platform::RUBY
7
+ s.authors = [ "Thomas Reynolds", "Ben Hollis", "Ian Warner" ]
8
+ s.email = [ "me@tdreyno.com", "ben@benhollis.net", "ian.warner@drykiss.com" ]
9
+ s.homepage = "https://github.com/middleman/middleman-blog"
10
+ s.summary = %q{ Blog engine for Middleman }
11
+ s.description = %q{ Blog engine for Middleman }
12
+ s.license = "MIT"
13
+ s.files = `git ls-files -z`.split( "\0" )
14
+ s.test_files = `git ls-files -z -- {fixtures,features}/*`.split( "\0" )
15
+ s.add_dependency("middleman-core", ">= 4.0.0")
16
+ s.add_dependency("tzinfo", ">= 0.3.0")
17
+ s.add_dependency("addressable", "~> 2.3")
25
18
  end
data/spec/spec_helper.rb CHANGED
@@ -1,2 +1,4 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'simplecov'
2
- SimpleCov.root(File.expand_path(File.dirname(__FILE__) + '/..'))
4
+ SimpleCov.root(File.expand_path("#{File.dirname(__FILE__)}/.."))
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require 'middleman-blog/uri_templates'
2
4
 
3
5
  describe 'Middleman::Blog::UriTemplates' do
metadata CHANGED
@@ -1,16 +1,16 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: middleman-blog
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.3
4
+ version: 4.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Thomas Reynolds
8
8
  - Ben Hollis
9
9
  - Ian Warner
10
- autorequire:
10
+ autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2018-12-27 00:00:00.000000000 Z
13
+ date: 2025-04-07 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: middleman-core
@@ -64,15 +64,14 @@ extensions: []
64
64
  extra_rdoc_files: []
65
65
  files:
66
66
  - ".editorconfig"
67
+ - ".github/CONTRIBUTING.md"
68
+ - ".github/ISSUE_TEMPLATE.md"
69
+ - ".github/workflows/ci.yml"
70
+ - ".github/workflows/stale.yml"
67
71
  - ".gitignore"
68
- - ".rubocop.yml"
69
- - ".travis.yml"
70
72
  - ".yardopts"
71
73
  - CHANGELOG.md
72
- - CONTRIBUTING.md
73
74
  - Gemfile
74
- - Gemfile-4.x
75
- - ISSUE_TEMPLATE.md
76
75
  - LICENSE.md
77
76
  - README.md
78
77
  - Rakefile
@@ -190,17 +189,6 @@ files:
190
189
  - fixtures/custom-permalinks-app/source/blog/2011-01-03-third-article.html.markdown
191
190
  - fixtures/custom-permalinks-app/source/index.html.erb
192
191
  - fixtures/custom-permalinks-app/source/layout.erb
193
- - fixtures/default-template-app/Gemfile
194
- - fixtures/default-template-app/config.rb
195
- - fixtures/default-template-app/source/2013-04-01-new-article.html.markdown
196
- - fixtures/default-template-app/source/about-me.html.erb
197
- - fixtures/default-template-app/source/archives.html.erb
198
- - fixtures/default-template-app/source/index.html.erb
199
- - fixtures/default-template-app/source/javascripts/_zepto.pjax.js
200
- - fixtures/default-template-app/source/javascripts/app.js
201
- - fixtures/default-template-app/source/javascripts/modernizr.js
202
- - fixtures/default-template-app/source/layouts/layout.erb
203
- - fixtures/default-template-app/source/stylesheets/app.css.scss
204
192
  - fixtures/filename-date-app/config.rb
205
193
  - fixtures/filename-date-app/source/2011-01-01-new-article.html.markdown
206
194
  - fixtures/filename-date-app/source/2011-01-03-filename-and-frontmatter.html.markdown
@@ -365,7 +353,7 @@ homepage: https://github.com/middleman/middleman-blog
365
353
  licenses:
366
354
  - MIT
367
355
  metadata: {}
368
- post_install_message:
356
+ post_install_message:
369
357
  rdoc_options: []
370
358
  require_paths:
371
359
  - lib
@@ -373,15 +361,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
373
361
  requirements:
374
362
  - - ">="
375
363
  - !ruby/object:Gem::Version
376
- version: 2.3.0
364
+ version: '0'
377
365
  required_rubygems_version: !ruby/object:Gem::Requirement
378
366
  requirements:
379
367
  - - ">="
380
368
  - !ruby/object:Gem::Version
381
369
  version: '0'
382
370
  requirements: []
383
- rubygems_version: 3.0.1
384
- signing_key:
371
+ rubygems_version: 3.4.10
372
+ signing_key:
385
373
  specification_version: 4
386
374
  summary: Blog engine for Middleman
387
375
  test_files:
@@ -499,17 +487,6 @@ test_files:
499
487
  - fixtures/custom-permalinks-app/source/blog/2011-01-03-third-article.html.markdown
500
488
  - fixtures/custom-permalinks-app/source/index.html.erb
501
489
  - fixtures/custom-permalinks-app/source/layout.erb
502
- - fixtures/default-template-app/Gemfile
503
- - fixtures/default-template-app/config.rb
504
- - fixtures/default-template-app/source/2013-04-01-new-article.html.markdown
505
- - fixtures/default-template-app/source/about-me.html.erb
506
- - fixtures/default-template-app/source/archives.html.erb
507
- - fixtures/default-template-app/source/index.html.erb
508
- - fixtures/default-template-app/source/javascripts/_zepto.pjax.js
509
- - fixtures/default-template-app/source/javascripts/app.js
510
- - fixtures/default-template-app/source/javascripts/modernizr.js
511
- - fixtures/default-template-app/source/layouts/layout.erb
512
- - fixtures/default-template-app/source/stylesheets/app.css.scss
513
490
  - fixtures/filename-date-app/config.rb
514
491
  - fixtures/filename-date-app/source/2011-01-01-new-article.html.markdown
515
492
  - fixtures/filename-date-app/source/2011-01-03-filename-and-frontmatter.html.markdown