Skip to content

Commit 2cc26d7

Browse files
authored
bundle update (#451)
for rubocop, fix one new offense in the code, and refactor the Gemfile to sort gems into dev and test groups for yard, switch from thin to puma, and adjust the header anchors for a newer version of commonmarker Signed-off-by: Cody Cutrer <[email protected]>
1 parent 1ce1853 commit 2cc26d7

File tree

7 files changed

+390
-74
lines changed

7 files changed

+390
-74
lines changed

Diff for: .known_good_references

+310
Large diffs are not rendered by default.

Diff for: Gemfile

+29-10
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,33 @@ gem "jar-dependencies", "0.4.1", platform: :jruby, require: false
99

1010
gemspec
1111

12-
gem "debug", "~> 1.9", require: false, platform: :mri
13-
gem "irb", "~> 1.15", require: false
14-
gem "nokogiri", "~> 1.15", require: false
15-
gem "rubocop-inst", "~> 1.0", require: false
16-
gem "rubocop-rake", "~> 0.6", require: false
17-
gem "rubocop-rspec", "~> 3.5", require: false
12+
group :development do
13+
gem "debug", "~> 1.9", platform: :mri
14+
gem "gem-release", "~> 2.2"
15+
gem "puma", "~> 6.6", platform: :mri
16+
gem "rackup", "~> 2.2", platform: :mri
17+
end
1818

19-
gem "coderay", "~> 1.1.3", require: false, platform: :mri
20-
gem "commonmarker", require: false, platform: :mri
21-
gem "thin", "~> 1.8.1", require: false, platform: :mri
22-
gem "yard", require: false, platform: :mri, github: "ccutrer/yard", branch: "integration"
19+
group :development, :test do
20+
gem "coderay", "~> 1.1.3", platform: :mri
21+
gem "commonmarker", "~> 2.0", platform: :mri
22+
gem "nokogiri", "~> 1.15", require: false
23+
gem "process_exists", "~> 0.2", require: false
24+
gem "rake", "~> 13.0", require: false
25+
gem "rubocop-inst", "~> 1.0", require: false
26+
gem "rubocop-rake", "~> 0.6", require: false
27+
gem "rubocop-rspec", "~> 3.5", require: false
28+
gem "tty-command", "~> 0.10", require: false
29+
gem "yaml-lint", "~> 0.0", require: false
30+
gem "yard", platform: :mri, github: "ccutrer/yard", branch: "integration", require: false
31+
end
32+
33+
group :test do
34+
gem "cucumber", "~> 9.2", require: false
35+
gem "cuke_linter", "~> 1.2", require: false
36+
gem "httparty", "~> 0.20", require: false
37+
gem "irb", "~> 1.15", require: false
38+
gem "persistent_httparty", "~> 0.1", require: false
39+
gem "rspec", "~> 3.11", require: false
40+
gem "timecop", "~> 0.9", require: false
41+
end

Diff for: Gemfile.lock

+43-41
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,9 @@
11
GIT
22
remote: https://github.com/ccutrer/yard.git
3-
revision: 4eb15c57c85628d7ef644e9307f4ad2f7d78e948
3+
revision: ebf890de3dc6bbfba3897ef80d02630915ba8b7c
44
branch: integration
55
specs:
6-
yard (0.9.28)
7-
webrick (~> 1.7.0)
6+
yard (0.9.37)
87

98
PATH
109
remote: .
@@ -17,14 +16,16 @@ PATH
1716
GEM
1817
remote: https://rubygems.org/
1918
specs:
20-
ast (2.4.2)
19+
ast (2.4.3)
2120
bigdecimal (3.1.9)
2221
bigdecimal (3.1.9-java)
2322
builder (3.3.0)
2423
coderay (1.1.3)
25-
commonmarker (0.23.10)
24+
commonmarker (2.0.1-arm64-darwin)
25+
commonmarker (2.0.1-x86_64-darwin)
26+
commonmarker (2.0.1-x86_64-linux)
2627
concurrent-ruby (1.3.5)
27-
csv (3.3.2)
28+
csv (3.3.4)
2829
cucumber (9.2.1)
2930
builder (~> 3.2)
3031
cucumber-ci-environment (> 9, < 11)
@@ -37,7 +38,7 @@ GEM
3738
mini_mime (~> 1.1)
3839
multi_test (~> 1.1)
3940
sys-uname (~> 1.2)
40-
cucumber-ci-environment (9.2.0)
41+
cucumber-ci-environment (10.0.1)
4142
cucumber-core (13.0.3)
4243
cucumber-gherkin (>= 27, < 28)
4344
cucumber-messages (>= 20, < 23)
@@ -54,29 +55,26 @@ GEM
5455
cuke_modeler (>= 1.5, < 4.0)
5556
cuke_modeler (3.24.0)
5657
cucumber-gherkin (< 33.0)
57-
daemons (1.4.1)
5858
date (3.4.1)
5959
date (3.4.1-java)
6060
debug (1.10.0)
6161
irb (~> 1.10)
6262
reline (>= 0.3.8)
63-
diff-lcs (1.6.0)
64-
eventmachine (1.2.7)
65-
eventmachine (1.2.7-java)
66-
ffi (1.17.1-arm64-darwin)
67-
ffi (1.17.1-java)
68-
ffi (1.17.1-x86_64-darwin)
69-
ffi (1.17.1-x86_64-linux-gnu)
63+
diff-lcs (1.6.1)
64+
ffi (1.17.2-arm64-darwin)
65+
ffi (1.17.2-java)
66+
ffi (1.17.2-x86_64-darwin)
67+
ffi (1.17.2-x86_64-linux-gnu)
7068
gem-release (2.2.4)
7169
gene_pool (1.5.0)
7270
concurrent-ruby (>= 1.0)
73-
httparty (0.22.0)
71+
httparty (0.23.1)
7472
csv
7573
mini_mime (>= 1.0.0)
7674
multi_xml (>= 0.5.2)
7775
io-console (0.8.0)
7876
io-console (0.8.0-java)
79-
irb (1.15.1)
77+
irb (1.15.2)
8078
pp (>= 0.6.0)
8179
rdoc (>= 4.0.0)
8280
reline (>= 0.4.2)
@@ -91,16 +89,18 @@ GEM
9189
multi_test (1.1.0)
9290
multi_xml (0.7.1)
9391
bigdecimal (~> 3.1)
94-
nokogiri (1.18.4-arm64-darwin)
92+
nio4r (2.7.4)
93+
nio4r (2.7.4-java)
94+
nokogiri (1.18.7-arm64-darwin)
9595
racc (~> 1.4)
96-
nokogiri (1.18.4-java)
96+
nokogiri (1.18.7-java)
9797
racc (~> 1.4)
98-
nokogiri (1.18.4-x86_64-darwin)
98+
nokogiri (1.18.7-x86_64-darwin)
9999
racc (~> 1.4)
100-
nokogiri (1.18.4-x86_64-linux-gnu)
100+
nokogiri (1.18.7-x86_64-linux-gnu)
101101
racc (~> 1.4)
102-
parallel (1.26.3)
103-
parser (3.3.7.1)
102+
parallel (1.27.0)
103+
parser (3.3.8.0)
104104
ast (~> 2.4.1)
105105
racc
106106
pastel (0.8.0)
@@ -113,22 +113,27 @@ GEM
113113
pp (0.6.2)
114114
prettyprint
115115
prettyprint (0.2.0)
116+
prism (1.4.0)
116117
process_exists (0.2.0)
117118
psych (5.2.3)
118119
date
119120
stringio
120121
psych (5.2.3-java)
121122
date
122123
jar-dependencies (>= 0.1.7)
124+
puma (6.6.0)
125+
nio4r (~> 2.0)
123126
racc (1.8.1)
124127
racc (1.8.1-java)
125-
rack (2.2.13)
128+
rack (3.1.13)
129+
rackup (2.2.1)
130+
rack (>= 3)
126131
rainbow (3.1.1)
127132
rake (13.2.1)
128-
rdoc (6.12.0)
133+
rdoc (6.13.1)
129134
psych (>= 4.0.0)
130135
regexp_parser (2.10.0)
131-
reline (0.6.0)
136+
reline (0.6.1)
132137
io-console (~> 0.5)
133138
rspec (3.13.0)
134139
rspec-core (~> 3.13.0)
@@ -143,25 +148,26 @@ GEM
143148
diff-lcs (>= 1.2.0, < 2.0)
144149
rspec-support (~> 3.13.0)
145150
rspec-support (3.13.2)
146-
rubocop (1.74.0)
151+
rubocop (1.75.2)
147152
json (~> 2.3)
148153
language_server-protocol (~> 3.17.0.2)
149154
lint_roller (~> 1.1.0)
150155
parallel (~> 1.10)
151156
parser (>= 3.3.0.2)
152157
rainbow (>= 2.2.2, < 4.0)
153158
regexp_parser (>= 2.9.3, < 3.0)
154-
rubocop-ast (>= 1.38.0, < 2.0)
159+
rubocop-ast (>= 1.44.0, < 2.0)
155160
ruby-progressbar (~> 1.7)
156161
unicode-display_width (>= 2.4.0, < 4.0)
157-
rubocop-ast (1.38.1)
158-
parser (>= 3.3.1.0)
159-
rubocop-inst (1.2.1)
162+
rubocop-ast (1.44.1)
163+
parser (>= 3.3.7.2)
164+
prism (~> 1.4)
165+
rubocop-inst (1.2.2)
160166
rubocop (~> 1.72, >= 1.72.1)
161167
rubocop-performance (~> 1.24)
162-
rubocop-performance (1.24.0)
168+
rubocop-performance (1.25.0)
163169
lint_roller (~> 1.1)
164-
rubocop (>= 1.72.1, < 2.0)
170+
rubocop (>= 1.75.0, < 2.0)
165171
rubocop-ast (>= 1.38.0, < 2.0)
166172
rubocop-rake (0.7.1)
167173
lint_roller (~> 1.1)
@@ -170,21 +176,16 @@ GEM
170176
lint_roller (~> 1.1)
171177
rubocop (~> 1.72, >= 1.72.1)
172178
ruby-progressbar (1.13.0)
173-
stringio (3.1.5)
179+
stringio (3.1.6)
174180
sys-uname (1.3.1)
175181
ffi (~> 1.1)
176-
thin (1.8.2)
177-
daemons (~> 1.0, >= 1.0.9)
178-
eventmachine (~> 1.0, >= 1.0.4)
179-
rack (>= 1, < 3)
180182
timecop (0.9.10)
181183
tty-color (0.6.0)
182184
tty-command (0.10.1)
183185
pastel (~> 0.8)
184186
unicode-display_width (3.1.4)
185187
unicode-emoji (~> 4.0, >= 4.0.4)
186188
unicode-emoji (4.0.4)
187-
webrick (1.7.0)
188189
yaml-lint (0.1.2)
189190

190191
PLATFORMS
@@ -195,7 +196,7 @@ PLATFORMS
195196

196197
DEPENDENCIES
197198
coderay (~> 1.1.3)
198-
commonmarker
199+
commonmarker (~> 2.0)
199200
cucumber (~> 9.2)
200201
cuke_linter (~> 1.2)
201202
debug (~> 1.9)
@@ -207,12 +208,13 @@ DEPENDENCIES
207208
openhab-scripting!
208209
persistent_httparty (~> 0.1)
209210
process_exists (~> 0.2)
211+
puma (~> 6.6)
212+
rackup (~> 2.2)
210213
rake (~> 13.0)
211214
rspec (~> 3.11)
212215
rubocop-inst (~> 1.0)
213216
rubocop-rake (~> 0.6)
214217
rubocop-rspec (~> 3.5)
215-
thin (~> 1.8.1)
216218
timecop (~> 0.9)
217219
tty-command (~> 0.10)
218220
yaml-lint (~> 0.0)

Diff for: lib/openhab/core/actions/notification.rb

+1-1
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,7 @@ def send(
9494
# @deprecated OH 4.1
9595
if Core.version >= Core::V4_2
9696
buttons ||= []
97-
buttons = buttons.map { |title, action| "#{title}=#{action}" } if buttons.is_a?(Hash)
97+
buttons = buttons.map { |button_title, action| "#{button_title}=#{action}" } if buttons.is_a?(Hash)
9898
raise ArgumentError, "buttons must contain (0..3) elements." unless (0..3).cover?(buttons.size)
9999

100100
attachment = "item:#{attachment.name}" if attachment.is_a?(Item) && attachment.image_item?

Diff for: lib/openhab/yard/html_helper.rb

+7-7
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,9 @@ def url_for_search_index
2626
end
2727

2828
def html_markup_markdown(text)
29+
# Remove the "omit from toc" comments
30+
text.gsub!(" <!-- omit from toc -->", "")
31+
2932
result = super
3033

3134
html = Nokogiri::HTML5.fragment(result)
@@ -42,13 +45,10 @@ def html_markup_markdown(text)
4245
end
4346
end
4447

45-
# wtf commonmarker, you don't generate anchors?!
46-
html.css("h1, h2, h3, h4, h5, h6").each do |header|
47-
next if header["id"]
48-
49-
id = header.text.strip.downcase.delete(%(.?"')).gsub(/[ ,]+/, "-")
50-
header["id"] = id
51-
header.prepend_child(%(<a href="##{id}" class="header-anchor">#</a>))
48+
# add the "#" mouse-over to header links
49+
html.css(Array.new(6) { |i| "h#{i + 1} > a.anchor" }.join(", ")).each do |anchor|
50+
anchor["class"] = "header-anchor"
51+
anchor.content = "#"
5252
end
5353

5454
html.to_s

Diff for: lib/openhab/yard/markdown_helper.rb

-3
Original file line numberDiff line numberDiff line change
@@ -55,9 +55,6 @@ def resolve_links(text)
5555
end
5656
end
5757

58-
# Remove the "omit from toc" comments
59-
result.gsub!(" <!-- omit from toc -->", "")
60-
6158
# re-link files in docs/*.md. They're written so they work on github without any
6259
# processing
6360
result.gsub!(%r{\[([A-Za-z0-9,. ]+)\]\(([A-Za-z0-9./-]+)\)}) do |str|

Diff for: openhab-scripting.gemspec

-12
Original file line numberDiff line numberDiff line change
@@ -25,18 +25,6 @@ Gem::Specification.new do |spec|
2525
spec.add_dependency "marcel", "~> 1.0"
2626
spec.add_dependency "method_source", "~> 1.0"
2727

28-
spec.add_development_dependency "cucumber", "~> 9.2"
29-
spec.add_development_dependency "cuke_linter", "~> 1.2"
30-
spec.add_development_dependency "gem-release", "~> 2.2"
31-
spec.add_development_dependency "httparty", "~> 0.20"
32-
spec.add_development_dependency "persistent_httparty", "~> 0.1"
33-
spec.add_development_dependency "process_exists", "~> 0.2"
34-
spec.add_development_dependency "rake", "~> 13.0"
35-
spec.add_development_dependency "rspec", "~> 3.11"
36-
spec.add_development_dependency "timecop", "~> 0.9"
37-
spec.add_development_dependency "tty-command", "~> 0.10"
38-
spec.add_development_dependency "yaml-lint", "~> 0.0"
39-
4028
spec.files = Dir["{lib}/**/*"]
4129
spec.require_paths = ["lib"]
4230
end

0 commit comments

Comments
 (0)