Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.htm

## [Unreleased](https://github.com/panorama-ed/memo_wise/compare/v1.13.0...HEAD)

**Gem enhancements:** none
**Gem enhancements:**

- Fixed issue with external tools loading `memo_wise.gemspec` from different directories [[#397]](https://github.com/panorama-ed/memo_wise/pull/397))

_No breaking changes!_

Expand Down
14 changes: 6 additions & 8 deletions memo_wise.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,12 @@ Gem::Specification.new do |spec|
# because the latter only loads a file once, and so by undefining the
# `VERSION` constant we can make it difficult to access that value again
# later. For more context, see: https://github.com/panorama-ed/memo_wise/pull/370#issuecomment-2560268423
spec.version = Module.new.tap do |mod|
# NOTE: We fully qualify `Kernel` here because Rubygems defines its own
# `load` method, which is used by default when this code is executed by
# `gem build memo_wise.gemspec`. That `load` method does not support the
# optional "wrap" parameter we pass through as `mod`. For more context, see:
# https://github.com/simplecov-ruby/simplecov/issues/557#issuecomment-2630782358
Kernel.load("lib/memo_wise/version.rb", mod)
end::MemoWise::VERSION
# NOTE: We fully qualify `Kernel` here because Rubygems defines its own
# `load` method, which is used by default when this code is executed by
# `gem build memo_wise.gemspec`. That `load` method does not support the
# optional "wrap" parameter we pass through as `mod`. For more context, see:
# https://github.com/simplecov-ruby/simplecov/issues/557#issuecomment-2630782358
spec.version = Module.new.tap { |mod| Kernel.load("#{__dir__}/lib/memo_wise/version.rb", mod) }::MemoWise::VERSION
spec.summary = "The wise choice for Ruby memoization"
spec.homepage = "https://github.com/panorama-ed/memo_wise"
spec.license = "MIT"
Expand Down