howzit 2.1.6 → 2.1.8

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: e053730ff4a0386a25682221bcf58a36a81e15b220659afb72cb1a5084172664
4
- data.tar.gz: baea37c956d1c64506499a764a502c879eb5ee70830e2ced4cb04f596b8231a1
3
+ metadata.gz: 8a339dc102a78623a6b3ef96602e081bf4a6d408d1f35d35d4f98dbc8135c154
4
+ data.tar.gz: 420d78ffa41450f2546d22402d0ffaace9f4fedc450bf955de58038bee1fd657
5
5
  SHA512:
6
- metadata.gz: 78e286ded9e392237f321e7c3361945ee2e8f586c091ed9ab78fc68757d49710416dbe76d03edd43b464df857527b7e8412649a85c9543a3b490ff03994a8acd
7
- data.tar.gz: 5df805459407073f865e5223bef535d1f488f2207f7cdb243cb5357da2a5ee8f19c05f5f4f1dec630b24122ce0892ef0783d46aaa161f9c36f5170823f18316b
6
+ metadata.gz: 2ea2707c779434c870a0d98d084f47dbe47b795f1c15282541866ba1c7cc74527f49f155d279d872fd2f7be57e1c8c6590d21dc31d29259c7b5358aef3ce589f
7
+ data.tar.gz: e4c7250b27f0d89521bfdfc5aaade5e5f5d9ecda605ecca64c07402b2e3d0e97791768872e7a73ad1f5c27fb53f39507f98a7a6a3c41a56fefc5b01e45ee1f5a
data/CHANGELOG.md CHANGED
@@ -1,3 +1,19 @@
1
+ ### 2.1.8
2
+
3
+ 2023-05-31 11:58
4
+
5
+ #### FIXED
6
+
7
+ - Colors.rb error when code is integer
8
+
9
+ ### 2.1.7
10
+
11
+ 2023-05-29 12:59
12
+
13
+ #### FIXED
14
+
15
+ - Handle variable replacements on lines containing colons outside of variable
16
+
1
17
  ### 2.1.6
2
18
 
3
19
  2023-05-29 12:42
data/lib/howzit/colors.rb CHANGED
@@ -206,7 +206,7 @@ module Howzit
206
206
  end
207
207
 
208
208
  def translate_rgb(code)
209
- return code if code !~ /#[A-Z0-9]{3,6}/i
209
+ return code if code.to_s !~ /#[A-Z0-9]{3,6}/i
210
210
 
211
211
  rgb(code)
212
212
  end
@@ -224,10 +224,10 @@ module Howzit
224
224
  end
225
225
 
226
226
  # Replace empty variables with default
227
- gsub!(/\[%(.*?):(.*?)\]/, '\2')
227
+ gsub!(/\[%([^\]]+?):(.*?)\]/, '\2')
228
228
 
229
229
  # Remove remaining empty variables
230
- gsub(/\[%(.*?)\]/, '')
230
+ gsub(/\[%.*?\]/, '')
231
231
  end
232
232
 
233
233
  ##
@@ -3,5 +3,5 @@
3
3
  # Primary module for this gem.
4
4
  module Howzit
5
5
  # Current Howzit version.
6
- VERSION = '2.1.6'
6
+ VERSION = '2.1.8'
7
7
  end
data/spec/spec_helper.rb CHANGED
@@ -28,6 +28,8 @@ end
28
28
 
29
29
  def save_buildnote
30
30
  note = <<~EONOTE
31
+ defined: this is defined
32
+
31
33
  # Howzit Test
32
34
 
33
35
  ## Topic Balogna
@@ -39,6 +41,11 @@ def save_buildnote
39
41
  @run(ls -1 &> /dev/null) Null Output
40
42
  @include(Topic Tropic)
41
43
 
44
+ ```run
45
+ #!/usr/bin/env ruby
46
+ title = "[%undefined]".empty? ? "[%defined]" : "[%undefined]"
47
+ ```
48
+
42
49
  @after
43
50
  This should be a postrequisite.
44
51
  @end
@@ -49,6 +56,8 @@ def save_buildnote
49
56
 
50
57
  - It has a list in it
51
58
  - That's pretty fun, right?
59
+ - Defined: '[%defined]'
60
+ - Undefined: '[%undefined]'
52
61
 
53
62
  ## Topic Tropic
54
63
 
data/spec/topic_spec.rb CHANGED
@@ -30,8 +30,8 @@ describe Howzit::Topic do
30
30
  end
31
31
 
32
32
  describe '.tasks' do
33
- it 'has 2 tasks' do
34
- expect(topic.tasks.count).to eq 2
33
+ it 'has 3 tasks' do
34
+ expect(topic.tasks.count).to eq 3
35
35
  end
36
36
  end
37
37
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: howzit
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.6
4
+ version: 2.1.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brett Terpstra
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-05-29 00:00:00.000000000 Z
11
+ date: 2023-05-31 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler