|
1 | | -lib = File.expand_path("../lib", __FILE__) |
| 1 | +# frozen_string_literal: true |
| 2 | + |
| 3 | +lib = File.expand_path("lib", __dir__) |
2 | 4 | $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib) |
3 | 5 | require "monetize/version" |
4 | | -require "English" |
5 | 6 |
|
6 | | -Gem::Specification.new do |spec| |
7 | | - spec.name = "monetize" |
8 | | - spec.version = Monetize::VERSION |
9 | | - spec.platform = Gem::Platform::RUBY |
10 | | - spec.authors = ["Shane Emmons", "Anthony Dmitriyev"] |
11 | | - spec.email = ["shane@emmons.io", "anthony.dmitriyev@gmail.com"] |
12 | | - spec.description = "A library for converting various objects into `Money` objects." |
13 | | - spec.summary = "A library for converting various objects into `Money` objects." |
14 | | - spec.homepage = "https://github.com/RubyMoney/monetize" |
15 | | - spec.license = "MIT" |
| 7 | +Gem::Specification.new do |s| |
| 8 | + s.name = "monetize" |
| 9 | + s.version = Monetize::VERSION |
| 10 | + s.platform = Gem::Platform::RUBY |
| 11 | + s.authors = ["Shane Emmons", "Anthony Dmitriyev"] |
| 12 | + s.email = ["shane@emmons.io", "anthony.dmitriyev@gmail.com"] |
| 13 | + s.homepage = "https://github.com/RubyMoney/monetize" |
| 14 | + s.summary = "A library for converting various objects into `Money` objects." |
| 15 | + s.description = "A library for converting various objects into `Money` objects." |
| 16 | + s.license = "MIT" |
16 | 17 |
|
17 | | - spec.files = `git ls-files`.split($INPUT_RECORD_SEPARATOR) |
18 | | - spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) } |
19 | | - spec.test_files = spec.files.grep(%r{^(test|spec|features)/}) |
20 | | - spec.require_paths = ["lib"] |
| 18 | + s.add_dependency "money", "~> 7.0" |
21 | 19 |
|
22 | | - spec.add_dependency "money", "~> 7.0" |
| 20 | + s.required_ruby_version = ">= 3.1" |
23 | 21 |
|
24 | | - spec.required_ruby_version = ">= 3.1" |
| 22 | + s.files = `git ls-files -z -- lib/* CHANGELOG.md LICENSE monetize.gemspec README.md`.split("\x0") |
| 23 | + s.require_paths = ["lib"] |
25 | 24 |
|
26 | | - if spec.respond_to?(:metadata) |
27 | | - spec.metadata["changelog_uri"] = "https://github.com/RubyMoney/monetize/blob/master/CHANGELOG.md" |
28 | | - spec.metadata["source_code_uri"] = "https://github.com/RubyMoney/monetize/" |
29 | | - spec.metadata["bug_tracker_uri"] = "https://github.com/RubyMoney/monetize/issues" |
30 | | - spec.metadata["rubygems_mfa_required"] = "true" |
| 25 | + if s.respond_to?(:metadata) |
| 26 | + s.metadata["changelog_uri"] = "https://github.com/RubyMoney/monetize/blob/master/CHANGELOG.md" |
| 27 | + s.metadata["source_code_uri"] = "https://github.com/RubyMoney/monetize/" |
| 28 | + s.metadata["bug_tracker_uri"] = "https://github.com/RubyMoney/monetize/issues" |
| 29 | + s.metadata["rubygems_mfa_required"] = "true" |
31 | 30 | end |
32 | 31 | end |
0 commit comments