clavius 1.0.3 → 1.0.4
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/README.md +2 -3
- data/lib/clavius.rb +2 -0
- data/lib/clavius/calculation.rb +2 -0
- data/lib/clavius/calculation/days_from.rb +3 -1
- data/lib/clavius/configuration.rb +2 -0
- data/lib/clavius/schedule.rb +2 -0
- data/lib/clavius/time.rb +4 -2
- data/lib/clavius/version.rb +3 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: 2540cd4797d07b1609f110f8040a023584b660d81ef0b9a941802fdfe40fa5a8
|
4
|
+
data.tar.gz: aefff0235be55ebe473505a3b3c2809a516bf2e194bad7452e85c94a9ccf13bd
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 178980a8d7aa54d8e2c3cded41bc14d0f29c67482e35bbf7d38e43831fe789a2988c35a9f0df34bb7e5b6539c6f1df385a9915a31ab4686e3235cbf4d08654c5
|
7
|
+
data.tar.gz: 3713adf36c31cce474e6c6ac0eff029baa7d1eac381395715107900dac0e0d0e35e55f50bd011f2cf1afdf763885a15e26b085a1f20ccd3ef8f248bbdfdecff7
|
data/README.md
CHANGED
@@ -1,10 +1,9 @@
|
|
1
1
|
# Clavius
|
2
2
|
|
3
3
|
[![Gem Version](https://badge.fury.io/rb/clavius.svg)](http://badge.fury.io/rb/clavius)
|
4
|
-
[![Build Status](https://travis-ci.
|
4
|
+
[![Build Status](https://travis-ci.com/craiglittle/clavius.svg?branch=master)](https://travis-ci.com/craiglittle/clavius)
|
5
5
|
[![Code Climate](https://codeclimate.com/github/craiglittle/clavius/badges/gpa.svg)](https://codeclimate.com/github/craiglittle/clavius)
|
6
6
|
[![Test Coverage](https://codeclimate.com/github/craiglittle/clavius/badges/coverage.svg)](https://codeclimate.com/github/craiglittle/clavius)
|
7
|
-
[![Dependency Status](https://gemnasium.com/craiglittle/clavius.svg)](https://gemnasium.com/craiglittle/clavius)
|
8
7
|
|
9
8
|
Date calculations based on a schedule.
|
10
9
|
|
@@ -46,6 +45,6 @@ for commit messages.
|
|
46
45
|
|
47
46
|
## Copyright
|
48
47
|
|
49
|
-
Copyright (c) 2015-
|
48
|
+
Copyright (c) 2015-2018 Craig Little. See [LICENSE][license] for details.
|
50
49
|
|
51
50
|
[license]: https://github.com/craiglittle/clavius/blob/master/LICENSE
|
data/lib/clavius.rb
CHANGED
data/lib/clavius/calculation.rb
CHANGED
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module Clavius
|
2
4
|
module Calculation
|
3
5
|
class DaysFrom
|
@@ -6,7 +8,7 @@ module Clavius
|
|
6
8
|
@schedule = schedule
|
7
9
|
@number = Integer(number)
|
8
10
|
|
9
|
-
fail ArgumentError, 'negative number' if @number
|
11
|
+
fail ArgumentError, 'negative number' if @number.negative?
|
10
12
|
end
|
11
13
|
|
12
14
|
def before(origin)
|
data/lib/clavius/schedule.rb
CHANGED
data/lib/clavius/time.rb
CHANGED
@@ -1,7 +1,9 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module Clavius
|
2
4
|
module Time
|
3
5
|
WEEKDAYS = %i[sun mon tue wed thu fri sat].freeze
|
4
|
-
BIG_BANG = Date.new(-
|
5
|
-
HEAT_DEATH = Date.new(
|
6
|
+
BIG_BANG = Date.new(-100_000_000)
|
7
|
+
HEAT_DEATH = Date.new(100_000_000)
|
6
8
|
end
|
7
9
|
end
|
data/lib/clavius/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: clavius
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Craig Little
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2018-10-02 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: Date calculations based on a schedule.
|
14
14
|
email:
|
@@ -37,7 +37,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
37
37
|
requirements:
|
38
38
|
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: '2.
|
40
|
+
version: '2.3'
|
41
41
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
42
42
|
requirements:
|
43
43
|
- - ">="
|
@@ -45,7 +45,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
45
45
|
version: '0'
|
46
46
|
requirements: []
|
47
47
|
rubyforge_project:
|
48
|
-
rubygems_version: 2.6
|
48
|
+
rubygems_version: 2.7.6
|
49
49
|
signing_key:
|
50
50
|
specification_version: 4
|
51
51
|
summary: Date calculations
|