Skip to content

Commit 2ef8406

Browse files
authored
Merge pull request #2673 from ViewComponent/audition-round-3
Remove $PROGRAM_NAME version-print line (audition round 3)
2 parents c20e884 + bfc26d0 commit 2ef8406

4 files changed

Lines changed: 14 additions & 3 deletions

File tree

‎.audition-baseline.json‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
"class-level-state|lib/view_component/base.rb": 9,
33
"class-level-state|lib/view_component/preview.rb": 2,
44
"class-variables|lib/view_component/base.rb": 2,
5-
"global-variables|lib/view_component/version.rb": 1,
65
"runtime-class-state|/Users/joelhawksley/.local/share/mise/installs/ruby/4.0.5/lib/ruby/4.0.0/delegate.rb": 1,
76
"runtime-class-state|/Users/joelhawksley/.local/share/mise/installs/ruby/4.0.5/lib/ruby/gems/4.0.0/gems/actionpack-8.1.3/lib/action_dispatch/http/mime_type.rb": 3,
87
"runtime-class-state|/Users/joelhawksley/.local/share/mise/installs/ruby/4.0.5/lib/ruby/gems/4.0.0/gems/actionview-8.1.3/lib/action_view/gem_version.rb": 1,

‎Gemfile.lock‎

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -338,6 +338,11 @@ GEM
338338
rubocop-ast (>= 1.47.1, < 2.0)
339339
ruby-progressbar (1.13.0)
340340
rubydex (0.3.0)
341+
rubydex (0.3.0-aarch64-linux)
342+
rubydex (0.3.0-arm64-darwin)
343+
rubydex (0.3.0-x86_64-darwin)
344+
rubydex (0.3.0-x86_64-linux)
345+
rubyzip (3.3.0)
341346
rubyzip (3.4.1)
342347
securerandom (0.4.1)
343348
selenium-webdriver (4.47.0)
@@ -596,6 +601,11 @@ CHECKSUMS
596601
rubocop-performance (1.26.1) sha256=cd19b936ff196df85829d264b522fd4f98b6c89ad271fa52744a8c11b8f71834
597602
ruby-progressbar (1.13.0) sha256=80fc9c47a9b640d6834e0dc7b3c94c9df37f08cb072b7761e4a71e22cff29b33
598603
rubydex (0.3.0) sha256=902ba4546c548de6a1908acee54cf3f5b998f01c87e2ad6fbd708011774df4e5
604+
rubydex (0.3.0-aarch64-linux) sha256=a7221b71b21c5a1cdda1fbac0946ee0411a2efd94c8115cf37e4e69461d88e73
605+
rubydex (0.3.0-arm64-darwin) sha256=19f685610216e4e7f488722ac90dfbc33113a384dd16db309cf939606f4c32dd
606+
rubydex (0.3.0-x86_64-darwin) sha256=59d20c98b0bf2226f5db5bee14cf57075aa93aa0c3fa0176f496a217691ff7b6
607+
rubydex (0.3.0-x86_64-linux) sha256=dfe4026591f226b4a1b53f82f86dc14fad2e7c221ee8a5be99a0a46bf2d58b04
608+
rubyzip (3.3.0) sha256=a372fc67892a4f8c0bc8ec906b720353d8e48807a64b2e63adf99b1e3583a034
599609
rubyzip (3.4.1) sha256=0a79e745b5c25872ebd148457df5665da8530ed8626c993b01457128f173ca02
600610
securerandom (0.4.1) sha256=cc5193d414a4341b6e225f0cb4446aceca8e50d5e1888743fac16987638ea0b1
601611
selenium-webdriver (4.47.0) sha256=67f915b8223d2133bbaa13e92fd98854175394f086e2036a9eff4f5561fd69e4

‎docs/CHANGELOG.md‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,10 @@ nav_order: 6
1010

1111
## main
1212

13+
* Remove the `$PROGRAM_NAME` version-printing line from `version.rb` so the file no longer reads a global variable (unshareable across Ractors). The version is still available via `ViewComponent::VERSION::STRING`.
14+
15+
*Joel Hawksley*
16+
1317
* Fix intermittent template compilation failures where line-number offsets and annotation stripping were decided when a template object was created instead of when it was compiled, so later changes to coverage or annotation settings produced off-by-one backtraces or blank output.
1418

1519
*Joel Hawksley*

‎lib/view_component/version.rb‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,5 +10,3 @@ module VERSION
1010
STRING = [MAJOR, MINOR, PATCH, PRE].compact.join(".").freeze
1111
end
1212
end
13-
14-
puts ViewComponent::VERSION::STRING if __FILE__ == $PROGRAM_NAME

0 commit comments

Comments
 (0)