Skip to content

Commit 473f80b

Browse files
committed
Upgrade to ruby 3
1 parent 40324a5 commit 473f80b

File tree

5 files changed

+21
-12
lines changed

5 files changed

+21
-12
lines changed

.ruby-version

Lines changed: 0 additions & 1 deletion
This file was deleted.

Gemfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
source 'https://rubygems.org'
2-
ruby '2.7.5'
2+
ruby '3.3.0'
33
gem 'yard', git: 'https://github.com/lsegal/yard.git', branch: :main
4-
gem 'rake', '< 12'
4+
gem 'rake'
55
gem 'redcarpet'
66
gem 'pygments.rb'

Gemfile.lock

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,15 @@
11
GIT
22
remote: https://github.com/lsegal/yard.git
3-
revision: 2d197a381c5d4cc5c55b2c60fff992b31c986361
3+
revision: e833aac7a01510245dd4ae1d1d18b046c8293c2d
44
branch: main
55
specs:
6-
yard (0.9.34)
6+
yard (0.9.36)
77

88
GEM
99
remote: https://rubygems.org/
1010
specs:
11-
pygments.rb (2.4.0)
12-
rake (11.3.0)
11+
pygments.rb (3.0.0)
12+
rake (13.2.1)
1313
redcarpet (3.6.0)
1414

1515
PLATFORMS
@@ -18,12 +18,12 @@ PLATFORMS
1818

1919
DEPENDENCIES
2020
pygments.rb
21-
rake (< 12)
21+
rake
2222
redcarpet
2323
yard!
2424

2525
RUBY VERSION
26-
ruby 2.7.5p203
26+
ruby 3.3.0p0
2727

2828
BUNDLED WITH
29-
2.3.8
29+
2.5.4

Rakefile

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -411,7 +411,9 @@ def runtime_markdown(data)
411411
'# runtime.js'
412412
]
413413

414-
data.each do |comment:, body:|
414+
data.each do |hash|
415+
comment:, body: = **hash
416+
415417
markdown << "## #{extract_function_name[body.first]}"
416418
markdown << ""
417419
markdown += comment
@@ -438,7 +440,9 @@ def runtime_ruby(data)
438440

439441
ruby = []
440442

441-
data.each do |comment:, body:|
443+
data.each do |hash|
444+
comment:, body: = **hash
445+
442446
method_name, method_args = extract_function_name[body.first]
443447
next if method_name.nil? or method_name =~ /^[A-Z]/
444448

bin/build

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
#!/usr/bin/env ruby
22

33
require 'bundler/setup'
4+
require 'shellwords'
45

56
if ARGV.empty?
67
puts <<~USAGE
@@ -13,5 +14,10 @@ end
1314
ref = ARGV[0]
1415
components = ARGV[1..-1].join(' ') # defaults to components = 'lib corelib stdlib'
1516

17+
def system(*cmd)
18+
puts cmd.shelljoin
19+
super
20+
end
21+
1622
system 'bin/rake', %{REF=#{ref}}, %{COMPONENTS=#{components}}, '--trace'
1723
system 'bin/rake', 'index', %{REF=#{ref}}, '--trace'

0 commit comments

Comments
 (0)