fat_period 1.5.0 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: fe15db09e24f9ddf7264fdf8862ea51bacb0fb88da8b21727c44ce0c0a4f930c
4
- data.tar.gz: 0ea19cc89dfa940268938ccf2d8f3abd949e2c1a405d158410c0f928c8c6d64a
3
+ metadata.gz: 5742b6c1b70e7477cb2b8e077c3b1e5d96fc417858f618a12ad64a457df692e4
4
+ data.tar.gz: 7965192d8da3ea88002089c52dc9344cae1f75e7fab28739185b5f290c3f1bc9
5
5
  SHA512:
6
- metadata.gz: e4270dcbd82522aeb3781205e4598b52f15cc2c3b352709b500ffb6db6cd80a5691416d3a3abed2cf132fc0de8d5b05a14e934d14100c984293893cc4b3de378
7
- data.tar.gz: 82458a341811b97e30393360fc81b02acad7d4b8446ce616b7c84d237e11ec037fa85790d241c02c9874924733ac0895fd648f7b0ec3d83f8de04ccd9eaf1372
6
+ metadata.gz: 78bf26849daf793f3b2115e136599178817fd43a1a03bc2882eea408bd7995c44feb94998f22bb220afeb3c2b8270770aa7dc586736849af5f5506f6f7e1123b
7
+ data.tar.gz: dc0b08cb99a577a8fe11827e96ef1c9473a4536fe4ae0e7dd483fc7a1d1d0493a333eecbbcc8a2cd9f710d03489bc32aa4c8695b9787007dc51efddb9805e14b
data/.envrc CHANGED
@@ -1 +1,7 @@
1
1
  PATH_add .bundle/bin
2
+ PATH_add ./scripts
3
+ # Ensure that we use the development DB when in the src dir.
4
+ export DB=development
5
+ export COMPOSE_FILE=.devcontainer/docker-compose.yml
6
+ export COMPOSE_PROJECT_NAME=byr
7
+ export BOOTSNAP_CACHE_DIR=tmp/cache
@@ -0,0 +1,48 @@
1
+ name: Ruby Gem
2
+
3
+ on:
4
+ push:
5
+ branches: [ "master" ]
6
+ pull_request:
7
+ branches: [ "master" ]
8
+
9
+ jobs:
10
+ build:
11
+ name: Build + Publish
12
+ runs-on: ubuntu-latest
13
+ permissions:
14
+ contents: read
15
+ packages: write
16
+
17
+ steps:
18
+ - uses: actions/checkout@v4
19
+ - name: Set up Ruby 2.6
20
+ # To automatically get bug fixes and new Ruby versions for ruby/setup-ruby,
21
+ # change this to (see https://github.com/ruby/setup-ruby#versioning):
22
+ # uses: ruby/setup-ruby@v1
23
+ uses: ruby/setup-ruby@55283cc23133118229fd3f97f9336ee23a179fcf # v1.146.0
24
+ with:
25
+ ruby-version: 2.6.x
26
+
27
+ - name: Publish to GPR
28
+ run: |
29
+ mkdir -p $HOME/.gem
30
+ touch $HOME/.gem/credentials
31
+ chmod 0600 $HOME/.gem/credentials
32
+ printf -- "---\n:github: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials
33
+ gem build *.gemspec
34
+ gem push --KEY github --host https://rubygems.pkg.github.com/${OWNER} *.gem
35
+ env:
36
+ GEM_HOST_API_KEY: "Bearer ${{secrets.GITHUB_TOKEN}}"
37
+ OWNER: ${{ github.repository_owner }}
38
+
39
+ - name: Publish to RubyGems
40
+ run: |
41
+ mkdir -p $HOME/.gem
42
+ touch $HOME/.gem/credentials
43
+ chmod 0600 $HOME/.gem/credentials
44
+ printf -- "---\n:rubygems_api_key: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials
45
+ gem build *.gemspec
46
+ gem push *.gem
47
+ env:
48
+ GEM_HOST_API_KEY: "${{secrets.RUBYGEMS_AUTH_TOKEN}}"
data/Gemfile CHANGED
@@ -2,3 +2,15 @@ source 'https://rubygems.org'
2
2
 
