daitai 0.1.12 → 0.2.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 +4 -4
- data/.rubocop.yml +3 -0
- data/.travis.yml +5 -6
- data/Gemfile.lock +35 -19
- data/README.md +60 -0
- data/daitai.gemspec +6 -5
- data/lib/daitai.rb +4 -0
- data/lib/daitai/functions/comparator.rb +2 -0
- data/lib/daitai/functions/gt.rb +11 -0
- data/lib/daitai/functions/gte.rb +11 -0
- data/lib/daitai/functions/lt.rb +11 -0
- data/lib/daitai/functions/lte.rb +11 -0
- data/lib/daitai/version.rb +1 -1
- metadata +29 -12
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7ffc5d8dc864432b9f888e859f1f0e2c650751d23a6744ca01a9ad99ff780eb7
|
4
|
+
data.tar.gz: abedc05e3e2b4b13653ccbfb852bf881cf21e0a34dfdb725408800f04f7a9ac5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2e06a52795852aa68419bcd5b01c62486209707e14ebf66fc923b90714b8661d2527fdc1785520cc5c4b0903dc44c3b7158278e7d190549b7343a4d0c45924c8
|
7
|
+
data.tar.gz: 32149016cd9de52b6dea9c63aa725c4cf7e023efebb6e81d5f054ca7b3f64766c98ab47671ff23aef9259e4a29f5ed8f57edbbfba048983b4d6a7353bbe6b79d
|
data/.rubocop.yml
CHANGED
data/.travis.yml
CHANGED
@@ -1,12 +1,11 @@
|
|
1
1
|
sudo: false
|
2
2
|
language: ruby
|
3
3
|
rvm:
|
4
|
-
- 2.
|
5
|
-
- 2.
|
6
|
-
- 2.
|
7
|
-
- 2.
|
8
|
-
- 2.5.0
|
4
|
+
- 2.3.7
|
5
|
+
- 2.4.6
|
6
|
+
- 2.5.5
|
7
|
+
- 2.6.3
|
9
8
|
- ruby-head
|
10
9
|
before_install:
|
11
10
|
- gem update --system
|
12
|
-
- gem install bundler -v
|
11
|
+
- gem install bundler -v 2.0.2
|
data/Gemfile.lock
CHANGED
@@ -1,41 +1,57 @@
|
|
1
1
|
PATH
|
2
2
|
remote: .
|
3
3
|
specs:
|
4
|
-
daitai (0.
|
4
|
+
daitai (0.2.0)
|
5
5
|
|
6
6
|
GEM
|
7
7
|
remote: https://rubygems.org/
|
8
8
|
specs:
|
9
|
+
ast (2.4.0)
|
9
10
|
coderay (1.1.2)
|
10
11
|
diff-lcs (1.3)
|
11
|
-
|
12
|
-
|
12
|
+
jaro_winkler (1.5.3)
|
13
|
+
method_source (0.9.2)
|
14
|
+
parallel (1.17.0)
|
15
|
+
parser (2.6.3.0)
|
16
|
+
ast (~> 2.4.0)
|
17
|
+
pry (0.12.2)
|
13
18
|
coderay (~> 1.1.0)
|
14
19
|
method_source (~> 0.9.0)
|
20
|
+
rainbow (3.0.0)
|
15
21
|
rake (12.3.1)
|
16
|
-
rspec (3.
|
17
|
-
rspec-core (~> 3.
|
18
|
-
rspec-expectations (~> 3.
|
19
|
-
rspec-mocks (~> 3.
|
20
|
-
rspec-core (3.
|
21
|
-
rspec-support (~> 3.
|
22
|
-
rspec-expectations (3.
|
22
|
+
rspec (3.8.0)
|
23
|
+
rspec-core (~> 3.8.0)
|
24
|
+
rspec-expectations (~> 3.8.0)
|
25
|
+
rspec-mocks (~> 3.8.0)
|
26
|
+
rspec-core (3.8.1)
|
27
|
+
rspec-support (~> 3.8.0)
|
28
|
+
rspec-expectations (3.8.4)
|
23
29
|
diff-lcs (>= 1.2.0, < 2.0)
|
24
|
-
rspec-support (~> 3.
|
25
|
-
rspec-mocks (3.
|
30
|
+
rspec-support (~> 3.8.0)
|
31
|
+
rspec-mocks (3.8.1)
|
26
32
|
diff-lcs (>= 1.2.0, < 2.0)
|
27
|
-
rspec-support (~> 3.
|
28
|
-
rspec-support (3.
|
33
|
+
rspec-support (~> 3.8.0)
|
34
|
+
rspec-support (3.8.2)
|
35
|
+
rubocop (0.71.0)
|
36
|
+
jaro_winkler (~> 1.5.1)
|
37
|
+
parallel (~> 1.10)
|
38
|
+
parser (>= 2.6)
|
39
|
+
rainbow (>= 2.2.2, < 4.0)
|
40
|
+
ruby-progressbar (~> 1.7)
|
41
|
+
unicode-display_width (>= 1.4.0, < 1.7)
|
42
|
+
ruby-progressbar (1.10.1)
|
43
|
+
unicode-display_width (1.6.0)
|
29
44
|
|
30
45
|
PLATFORMS
|
31
46
|
ruby
|
32
47
|
|
33
48
|
DEPENDENCIES
|
34
|
-
bundler (~>
|
49
|
+
bundler (~> 2)
|
35
50
|
daitai!
|
36
|
-
pry (~> 0.
|
37
|
-
rake (~> 12.
|
38
|
-
rspec (~> 3.
|
51
|
+
pry (~> 0.12.2)
|
52
|
+
rake (~> 12.3)
|
53
|
+
rspec (~> 3.8)
|
54
|
+
rubocop (~> 0.71)
|
39
55
|
|
40
56
|
BUNDLED WITH
|
41
|
-
|
57
|
+
2.0.2
|
data/README.md
CHANGED
@@ -47,6 +47,8 @@ $ gem install daitai
|
|
47
47
|
* [false](#false-definition)
|
48
48
|
* [filter](#filter-definition)
|
49
49
|
* [flip](#flip-definition)
|
50
|
+
* [gt](#gt-definition)
|
51
|
+
* [gte](#gte-definition)
|
50
52
|
* [head](#head-definition)
|
51
53
|
* [identity](#identity-definition)
|
52
54
|
* [inc](#inc-definition)
|
@@ -55,6 +57,8 @@ $ gem install daitai
|
|
55
57
|
* [is_nil](#is_nil-definition)
|
56
58
|
* [last](#last-definition)
|
57
59
|
* [length](#length-definition)
|
60
|
+
* [lt](#lt-definition)
|
61
|
+
* [lte](#lte-definition)
|
58
62
|
* [map](#map-definition)
|
59
63
|
* [max](#max-definition)
|
60
64
|
* [mean](#mean-definition)
|
@@ -315,6 +319,34 @@ flipped_concat.("flip", "flop") # => "flopflip"
|
|
315
319
|
|
316
320
|
- - -
|
317
321
|
|
322
|
+
<h4 id='gt-definition'>
|
323
|
+
<code>a -> a -> Bool</code>
|
324
|
+
</h4>
|
325
|
+
|
326
|
+
Checks if the first argument is greater than the second one.
|
327
|
+
|
328
|
+
```ruby
|
329
|
+
Daitai.gt.(7, 5) # => true
|
330
|
+
Daitai.gt.(40, 40) # => false
|
331
|
+
Daitai.gt.(3.1, 3.14) # => false
|
332
|
+
```
|
333
|
+
|
334
|
+
- - -
|
335
|
+
|
336
|
+
<h4 id='gte-definition'>
|
337
|
+
<code>a -> a -> Bool</code>
|
338
|
+
</h4>
|
339
|
+
|
340
|
+
Checks if the first argument is greater than or equal to the second one.
|
341
|
+
|
342
|
+
```ruby
|
343
|
+
Daitai.gte.(7, 5) # => true
|
344
|
+
Daitai.gte.(40, 40) # => true
|
345
|
+
Daitai.gte.(3.1, 3.14) # => false
|
346
|
+
```
|
347
|
+
|
348
|
+
- - -
|
349
|
+
|
318
350
|
<h4 id='head-definition'>
|
319
351
|
<code>head :: [a] -> a</code>
|
320
352
|
</h4>
|
@@ -426,6 +458,34 @@ Daitai.length.("Ruby") # => 4
|
|
426
458
|
|
427
459
|
- - -
|
428
460
|
|
461
|
+
<h4 id='lt-definition'>
|
462
|
+
<code>lt :: a -> a -> Bool</code>
|
463
|
+
</h4>
|
464
|
+
|
465
|
+
Checks if the first argument is less than the second one.
|
466
|
+
|
467
|
+
```ruby
|
468
|
+
Daitai.lt.(5, 7) # => true
|
469
|
+
Daitai.lt.(40, 40) # => false
|
470
|
+
Daitai.lt.(3.14, 3.1) # => false
|
471
|
+
```
|
472
|
+
|
473
|
+
- - -
|
474
|
+
|
475
|
+
<h4 id='lte-definition'>
|
476
|
+
<code>lte :: a -> a -> Bool</code>
|
477
|
+
</h4>
|
478
|
+
|
479
|
+
Checks if the first argument is less than or equal to the second one.
|
480
|
+
|
481
|
+
```ruby
|
482
|
+
Daitai.lte.(5, 7) # => true
|
483
|
+
Daitai.lte.(40, 40) # => true
|
484
|
+
Daitai.lte.(3.14, 3.1) # => false
|
485
|
+
```
|
486
|
+
|
487
|
+
- - -
|
488
|
+
|
429
489
|
<h4 id='map-definition'>
|
430
490
|
<code>map :: (a -> b) -> [a] -> [b]</code>
|
431
491
|
</h4>
|
data/daitai.gemspec
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
# frozen_string_literal: true
|
2
2
|
|
3
|
-
lib = File.expand_path('
|
3
|
+
lib = File.expand_path('lib', __dir__)
|
4
4
|
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
5
5
|
require 'daitai/version'
|
6
6
|
|
@@ -21,8 +21,9 @@ Gem::Specification.new do |spec|
|
|
21
21
|
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
22
22
|
spec.require_paths = ['lib']
|
23
23
|
|
24
|
-
spec.add_development_dependency 'bundler', '~>
|
25
|
-
spec.add_development_dependency 'pry', '~> 0.
|
26
|
-
spec.add_development_dependency 'rake', '~> 12.
|
27
|
-
spec.add_development_dependency 'rspec', '~> 3.
|
24
|
+
spec.add_development_dependency 'bundler', '~> 2'
|
25
|
+
spec.add_development_dependency 'pry', '~> 0.12.2'
|
26
|
+
spec.add_development_dependency 'rake', '~> 12.3'
|
27
|
+
spec.add_development_dependency 'rspec', '~> 3.8'
|
28
|
+
spec.add_development_dependency 'rubocop', '~> 0.71'
|
28
29
|
end
|
data/lib/daitai.rb
CHANGED
@@ -21,6 +21,8 @@ module Daitai
|
|
21
21
|
extend False
|
22
22
|
extend Filter
|
23
23
|
extend Flip
|
24
|
+
extend Gt
|
25
|
+
extend Gte
|
24
26
|
extend Head
|
25
27
|
extend Identity
|
26
28
|
extend Inc
|
@@ -29,6 +31,8 @@ module Daitai
|
|
29
31
|
extend IsNil
|
30
32
|
extend Last
|
31
33
|
extend Length
|
34
|
+
extend Lt
|
35
|
+
extend Lte
|
32
36
|
extend Map
|
33
37
|
extend Max
|
34
38
|
extend Mean
|
data/lib/daitai/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: daitai
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Walerian Sobczak
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2019-06-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -16,56 +16,70 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '
|
19
|
+
version: '2'
|
20
20
|
type: :development
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: '
|
26
|
+
version: '2'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: pry
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
31
|
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: 0.
|
33
|
+
version: 0.12.2
|
34
34
|
type: :development
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: 0.
|
40
|
+
version: 0.12.2
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: rake
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
45
|
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version: '12.
|
47
|
+
version: '12.3'
|
48
48
|
type: :development
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
52
|
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version: '12.
|
54
|
+
version: '12.3'
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: rspec
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
59
|
- - "~>"
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version: '3.
|
61
|
+
version: '3.8'
|
62
62
|
type: :development
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
66
|
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version: '3.
|
68
|
+
version: '3.8'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: rubocop
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - "~>"
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '0.71'
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '0.71'
|
69
83
|
description:
|
70
84
|
email:
|
71
85
|
- walerian.sobczak@gmail.com
|
@@ -102,6 +116,8 @@ files:
|
|
102
116
|
- lib/daitai/functions/false.rb
|
103
117
|
- lib/daitai/functions/filter.rb
|
104
118
|
- lib/daitai/functions/flip.rb
|
119
|
+
- lib/daitai/functions/gt.rb
|
120
|
+
- lib/daitai/functions/gte.rb
|
105
121
|
- lib/daitai/functions/head.rb
|
106
122
|
- lib/daitai/functions/identity.rb
|
107
123
|
- lib/daitai/functions/inc.rb
|
@@ -110,6 +126,8 @@ files:
|
|
110
126
|
- lib/daitai/functions/is_nil.rb
|
111
127
|
- lib/daitai/functions/last.rb
|
112
128
|
- lib/daitai/functions/length.rb
|
129
|
+
- lib/daitai/functions/lt.rb
|
130
|
+
- lib/daitai/functions/lte.rb
|
113
131
|
- lib/daitai/functions/map.rb
|
114
132
|
- lib/daitai/functions/max.rb
|
115
133
|
- lib/daitai/functions/mean.rb
|
@@ -155,8 +173,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
155
173
|
- !ruby/object:Gem::Version
|
156
174
|
version: '0'
|
157
175
|
requirements: []
|
158
|
-
|
159
|
-
rubygems_version: 2.7.3
|
176
|
+
rubygems_version: 3.0.3
|
160
177
|
signing_key:
|
161
178
|
specification_version: 4
|
162
179
|
summary: A functional library for Ruby.
|