shortcode 1.2.0 → 1.2.1

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
  SHA1:
3
- metadata.gz: b6e16afa9cbced683fa57993d25230c1ccbbc17d
4
- data.tar.gz: 3085a76be15d7c3522219ff2efa39b2e5db9bf1a
3
+ metadata.gz: 11f134f87bfa70439f00a60c1b424648357cbbe4
4
+ data.tar.gz: 99a050c747acb9dfedc1f3f9e035d4eb9b496dc4
5
5
  SHA512:
6
- metadata.gz: dc17a4b44ad1e685609b44a735395ed8802a834810b9d36cb403ab671a05b34056ea2329cb63bcc4002e4107774f0747bbd66968ce66b1f8b3a62d104c14130e
7
- data.tar.gz: 1e816940f82d9cede5b8741cb02591dc1fbe5a5b8d060f1cacd3cec152f6650d78b4c619b8134bcf7d075307d4d2b676428dc045b7a32aa23e09ce84685987e8
6
+ metadata.gz: a021bdbe0979e2266972703969c0c01030a45138de2e1e99e36ba77845020b7f787056d3a13afd6337fdaef3c1b39e3b1004f4727d454a0d648d86f64953891b
7
+ data.tar.gz: 44ddde6b96b26707107ee0ba028de4404d965ed5453d9e1be587c09040f54d9c258d0d3b411162311ccdd57d3b7b2b5940109a40fe8af4a6f43952f0730e6d3a
data/CHANGELOG.md CHANGED
@@ -1,3 +1,9 @@
1
+ ## 1.2.1 (June 1, 2017)
2
+
3
+ Misc:
4
+
5
+ - Added singleton usage deprecation warnings
6
+
1
7
  ## 1.2.0 (June 1, 2017)
2
8
 
3
9
  Features:
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- shortcode (1.1.1)
4
+ shortcode (1.2.1)
5
5
  parslet (= 1.8.0)
6
6
 
7
7
  GEM
data/README.md CHANGED
@@ -278,24 +278,6 @@ shortcode.setup do |config|
278
278
  end
279
279
  ```
280
280
 
281
- ### Singleton
282
-
283
- You can optionally use Shortcode as a singleton instance with the same configuration throughout.
284
-
285
- To do this, you call methods directly on the `Shortcode` class.
286
-
287
- For example:
288
-
289
- ```ruby
290
- Shortcode.setup do |config|
291
- config.block_tags = [:quote]
292
- end
293
-
294
- Shortcode.register_presenter(QuotePresenterClass)
295
-
296
- Shortcode.process('[quote]Some quote[/quote]')
297
- ```
298
-
299
281
  ## Contributing
300
282
 
301
283
  1. Fork it
data/lib/shortcode.rb CHANGED
@@ -12,6 +12,7 @@ rescue LoadError; end
12
12
  class Shortcode
13
13
  # This is providedc for backwards compatibility
14
14
  def self.process(string, additional_attributes=nil)
15
+ warn "[DEPRECATION] singleton `Shortcode.process` is deprecated and will be removed in version 2.0. Please create a new instance `Shortcode.new` and call `process` on the instance."
15
16
  singleton.process(string, additional_attributes)
16
17
  end
17
18
 
@@ -22,11 +23,13 @@ class Shortcode
22
23
 
23
24
  # This is providedc for backwards compatibility
24
25
  def self.setup(&prc)
26
+ warn "[DEPRECATION] singleton `Shortcode.setup` is deprecated and will be removed in version 2.0. Please create a new instance `Shortcode.new` and call `setup` on the instance."
25
27
  singleton.setup(&prc)
26
28
  end
27
29
 
28
30
  # This is providedc for backwards compatibility
29
31
  def self.register_presenter(*presenters)
32
+ warn "[DEPRECATION] singleton `Shortcode.register_presenter` is deprecated and will be removed in version 2.0. Please create a new instance `Shortcode.new` and call `register_presenter` on the instance."
30
33
  singleton.register_presenter(*presenters)
31
34
  end
32
35
 
@@ -1,3 +1,3 @@
1
1
  class Shortcode
2
- VERSION = "1.2.0"
2
+ VERSION = "1.2.1"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: shortcode
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0
4
+ version: 1.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jamie Dyer
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-06-01 00:00:00.000000000 Z
11
+ date: 2017-06-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: parslet
@@ -221,7 +221,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
221
221
  version: '0'
222
222
  requirements: []
223
223
  rubyforge_project:
224
- rubygems_version: 2.6.11
224
+ rubygems_version: 2.5.2
225
225
  signing_key:
226
226
  specification_version: 4
227
227
  summary: Gem for parsing wordpress style shortcodes in ruby projects