3
3
  # Specify your gem's dependencies in fat_period.gemspec
4
4
  gemspec
5
+
6
+ gem 'bundler'
7
+ gem 'debug'
8
+ gem 'pry'
9
+ gem 'pry-doc'
10
+ gem 'rake'
11
+ gem 'rspec'
12
+ gem 'rubocop'
13
+ gem 'rubocop-rspec'
14
+ gem 'rubocop-performance'
15
+ gem 'rubocop-rake'
16
+ gem 'rubocop-shopify'
data/Rakefile CHANGED
@@ -1,6 +1,9 @@
1
1
  require "bundler/gem_tasks"
2
2
  require "rspec/core/rake_task"
3
3
 
4
+ require 'rubocop/rake_task'
5
+
6
+ RuboCop::RakeTask.new
4
7
  RSpec::Core::RakeTask.new(:spec)
5
8
 
6
- task :default => :spec
9
+ task :default => [:spec, :rubocop]
data/fat_period.gemspec CHANGED
@@ -1,4 +1,5 @@
1
1
  # coding: utf-8
2
+
2
3
  lib = File.expand_path('../lib', __FILE__)
3
4
  $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
5
  require 'fat_period/version'
@@ -9,10 +10,10 @@ Gem::Specification.new do |spec|
9
10
  spec.authors = ['Daniel E. Doherty']
10
11
  spec.email = ['ded@ddoherty.net']
11
12
 
12
- spec.summary = %q{Implements a Period class as a Range of Dates.}
13
+ spec.summary = 'Implements a Period class as a Range of Dates.'
13
14
  spec.homepage = 'https://github.com/ddoherty03/fat_period'
14
15
 
15
- spec.files = `git ls-files -z`.split("\x0").reject do |f|
16
+ spec.files = %x(git ls-files -z).split("\x0").reject do |f|
16
17
  f.match(%r{^(test|spec|features)/})
17
18
  end
18
19
  # Don't install any executables.
@@ -20,13 +21,5 @@ Gem::Specification.new do |spec|
20
21
  # spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
21
22
  spec.require_paths = ['lib']
22
23
 
23
- spec.add_development_dependency 'bundler'
24
- spec.add_development_dependency 'rake'
25
- spec.add_development_dependency 'rspec'
26
- spec.add_development_dependency 'debug', '>= 1.0.0'
27
- spec.add_development_dependency 'pry'
28
- spec.add_development_dependency 'pry-doc'
29
- spec.add_development_dependency 'simplecov'
30
-
31
- spec.add_runtime_dependency 'fat_core', '>= 5.1.0'
24
+ spec.add_dependency 'fat_core', '>= 5.4'
32
25
  end
@@ -1,5 +1,3 @@
1
- require 'date'
2
-
3
1
  module FatPeriod
4
2
  # An extension of Date for methods useful with respect to FatPeriod::Periods.
5
3
  module Date
@@ -20,53 +18,6 @@ module FatPeriod
20
18
  require 'fat_period'
21
19
  Period.new(beginning_of_chunk(chunk), end_of_chunk(chunk))
22
20
  end
23
-
24
- # Return a period representing a chunk containing a given Date.
25
- def day_containing
26
- Period.new(self, self)
27
- end
28
-
29
- def week_containing
30
- Period.new(self.beginning_of_week, self.end_of_week)
31
- end
32
-
33
- def biweek_containing
34
- Period.new(self.beginning_of_biweek, self.end_of_biweek)
35
- end
36
-
37
- def semimonth_containing
38
- Period.new(self.beginning_of_semimonth, self.end_of_semimonth)
39
- end
40
-
41
- def month_containing
42
- Period.new(self.beginning_of_month, self.end_of_month)
43
- end
44
-
45
- def bimonth_containing
46
- Period.new(self.beginning_of_bimonth, self.end_of_bimonth)
47
- end
48
-
49
- def quarter_containing
50
- Period.new(self.beginning_of_quarter, self.end_of_quarter)
51
- end
52
-
53
- def half_containing
54
- Period.new(self.beginning_of_half, self.end_of_half)
55
- end
56
-
57
- def year_containing
58
- Period.new(self.beginning_of_year, self.end_of_year)
59
- end
60
-
61
- def chunk_containing(chunk)
62
- raise ArgumentError, 'chunk is nil' unless chunk
63
-
64
- chunk = chunk.to_sym
65
- raise ArgumentError, "unknown chunk name: #{chunk}" unless CHUNKS.include?(chunk)
66
-
67
- method = "#{chunk}_containing".to_sym
68
- send(method, self)
69
- end
70
21
  end
