bridgetown-minify-html 0.1.0 → 0.2.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c6a57d61db7ff8bd32025ce24450ec588b8b7537a85d2c3e9a5b00e549403a79
4
- data.tar.gz: e1f8a7f2560c5356c440ba1b1569ab2457ee9b7625258536fef24cae671fc7b6
3
+ metadata.gz: 4e38c03a2b0f0a8220e328aef8e0baa16259cd612ceb429abd91169837997686
4
+ data.tar.gz: ef52a1322bd8bb2bdcebe71514b1f00fcb1bd54c4fafd8face8901559c08de3b
5
5
  SHA512:
6
- metadata.gz: 53b9cd28f9803b548e07cbe99b13dbfd051f75070eeaff8ef77cdc96d7ef26e390abb6f3924820037d27d776f94358db1af23d59f1f1fa6054026f82b99e6855
7
- data.tar.gz: 862364452a15dda77e8df622818c234c3646a1553bf816779c0dea3d3054652427c766907d9b480e219e6cd7fbfb85cccfbc0fbe21aac7b889167f1bf3d97aac
6
+ metadata.gz: 900c116fceb6f43cdafb677003752d839ddcec1088b6fd59a7195be4ddd0056f9d46d5619c0acd053e2f0404f2892fb3020750a6e21b602b0f53e1c8040fd49f
7
+ data.tar.gz: 213ec9af0da70fc26430d9b68fc3e29b6ba107bbb0edf7d2848afda70f512e571f19e092cce95d685dc7a5ab4c5dd90bbcdf83b643d2109bc065c7c2b1c187d6
@@ -2,6 +2,8 @@
2
2
  name: Changelog
3
3
 
4
4
  on:
5
+ release:
6
+ types: [created]
5
7
  push:
6
8
  branches:
7
9
  - master
@@ -12,7 +12,7 @@ jobs:
12
12
  steps:
13
13
  - uses: actions/checkout@v2
14
14
  - name: Set up Ruby 2.6
15
- uses: actions/setup-ruby@v1
15
+ uses: actions/setup-ruby@v1.1.1
16
16
  with:
17
17
  ruby-version: 2.6.x
18
18
 
@@ -2,7 +2,24 @@
2
2
 
3
3
  ## [Unreleased](https://github.com/MikeRogers0/bridgetown-minify-html/tree/HEAD)
4
4
 
5
- [Full Changelog](https://github.com/MikeRogers0/bridgetown-minify-html/compare/5ce9f22631f178ecf164501e7d28d6dee902ce9c...HEAD)
5
+ [Full Changelog](https://github.com/MikeRogers0/bridgetown-minify-html/compare/v0.1.0...HEAD)
6
+
7
+ **Fixed bugs:**
8
+
9
+ - bug: undefined local variable or method extension [\#8](https://github.com/MikeRogers0/bridgetown-minify-html/pull/8) ([MikeRogers0](https://github.com/MikeRogers0))
10
+ - bug: Bridgetown::StaticFile don't have output\_ext - so ignoring them [\#7](https://github.com/MikeRogers0/bridgetown-minify-html/pull/7) ([MikeRogers0](https://github.com/MikeRogers0))
11
+ - fix: Making sure changelog is regenerated on release [\#4](https://github.com/MikeRogers0/bridgetown-minify-html/pull/4) ([MikeRogers0](https://github.com/MikeRogers0))
12
+
13
+ **Merged pull requests:**
14
+
15
+ - feat: Rewording test titles [\#6](https://github.com/MikeRogers0/bridgetown-minify-html/pull/6) ([MikeRogers0](https://github.com/MikeRogers0))
16
+ - chores: Adding rubygems badge in [\#5](https://github.com/MikeRogers0/bridgetown-minify-html/pull/5) ([MikeRogers0](https://github.com/MikeRogers0))
17
+ - Update rake requirement from ~\> 12.0 to ~\> 13.0 [\#2](https://github.com/MikeRogers0/bridgetown-minify-html/pull/2) ([dependabot[bot]](https://github.com/apps/dependabot))
18
+ - Bump actions/setup-ruby from v1 to v1.1.1 [\#1](https://github.com/MikeRogers0/bridgetown-minify-html/pull/1) ([dependabot[bot]](https://github.com/apps/dependabot))
19
+
20
+ ## [v0.1.0](https://github.com/MikeRogers0/bridgetown-minify-html/tree/v0.1.0) (2020-07-20)
21
+
22
+ [Full Changelog](https://github.com/MikeRogers0/bridgetown-minify-html/compare/5ce9f22631f178ecf164501e7d28d6dee902ce9c...v0.1.0)
6
23
 
7
24
  **Implemented enhancements:**
8
25
 
data/README.md CHANGED
@@ -1,3 +1,5 @@
1
+ [![Gem Version](https://badge.fury.io/rb/bridgetown-minify-html.svg)](https://badge.fury.io/rb/bridgetown-minify-html)
2
+
1
3
  # Bridgetown Minify HTML
2
4
 
3
5
  A Bridgetown plugin to Minify your outputted HTML.
@@ -22,7 +22,7 @@ Gem::Specification.new do |spec|
22
22
 
23
23
  spec.add_development_dependency "bundler"
24
24
  spec.add_development_dependency "nokogiri", "~> 1.6"
25
- spec.add_development_dependency "rake", "~> 12.0"
25
+ spec.add_development_dependency "rake", "~> 13.0"
26
26
  spec.add_development_dependency "rspec", "~> 3.0"
27
27
  spec.add_development_dependency "rubocop-bridgetown", "~> 0.2"
28
28
  end
@@ -41,14 +41,14 @@ module BridgetownMinifyHtml
41
41
  private
42
42
 
43
43
  def minify_page(page)
44
- return unless compressible?(page.output_ext)
44
+ return unless compressible?(page)
45
45
 
46
46
  page.output = compressor.compress(page.output)
47
47
  @minified_count += 1
48
48
  end
49
49
 
50
- def compressible?(extension)
51
- [".html", ".svg", ".xml"].include?(extension)
50
+ def compressible?(page)
51
+ page.respond_to?(:output_ext) && [".html", ".svg", ".xml"].include?(page.output_ext)
52
52
  end
53
53
 
54
54
  def compressor
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module BridgetownMinifyHtml
4
- VERSION = "0.1.0"
4
+ VERSION = "0.2.0"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: bridgetown-minify-html
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mike Rogers
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-07-20 00:00:00.000000000 Z
11
+ date: 2020-07-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bridgetown
@@ -84,14 +84,14 @@ dependencies:
84
84
  requirements:
85
85
  - - "~>"
86
86
  - !ruby/object:Gem::Version
87
- version: '12.0'
87
+ version: '13.0'
88
88
  type: :development
89
89
  prerelease: false
90
90
  version_requirements: !ruby/object:Gem::Requirement
91
91
  requirements:
92
92
  - - "~>"
93
93
  - !ruby/object:Gem::Version
94
- version: '12.0'
94
+ version: '13.0'
95
95
  - !ruby/object:Gem::Dependency
96
96
  name: rspec
97
97
  requirement: !ruby/object:Gem::Requirement