71
22
  end
72
23
 
@@ -1,6 +1,5 @@
1
+ require 'active_support'
1
2
  require 'fat_core/date'
2
- require 'fat_core/range'
3
- require 'fat_core/string'
4
3
 
5
4
  # The Period class represents a range of Dates and supports a variety of
6
5
  # operations on those ranges.
@@ -27,18 +26,17 @@ class Period
27
26
  # @raise [ArgumentError] if first date is later than last date
28
27
  # @return [Period]
29
28
  def initialize(first, last)
30
- @first = Date.ensure(first).freeze
31
- @last = Date.ensure(last).freeze
29
+ @first = Date.ensure_date(first).freeze
30
+ @last = Date.ensure_date(last).freeze
32
31
  freeze
33
32
 
34
- raise ArgumentError, "Period's first date is later than its last date" if @first > @last
33
+ return unless @first > @last
34
+
35
+ raise ArgumentError, "Period's first date is later than its last date"
35
36
  end
36
37
 
37
38
  # These need to come after initialize is defined
38
39
 
39
- # Period from commercial beginning of time to today
40
- TO_DATE = Period.new(Date::BOT, Date.current)
41
-
42
40
  # Period from commercial beginning of time to commercial end of time.
43
41
  FOREVER = Period.new(Date::BOT, Date::EOT)
44
42
 
@@ -68,60 +66,35 @@ class Period
68
66
  Period.new(first, second) if first && second
69
67
  end
70
68
 
71
- PHRASE_RE = %r{\A
72
- # One or both of from and to parts
73
- (((from)?\s*(?<from_part>[-_a-z0-9]+)\s*)?
74
- (to\s+(?<to_part>[-_a-z0-9]+))?)
75
- # Wholly optional chunk part
76
- (\s+per\s+(?<chunk_part>\w+))?\z}xi
77
-
78
- private_constant :PHRASE_RE
79
-
80
- # Return an array of periods, either a single period as in `Period.parse`
81
- # from a String phrase in which a `from spec` is introduced with 'from' and,
82
- # optionally, a `to spec` is introduced with 'to', or a number of periods if
83
- # there is a 'per <chunk>' modifier. A phrase with only a `to spec` is
84
- # treated the same as one with only a from spec. If neither 'from' nor 'to'
85
- # appear in phrase, treat the whole string as a from spec.
69
+ # Return a period as in `Period.parse` from a String phrase in which the from
70
+ # spec is introduced with 'from' and, optionally, the to spec is introduced
71
+ # with 'to'. A phrase with only a to spec is treated the same as one with
72
+ # only a from spec. If neither 'from' nor 'to' appear in phrase, treat the
73
+ # whole string as a from spec.
86
74
  #
87
75
  # @example
88
- # Period.parse_phrase('from 2014-11 to 2015-3Q') #=> [Period('2014-11-01..2015-09-30')]
89
- # Period.parse_phrase('from 2014-11') #=> [Period('2014-11-01..2014-11-30')]
90
- # Period.parse_phrase('from 2015-3Q') #=> [Period('2015-09-01..2015-12-31')]
91
- # Period.parse_phrase('to 2015-3Q') #=> [Period('2015-09-01..2015-12-31')]
92
- # Period.parse_phrase('from 2015-3Q') #=> [Period('2015-09-01..2015-12-31')]
93
- # Period.parse_phrase('from 2015 per month') #=> [
94
- # Period('2015-01-01..2015-01-31'),
95
- # Period('2015-02-01..2015-02-28'),
96
- # ...
97
- # Period('2015-12-01..2015-12-31')
98
- # ]
99
- #
100
- # @param phrase [String] with 'from <spec> to <spec> [per <chunk>]'
101
- # @return [Array<Period>] translated from phrase
102
- def self.parse_phrase(phrase, partial_first: false, partial_last: false, round_up_last: false)
103
- phrase = phrase.downcase.clean
104
- mm = phrase.match(PHRASE_RE)
105
- raise ArgumentError, "invalid period phrase: `#{phrase}`" unless mm
106
-
107
- if mm[:from_part] && mm[:to_part].nil?
108
- from_part = mm[:from_part]
109
- to_part = nil
110
- elsif mm[:from_part].nil? && mm[:to_part]
111
- from_part = mm[:to_part]
112
- to_part = nil
113
- else
114
- from_part = mm[:from_part]
115
- to_part = mm[:to_part]
116
- end
117
-
118
- whole_period = parse(from_part, to_part)
119
- if mm[:chunk_part].nil?
120
- [whole_period]
76
+ # Period.parse_phrase('from 2014-11 to 2015-3Q') #=> Period('2014-11-01..2015-09-30')
77
+ # Period.parse_phrase('from 2014-11') #=> Period('2014-11-01..2014-11-30')
78
+ # Period.parse_phrase('from 2015-3Q') #=> Period('2015-09-01..2015-12-31')
79
+ # Period.parse_phrase('to 2015-3Q') #=> Period('2015-09-01..2015-12-31')
80
+ # Period.parse_phrase('2015-3Q') #=> Period('2015-09-01..2015-12-31')
81
+ #
82
+ # @param phrase [String] with 'from <spec> to <spec>'
83
+ # @return [Period] translated from phrase
84
+ def self.parse_phrase(phrase)
85
+ phrase = phrase.clean
86
+ case phrase
87
+ when /\Afrom (.*) to (.*)\z/
88
+ from_phrase = $1
89
+ to_phrase = $2
90
+ when /\Afrom (.*)\z/, /\Ato (.*)\z/
91
+ from_phrase = $1
92
+ to_phrase = nil
121
93
  else
122
- whole_period.chunks(size: mm[:chunk_part], partial_first: partial_first,
123
- partial_last: partial_last, round_up_last: round_up_last)
94
+ from_phrase = phrase
95
+ to_phrase = nil
124
96
  end
97
+ parse(from_phrase, to_phrase)
125
98
  end
126
99
 
127
100
  # @group Conversion
@@ -166,31 +139,6 @@ class Period
166
139
  end
167
140
  end
168
141
 
169
- # Convert a string or Period into a Period object, if the string is parsable
170
- # as a period.
171
- #
172
- # @example
173
- # Period.ensure('2023-1q') #=> Period 2023-01-01..2023-03-31
174
- # pd = Period.new('2016-01-01', '2016-12-31')
175
- # Period.ensure(pd) #=> pd # No effect
176
- #
177
- # @return [Period] either parsed String or same Period
178
- def self.ensure(pd)
179
- case pd
180
- when Period
181
- pd
182
- when String
183
- if pd.match?(/\s*from/i)
184
- # Ignore any chunk modifier, 'per'
185
- Period.parse_phrase(pd).first
186
- else
187
- Period.parse(pd)
188
- end
189
- else
190
- raise UserError, "can't ensure `#{pd}` of #{pd.class} is a Period"
191
- end
192
- end
193
-
194
142
  # A concise way to print out Periods for inspection as
195
143
  # 'Period(YYYY-MM-DD..YYYY-MM-DD)'.
196
144
  #
@@ -216,7 +164,7 @@ class Period
216
164
  # @param other [Period] @return [Integer] -1 if self < other; 0 if self ==
217
165
  # other; 1 if self > other
218
166
  def <=>(other)
219
- return nil unless other.is_a?(Period)
167
+ return unless other.is_a?(Period)
220
168
 
221
169
  [first, last] <=> [other.first, other.last]
222
170
  end
@@ -235,7 +183,7 @@ class Period
235
183
  end
236
184
 
237
185
  def eql?(other)
238
- return nil unless other.is_a?(Period)
186
+ return unless other.is_a?(Period)
239
187
 
240
188
  hash == other.hash
241
189
  end
@@ -250,7 +198,7 @@ class Period
250
198
 
251
199
  to_range.cover?(date)
252
200
  end
253
- alias === contains?
201
+ alias_method :===, :contains?
254
202
 
255
203
  include Enumerable
256
204
 
@@ -258,15 +206,10 @@ class Period
258
206
 
259
207
  # Yield each day in this Period.
260
208
  def each
261
- if block_given?
262
- d = first
263
- while d <= last
264
- yield d
265
- d += 1.day
266
- end
267
- self
268
- else
269
- to_enum(:each)
209
+ d = first
210
+ while d <= last
211
+ yield d
212
+ d += 1.day
270
213
  end
271
214
  end
272
215
 
@@ -284,8 +227,8 @@ class Period
284
227
  def size
285
228
  (last - first + 1).to_i
286
229
  end
287
- alias length size
288
- alias days size
230
+ alias_method :length, :size
231
+ alias_method :days, :size
289
232
 
290
233
  # Return the fractional number of months in the period. By default, use the
291
234
  # average number of days in a month, but allow the user to override the
@@ -331,8 +274,18 @@ class Period
331
274
 
332
275
  # An Array of the valid Symbols for calendar chunks plus the Symbol :irregular
333
276
  # for other periods.
334
- CHUNKS = %i[day week biweek semimonth month bimonth quarter
335
- half year irregular].freeze
277
+ CHUNKS = %i[
278
+ day
279
+ week
280
+ biweek
281
+ semimonth
282
+ month
283
+ bimonth
284
+ quarter
285
+ half
286
+ year
287
+ irregular
288
+ ].freeze
336
289
 
337
290
  CHUNK_ORDER = {}
338
291
  CHUNKS.each_with_index do |c, i|
@@ -342,13 +295,17 @@ class Period
342
295
 
343
296
  # An Array of Ranges for the number of days that can be covered by each chunk.
344
297
  CHUNK_RANGE = {
345
- day: (1..1), week: (7..7), biweek: (14..14), semimonth: (15..16),
346
- month: (28..31), bimonth: (59..62), quarter: (90..92),
347
- half: (180..183), year: (365..366)
298
+ day: (1..1),
299
+ week: (7..7),
300
+ biweek: (14..14),
301
+ semimonth: (15..16),
302
+ month: (28..31),
303
+ bimonth: (59..62),
304
+ quarter: (90..92),
305
+ half: (180..183),
306
+ year: (365..366)
348
307
  }.freeze
349
308
 
350
- private_constant :CHUNK_ORDER, :CHUNK_RANGE
351
-
352
309
  def self.chunk_cmp(chunk1, chunk2)
353
310
  CHUNK_ORDER[chunk1] <=> CHUNK_ORDER[chunk2]
354
311
  end
@@ -396,7 +353,7 @@ class Period
396
353
  chunk = chunk.to_sym
397
354
  raise ArgumentError, "unknown chunk name: #{chunk}" unless CHUNKS.include?(chunk)
398
355
 
399
- date = Date.ensure(date)
356
+ date = Date.ensure_date(date)
400
357
  method = "#{chunk}_containing".to_sym
401
358
  send(method, date)
402
359
  end
@@ -636,8 +593,8 @@ class Period
636
593
  # @param round_up_last [Boolean] allow the last period in the returned array
637
594
  # to extend beyond the end of self.
638
595
  # @return [Array<Period>] periods that subdivide self into chunks of size, `size`
639
- def chunks(size: :month, partial_first: false, partial_last: false,
640
- round_up_last: false)
596
+ def chunks(size: :month, partial_first: true, partial_last: true,
597
+ round_up_last: false)
641
598
  chunk_size = size.to_sym
642
599
  raise ArgumentError, "unknown chunk size '#{chunk_size}'" unless CHUNKS.include?(chunk_size)
643
600
 
@@ -661,7 +618,6 @@ class Period
661
618
  return result
662
619
  end
663
620
 
664
- # The first chunk
665
621
  chunk_start = first.dup
666
622
  chunk_end = chunk_start.end_of_chunk(chunk_size)
667
623
  if chunk_start.beginning_of_chunk?(chunk_size) || partial_first
@@ -670,16 +626,14 @@ class Period
670
626
  end
671
627
  chunk_start = chunk_end + 1.day
672
628
  chunk_end = chunk_start.end_of_chunk(chunk_size)
673
-
674
629
  # Add Whole chunks
675
630
  while chunk_end <= last
676
631
  result << Period.new(chunk_start, chunk_end)
677
632
  chunk_start = chunk_end + 1.day
678
633
  chunk_end = chunk_start.end_of_chunk(chunk_size)
679
634
  end
680
-
681
635
  # Possibly append the final chunk to result
682
- if chunk_start <= last
636
+ if chunk_start < last
683
637
  if round_up_last
684
638
  result << Period.new(chunk_start, chunk_end)
685
639
  elsif partial_last
@@ -772,8 +726,8 @@ class Period
772
726
  Period.new(result.first, result.last)
773
727
  end
774
728
  end
775
- alias & intersection
776
- alias narrow_to intersection
729
+ alias_method :&, :intersection
730
+ alias_method :narrow_to, :intersection
777
731
 
778
732
  # Return the Period that is the union of self with `other` or nil if
779
733
  # they neither overlap nor are contiguous
@@ -790,11 +744,11 @@ class Period
790
744
  # @return [Period, nil] self union `other`?
791
745
  def union(other)
792
746
  result = to_range.union(other.to_range)
793
- return nil if result.nil?
747
+ return if result.nil?
794
748
 
795
749
  Period.new(result.first, result.last)
796
750
  end
797
- alias + union
751
+ alias_method :+, :union
798
752
 
799
753
  # Return an array of periods that are this period excluding any overlap with
800
754
  # other. If there is no overlap, return an array with a period equal to self
@@ -812,7 +766,7 @@ class Period
812
766
  ranges = to_range.difference(other.to_range)
813
767
  ranges.each.map { |r| Period.new(r.first, r.last) }
814
768
  end
815
- alias - difference
769
+ alias_method :-, :difference
816
770
 
817
771
  # Return whether this period overlaps the `other` period. To overlap, the
818
772
  # periods must have at least one day in common.
@@ -1,3 +1,3 @@
1
1
  module FatPeriod
2
- VERSION = '1.5.0'.freeze
2
+ VERSION = '2.0.0'.freeze
3
3
  end
data/lib/fat_period.rb CHANGED
@@ -1,3 +1,9 @@
1
+ require 'date'
2
+
1
3
  require 'fat_period/version'
2
4
  require 'fat_period/date'
3
5
  require 'fat_period/period'
6
+
7
+ require 'fat_core/date'
8
+ require 'fat_core/range'
9
+ require 'fat_core/string'
metadata CHANGED
@@ -1,127 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fat_period
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.0
4
+ version: 2.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Daniel E. Doherty
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-09-08 00:00:00.000000000 Z
11
+ date: 2024-11-12 00:00:00.000000000 Z
12
12
  dependencies:
13
- - !ruby/object:Gem::Dependency
14
- name: bundler
15
- requirement: !ruby/object:Gem::Requirement
16
- requirements:
17
- - - ">="
18
- - !ruby/object:Gem::Version
19
- version: '0'
20
- type: :development
21
- prerelease: false
22
- version_requirements: !ruby/object:Gem::Requirement
23
- requirements:
24
- - - ">="
25
- - !ruby/object:Gem::Version
26
- version: '0'
27
- - !ruby/object:Gem::Dependency
28
- name: rake
29
- requirement: !ruby/object:Gem::Requirement
30
- requirements:
31
- - - ">="
32
- - !ruby/object:Gem::Version
33
- version: '0'
34
- type: :development
35
- prerelease: false
36
- version_requirements: !ruby/object:Gem::Requirement
37
- requirements:
38
- - - ">="
39
- - !ruby/object:Gem::Version
40
- version: '0'
41
- - !ruby/object:Gem::Dependency
42
- name: rspec
43
- requirement: !ruby/object:Gem::Requirement
44
- requirements:
45
- - - ">="
46
- - !ruby/object:Gem::Version
47
- version: '0'
48
- type: :development
49
- prerelease: false
50
- version_requirements: !ruby/object:Gem::Requirement
51
- requirements:
52
- - - ">="
53
- - !ruby/object:Gem::Version
54
- version: '0'
55
- - !ruby/object:Gem::Dependency
56
- name: debug
57
- requirement: !ruby/object:Gem::Requirement
58
- requirements:
59
- - - ">="
60
- - !ruby/object:Gem::Version
61
- version: 1.0.0
62
- type: :development
63
- prerelease: false
64
- version_requirements: !ruby/object:Gem::Requirement
65
- requirements:
66
- - - ">="
67
- - !ruby/object:Gem::Version
68
- version: 1.0.0
69
- - !ruby/object:Gem::Dependency
70
- name: pry
71
- requirement: !ruby/object:Gem::Requirement
72
- requirements:
73
- - - ">="
74
- - !ruby/object:Gem::Version
75
- version: '0'
76
- type: :development
77
- prerelease: false
78
- version_requirements: !ruby/object:Gem::Requirement
79
- requirements:
80
- - - ">="
81
- - !ruby/object:Gem::Version
82
- version: '0'
83
- - !ruby/object:Gem::Dependency
84
- name: pry-doc
85
- requirement: !ruby/object:Gem::Requirement
86
- requirements:
87
- - - ">="
88
- - !ruby/object:Gem::Version
89
- version: '0'
90
- type: :development
91
- prerelease: false
92
- version_requirements: !ruby/object:Gem::Requirement
93
- requirements:
94
- - - ">="
95
- - !ruby/object:Gem::Version
96
- version: '0'
97
- - !ruby/object:Gem::Dependency
98
- name: simplecov
99
- requirement: !ruby/object:Gem::Requirement
100
- requirements:
101
- - - ">="
102
- - !ruby/object:Gem::Version
103
- version: '0'
104
- type: :development
105
- prerelease: false
106
- version_requirements: !ruby/object:Gem::Requirement
107
- requirements:
108
- - - ">="
109
- - !ruby/object:Gem::Version
110
- version: '0'
111
13
  - !ruby/object:Gem::Dependency
112
14
  name: fat_core
113
15
  requirement: !ruby/object:Gem::Requirement
114
16
  requirements:
115
17
  - - ">="
116
18
  - !ruby/object:Gem::Version
117
- version: 5.1.0
19
+ version: '5.4'
118
20
  type: :runtime
119
21
  prerelease: false
120
22
  version_requirements: !ruby/object:Gem::Requirement
121
23
  requirements:
122
24
  - - ">="
123
25
  - !ruby/object:Gem::Version
124
- version: 5.1.0
26
+ version: '5.4'
125
27
  description:
126
28
  email:
127
29
  - ded@ddoherty.net
@@ -130,10 +32,9 @@ extensions: []
130
32
  extra_rdoc_files: []
131
33
  files:
132
34
  - ".envrc"
35
+ - ".github/workflows/gem-push.yml"
133
36
  - ".gitignore"
134
37
  - ".rspec"
135
- - ".ruby-version"
136
- - ".simplecov"
137
38
  - ".travis.yml"
138
39
  - Gemfile
139
40
  - LICENSE.txt
@@ -164,7 +65,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
164
65
  - !ruby/object:Gem::Version
165
66
  version: '0'
166
67
  requirements: []
167
- rubygems_version: 3.5.18
68
+ rubygems_version: 3.5.22
168
69
  signing_key:
169
70
  specification_version: 4
170
71
  summary: Implements a Period class as a Range of Dates.
data/.ruby-version DELETED
@@ -1 +0,0 @@
1
- 3.2.2
data/.simplecov DELETED
@@ -1,18 +0,0 @@
1
- # -*- mode: ruby -*-
2
-
3
- SimpleCov.start do
4
- # any custom configs like groups and filters can be here at a central place
5
- add_filter '/spec/'
6
- add_filter '/tmp/'
7
- add_group "Models", "lib/fat_period"
8
- # add_group "Core Extension", "lib/ext"
9
- # After this many seconds between runs, old coverage stats are thrown out,
10
- # so 3600 => 1 hour
11
- merge_timeout 3600
12
- # Make this true to merge rspec and cucumber coverage together
13
- use_merging false
14
- command_name 'Rspec'
15
- nocov_token 'no_cover'
16
- # Branch coverage
17
- enable_coverage :branch
18
- end