mesopotamian 1
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 +7 -0
- data/.gitignore +9 -0
- data/.rspec +2 -0
- data/.travis.yml +3 -0
- data/CODE_OF_CONDUCT.md +13 -0
- data/Gemfile +4 -0
- data/LICENSE.txt +21 -0
- data/README.md +57 -0
- data/Rakefile +11 -0
- data/lib/mesopotamian.rb +231 -0
- data/lib/mesopotamian_math/conversions.rb +106 -0
- data/lib/mesopotamian_math/numerals.rb +45 -0
- data/lib/mesopotamian_math/version.rb +5 -0
- data/mesopotamian.gemspec +28 -0
- metadata +128 -0
checksums.yaml
ADDED
@@ -0,0 +1,7 @@
|
|
1
|
+
---
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 5b6e7b0269bb24152058da78f77580e03239540b
|
4
|
+
data.tar.gz: a880e3f02b605dd2d19f8f3674842a56bd419f49
|
5
|
+
SHA512:
|
6
|
+
metadata.gz: df9a6a92ec6c8a794891b30239cdb234a431d87d053ba06b4fcc58bb2492a387e85b3ca32a64121d3fdf27707bddebca385e7c50515f1796fb071230628eb754
|
7
|
+
data.tar.gz: cdc17d62a0b9fd7d2972823c87ab3b815a97823a07759db3d8efb894fe4dd5cc60dad038025bdbacdca06b9bb1f90dc3f1784fc08185e5c13359b49dfb0a0751
|
data/.gitignore
ADDED
data/.rspec
ADDED
data/.travis.yml
ADDED
data/CODE_OF_CONDUCT.md
ADDED
@@ -0,0 +1,13 @@
|
|
1
|
+
# Contributor Code of Conduct
|
2
|
+
|
3
|
+
As contributors and maintainers of this project, we pledge to respect all people who contribute through reporting issues, posting feature requests, updating documentation, submitting pull requests or patches, and other activities.
|
4
|
+
|
5
|
+
We are committed to making participation in this project a harassment-free experience for everyone, regardless of level of experience, gender, gender identity and expression, sexual orientation, disability, personal appearance, body size, race, age, or religion.
|
6
|
+
|
7
|
+
Examples of unacceptable behavior by participants include the use of sexual language or imagery, derogatory comments or personal attacks, trolling, public or private harassment, insults, or other unprofessional conduct.
|
8
|
+
|
9
|
+
Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct. Project maintainers who do not follow the Code of Conduct may be removed from the project team.
|
10
|
+
|
11
|
+
Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by opening an issue or contacting one or more of the project maintainers.
|
12
|
+
|
13
|
+
This Code of Conduct is adapted from the [Contributor Covenant](http:contributor-covenant.org), version 1.0.0, available at [http://contributor-covenant.org/version/1/0/0/](http://contributor-covenant.org/version/1/0/0/)
|
data/Gemfile
ADDED
data/LICENSE.txt
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
The MIT License (MIT)
|
2
|
+
|
3
|
+
Copyright (c) 2015 Jan Lindblom
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in
|
13
|
+
all copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
21
|
+
THE SOFTWARE.
|
data/README.md
ADDED
@@ -0,0 +1,57 @@
|
|
1
|
+
# Mesopotamian
|
2
|
+
|
3
|
+
Mesopotamian mathematics for Ruby. Version 𒁹.
|
4
|
+
|
5
|
+
Adds support for Babylonian numerals and conversions between Mesopotamian sexagesimal numbers and regular decimal integers. All the named numerals are available: 𒁹, 𒈫, 𒐈, 𒐉, 𒐊, 𒐋, 𒐌, 𒐍, 𒐎, 𒌋, 𒌋𒌋, 𒌍, 𒄭 and 𒐐.
|
6
|
+
|
7
|
+
Adds a new type: Mesopotamian. This represents sexagesimal babylonian numerals in single digit or array form as well as cuneiform string format.
|
8
|
+
|
9
|
+
[](https://drone.io/bitbucket.org/janlindblom/babylon/latest)
|
10
|
+
|
11
|
+
## Installation
|
12
|
+
|
13
|
+
Add this line to your application's Gemfile:
|
14
|
+
|
15
|
+
```ruby
|
16
|
+
gem 'mesopotamian'
|
17
|
+
```
|
18
|
+
|
19
|
+
And then execute:
|
20
|
+
|
21
|
+
$ bundle
|
22
|
+
|
23
|
+
Or install it yourself as:
|
24
|
+
|
25
|
+
$ gem install mesopotamian
|
26
|
+
|
27
|
+
## Usage
|
28
|
+
|
29
|
+
Use Mesopotamian objects to represent numeral in Mesopotamian base 60 (sexagecimals):
|
30
|
+
|
31
|
+
```ruby
|
32
|
+
num = Mesopotamian(65535)
|
33
|
+
num.to_s
|
34
|
+
=> "𒌋𒐍 𒌋𒈫 𒌋𒐊"
|
35
|
+
num.to_i
|
36
|
+
=> 65535
|
37
|
+
num.to_a
|
38
|
+
=> [18, 12, 15]
|
39
|
+
```
|
40
|
+
|
41
|
+
# Background
|
42
|
+
|
43
|
+
Most if not all of the actuals have been collected from http://it.stlawu.edu/~dmelvill/mesomath/index.html
|
44
|
+
|
45
|
+
## Development
|
46
|
+
|
47
|
+
After checking out the repo, run `bin/setup` to install dependencies. Then, run `bin/console` for an interactive prompt that will allow you to experiment.
|
48
|
+
|
49
|
+
To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release` to create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
|
50
|
+
|
51
|
+
## Contributing
|
52
|
+
|
53
|
+
1. Fork it ( https://bitbucket.org/janlindblom/babylon/fork )
|
54
|
+
2. Create your feature branch (`git checkout -b my-new-feature`)
|
55
|
+
3. Commit your changes (`git commit -am 'Add some feature'`)
|
56
|
+
4. Push to the branch (`git push origin my-new-feature`)
|
57
|
+
5. Create a new Pull Request
|
data/Rakefile
ADDED
@@ -0,0 +1,11 @@
|
|
1
|
+
require "bundler/gem_tasks"
|
2
|
+
require "yard"
|
3
|
+
require "yard/rake/yardoc_task"
|
4
|
+
require "rspec/core/rake_task"
|
5
|
+
|
6
|
+
YARD::Rake::YardocTask.new do |t|
|
7
|
+
t.files = ['lib/**/*.rb']
|
8
|
+
t.stats_options = ['--list-undoc']
|
9
|
+
end
|
10
|
+
|
11
|
+
RSpec::Core::RakeTask.new(:spec)
|
data/lib/mesopotamian.rb
ADDED
@@ -0,0 +1,231 @@
|
|
1
|
+
require "mesopotamian_math/version"
|
2
|
+
require "mesopotamian_math/numerals"
|
3
|
+
require "mesopotamian_math/conversions"
|
4
|
+
|
5
|
+
# Mesopotamian numbers
|
6
|
+
class Mesopotamian < Numeric
|
7
|
+
include Comparable
|
8
|
+
|
9
|
+
# Create a new mesopotamian numeral
|
10
|
+
# @param [Numeric,Array] num
|
11
|
+
def initialize(num)
|
12
|
+
case num
|
13
|
+
when Numeric
|
14
|
+
@i = num.to_i
|
15
|
+
when Array
|
16
|
+
sum = 0
|
17
|
+
num.reverse.each_with_index do |n,i|
|
18
|
+
sum += n * 60**i
|
19
|
+
end
|
20
|
+
@i = sum
|
21
|
+
else
|
22
|
+
raise ArgumentError.new "Cannot convert #{num}"
|
23
|
+
end
|
24
|
+
end
|
25
|
+
|
26
|
+
# Return a string representation of this Mesopotamian.
|
27
|
+
# @return [String]
|
28
|
+
def to_s
|
29
|
+
@s ||= build_string.freeze
|
30
|
+
end
|
31
|
+
|
32
|
+
# Returns an integer representation of this Mesopotamian in base 10.
|
33
|
+
# @return [Integer]
|
34
|
+
def to_i
|
35
|
+
@i
|
36
|
+
end
|
37
|
+
|
38
|
+
alias to_int to_i
|
39
|
+
|
40
|
+
def to_a
|
41
|
+
MesopotamianMath::Conversions.sexa_value @i
|
42
|
+
end
|
43
|
+
|
44
|
+
# As this is already a Mesopotamian, simply return itself.
|
45
|
+
# @return [Mesopotamian]
|
46
|
+
def to_m
|
47
|
+
self
|
48
|
+
end
|
49
|
+
|
50
|
+
alias to_sex to_m
|
51
|
+
|
52
|
+
# Returns +true+ if +num+ and this are the same type and have equal values.
|
53
|
+
# @return [Boolean]
|
54
|
+
def eql?(num)
|
55
|
+
self.class.equal?(num.class) && @i == num.to_i
|
56
|
+
end
|
57
|
+
|
58
|
+
alias == eql?
|
59
|
+
|
60
|
+
# @return [Numeric]
|
61
|
+
def hash
|
62
|
+
@i.to_hash
|
63
|
+
end
|
64
|
+
|
65
|
+
# @return [Boolean]
|
66
|
+
def zero?
|
67
|
+
@i.zero?
|
68
|
+
end
|
69
|
+
|
70
|
+
# @return [Boolean]
|
71
|
+
def nonzero?
|
72
|
+
@i.nonzero?
|
73
|
+
end
|
74
|
+
|
75
|
+
# Returns +true+ if this is an odd number.
|
76
|
+
# @return [Boolean]
|
77
|
+
def odd?
|
78
|
+
@i.odd?
|
79
|
+
end
|
80
|
+
|
81
|
+
# Returns +true+ if this is an even number.
|
82
|
+
# @return [Boolean]
|
83
|
+
def even?
|
84
|
+
@i.even?
|
85
|
+
end
|
86
|
+
|
87
|
+
# Returns +false+ if +a+ is less than zero or if +b+ is greater than zero, true otherwise.
|
88
|
+
# @return [Boolean]
|
89
|
+
def between?(a, b)
|
90
|
+
@i.between? a, b
|
91
|
+
end
|
92
|
+
|
93
|
+
# Since a Mesopotamian is an Integer, this always returns +true+.
|
94
|
+
# @return [Boolean]
|
95
|
+
def integer?
|
96
|
+
true
|
97
|
+
end
|
98
|
+
|
99
|
+
# If this is the same type as +o+, returns an array containing this and +num+.
|
100
|
+
# @return [Array<Mesopotamian>]
|
101
|
+
def coerce(o)
|
102
|
+
[Mesopotamian.new(o.to_int), self]
|
103
|
+
end
|
104
|
+
|
105
|
+
# Unary Plus—Returns the receiver's value.
|
106
|
+
# @return [Mesopotamian]
|
107
|
+
def +@
|
108
|
+
self
|
109
|
+
end
|
110
|
+
|
111
|
+
# Unary Minus—Returns the receiver's value, negated.
|
112
|
+
# @return [Mesopotamian]
|
113
|
+
def -@
|
114
|
+
Mesopotamian.new(-@i)
|
115
|
+
end
|
116
|
+
|
117
|
+
# @return [Mesopotamian]
|
118
|
+
def +(o)
|
119
|
+
op(:+, o)
|
120
|
+
end
|
121
|
+
|
122
|
+
# @return [Mesopotamian]
|
123
|
+
def -(o)
|
124
|
+
op(:-, o)
|
125
|
+
end
|
126
|
+
|
127
|
+
# @return [Mesopotamian]
|
128
|
+
def *(o)
|
129
|
+
op(:*, o)
|
130
|
+
end
|
131
|
+
|
132
|
+
# @return [Mesopotamian]
|
133
|
+
def /(o)
|
134
|
+
op(:/, o)
|
135
|
+
end
|
136
|
+
|
137
|
+
# @return [Mesopotamian]
|
138
|
+
def **(o)
|
139
|
+
op(:**, o)
|
140
|
+
end
|
141
|
+
|
142
|
+
# @return [Mesopotamian]
|
143
|
+
def <<(o)
|
144
|
+
Mesopotamian.new(@i << o.to_int)
|
145
|
+
end
|
146
|
+
|
147
|
+
# @return [Mesopotamian]
|
148
|
+
def >>(o)
|
149
|
+
Mesopotamian.new(@i >> o.to_int)
|
150
|
+
end
|
151
|
+
|
152
|
+
# @return [Mesopotamian]
|
153
|
+
def &(o)
|
154
|
+
Mesopotamian.new(@i & o.to_int)
|
155
|
+
end
|
156
|
+
|
157
|
+
# @return [Mesopotamian]
|
158
|
+
def |(o)
|
159
|
+
Mesopotamian.new(@i | o.to_int)
|
160
|
+
end
|
161
|
+
|
162
|
+
# Returns zero if this equals +other+, otherwise +nil+ is returned if the
|
163
|
+
# two values are incomparable.
|
164
|
+
# @return [Numeric]
|
165
|
+
def <=>(o)
|
166
|
+
case o
|
167
|
+
when Mesopotamian
|
168
|
+
@i <=> o.to_i
|
169
|
+
when Numeric
|
170
|
+
@i <=> o
|
171
|
+
else
|
172
|
+
a, b = o.coerce(self)
|
173
|
+
a <=> b
|
174
|
+
end rescue nil
|
175
|
+
end
|
176
|
+
|
177
|
+
# @return [Mesopotamian]
|
178
|
+
def freeze
|
179
|
+
to_m
|
180
|
+
super
|
181
|
+
end
|
182
|
+
|
183
|
+
private
|
184
|
+
|
185
|
+
def build_string
|
186
|
+
sexa = MesopotamianMath::Conversions.sexa_value @i
|
187
|
+
if (sexa.is_a?(Integer) || sexa.is_a?(Array))
|
188
|
+
return MesopotamianMath::Conversions.sexa_to_string sexa
|
189
|
+
else
|
190
|
+
# We shouldn't be able to end up here
|
191
|
+
raise TypeError.new "Something is wrong with the value #{sexa}, it's neither Integer nor Array"
|
192
|
+
end
|
193
|
+
""
|
194
|
+
end
|
195
|
+
|
196
|
+
def op(sym, o)
|
197
|
+
case o
|
198
|
+
when Mesopotamian
|
199
|
+
Mesopotamian.new(@i.send(sym, o.to_i))
|
200
|
+
when Numeric
|
201
|
+
Mesopotamian.new(@i.send(sym, o))
|
202
|
+
else
|
203
|
+
a, b = o.coerce(self)
|
204
|
+
a.send(sym, b)
|
205
|
+
end
|
206
|
+
end
|
207
|
+
|
208
|
+
end
|
209
|
+
|
210
|
+
# # Create a new mesopotamian numeral
|
211
|
+
def Mesopotamian(num)
|
212
|
+
Mesopotamian.new(num)
|
213
|
+
end
|
214
|
+
|
215
|
+
# Extensions to the Integer class
|
216
|
+
class Integer
|
217
|
+
# Convert this Integer to a Mesopotamian
|
218
|
+
def to_m
|
219
|
+
Mesopotamian.new(to_i)
|
220
|
+
end
|
221
|
+
alias to_sex to_m
|
222
|
+
end
|
223
|
+
|
224
|
+
# Extensions to the Array class
|
225
|
+
class Array
|
226
|
+
# Convert this Array to a Mesopotamian
|
227
|
+
def to_m
|
228
|
+
Mesopotamian.new(to_a)
|
229
|
+
end
|
230
|
+
alias to_sex to_m
|
231
|
+
end
|
@@ -0,0 +1,106 @@
|
|
1
|
+
require "mesopotamian_math/numerals"
|
2
|
+
|
3
|
+
module MesopotamianMath
|
4
|
+
# Conversions between decimal (base 10) and sexagesimal (base 60).
|
5
|
+
module Conversions
|
6
|
+
include Numerals
|
7
|
+
|
8
|
+
# Converts an integer into sexagecimal, array syntax.
|
9
|
+
# @param [Integer] decimal
|
10
|
+
# @return [Integer,Array]
|
11
|
+
def self.sexa_value(decimal)
|
12
|
+
raise ArgumentError.new "The argument #{decimal} is not integer" unless decimal.is_a?(Integer)
|
13
|
+
index = 0
|
14
|
+
input = decimal
|
15
|
+
result = []
|
16
|
+
while input != 0
|
17
|
+
remainder = input % 60
|
18
|
+
result.unshift remainder
|
19
|
+
input = input / 60
|
20
|
+
end
|
21
|
+
result
|
22
|
+
end
|
23
|
+
|
24
|
+
# Convert a sexagesimal number, in integer or array form, into a string
|
25
|
+
# with babylonian cuneiform numerals.
|
26
|
+
# @param [Array,Integer] numeral
|
27
|
+
# @return [String]
|
28
|
+
def self.sexa_to_string(numeral)
|
29
|
+
raise ArgumentError.new "Argument #{numeral} is neither Integer nor Array" unless (numeral.is_a?(Integer) || numeral.is_a?(Array))
|
30
|
+
n = [numeral] if numeral.is_a? Integer
|
31
|
+
n = numeral if numeral.is_a? Array
|
32
|
+
result = []
|
33
|
+
n.each do |digit|
|
34
|
+
result << babylonian_digit(digit)
|
35
|
+
end
|
36
|
+
result.join " "
|
37
|
+
end
|
38
|
+
|
39
|
+
# Translates _simple_ mesopotamian numerals into integers. Only the base set
|
40
|
+
# of named numerals are, see {Babylon::Numerals}.
|
41
|
+
# @param [String] babylonian
|
42
|
+
# @return [Integer]
|
43
|
+
def self.dec_value(babylonian)
|
44
|
+
case babylonian
|
45
|
+
when DISH then 1
|
46
|
+
when MIN then 2
|
47
|
+
when ESH then 3
|
48
|
+
when LIMMU then 4
|
49
|
+
when IA then 5
|
50
|
+
when ASH then 6
|
51
|
+
when IMIN then 7
|
52
|
+
when USSU then 8
|
53
|
+
when ILIMMU then 9
|
54
|
+
when U then 10
|
55
|
+
when UDISH then 11
|
56
|
+
when MAN then 20
|
57
|
+
when USHU then 30
|
58
|
+
when HI then 40
|
59
|
+
when NINNU then 50
|
60
|
+
when GISH then 60
|
61
|
+
when DISHU then 70
|
62
|
+
when GESU then 600
|
63
|
+
when LIM then 1000
|
64
|
+
when SHAR then 3600
|
65
|
+
end
|
66
|
+
end
|
67
|
+
|
68
|
+
private
|
69
|
+
|
70
|
+
def self.babylonian_digit(digit)
|
71
|
+
raise ArgumentError.new "Argument #{digit} is not an Integer" unless digit.is_a? Integer
|
72
|
+
case digit
|
73
|
+
when 0 then " "
|
74
|
+
when 1 then DISH
|
75
|
+
when 2 then MIN
|
76
|
+
when 3 then ESH
|
77
|
+
when 4 then LIMMU
|
78
|
+
when 5 then IA
|
79
|
+
when 6 then ASH
|
80
|
+
when 7 then IMIN
|
81
|
+
when 8 then USSU
|
82
|
+
when 9 then ILIMMU
|
83
|
+
when 10 then U
|
84
|
+
when 11 then UDISH
|
85
|
+
when 20 then MAN
|
86
|
+
when 30 then USHU
|
87
|
+
when 40 then HI
|
88
|
+
when 50 then NINNU
|
89
|
+
when 60 then GISH
|
90
|
+
when 70 then DISHU
|
91
|
+
when 600 then GESU
|
92
|
+
when 1000 then LIM
|
93
|
+
when 3600 then SHAR
|
94
|
+
else
|
95
|
+
digits = digit.to_s.chars.map{ |x| x.to_i }
|
96
|
+
place = digits.length - 1
|
97
|
+
digits.each_with_index do |d,i|
|
98
|
+
digits[i] = d * 10 ** place
|
99
|
+
place -= 1
|
100
|
+
end
|
101
|
+
digits.map{ |x| babylonian_digit x }.join ""
|
102
|
+
end
|
103
|
+
end
|
104
|
+
|
105
|
+
end
|
106
|
+
end
|
@@ -0,0 +1,45 @@
|
|
1
|
+
module MesopotamianMath
|
2
|
+
# Named regular numerals as strings
|
3
|
+
module Numerals
|
4
|
+
# diš
|
5
|
+
DISH = "𒁹"
|
6
|
+
# min
|
7
|
+
MIN = "𒈫"
|
8
|
+
# eš
|
9
|
+
ESH = "𒐈"
|
10
|
+
# limmu
|
11
|
+
LIMMU = "𒐉"
|
12
|
+
# ia
|
13
|
+
IA = "𒐊"
|
14
|
+
# aš
|
15
|
+
ASH = "𒐋"
|
16
|
+
# imin
|
17
|
+
IMIN = "𒐌"
|
18
|
+
# ussu
|
19
|
+
USSU = "𒐍"
|
20
|
+
# ilimmu
|
21
|
+
ILIMMU = "𒐎"
|
22
|
+
# u
|
23
|
+
U = "𒌋"
|
24
|
+
# u.dish
|
25
|
+
UDISH = "𒌋𒁹"
|
26
|
+
# man
|
27
|
+
MAN = "𒌋𒌋"
|
28
|
+
# ušu
|
29
|
+
USHU = "𒌍"
|
30
|
+
# hi
|
31
|
+
HI = "𒄭"
|
32
|
+
# ninnu
|
33
|
+
NINNU = "𒐐"
|
34
|
+
# giš
|
35
|
+
GISH = "𒁹"
|
36
|
+
# diš.u
|
37
|
+
DISHU = "𒁹𒌋"
|
38
|
+
# gesu
|
39
|
+
GESU = "𒌋 "
|
40
|
+
# lim
|
41
|
+
LIM = "𒌋𒐋 𒄭 "
|
42
|
+
# šar
|
43
|
+
SHAR = "𒁹 "
|
44
|
+
end
|
45
|
+
end
|
@@ -0,0 +1,28 @@
|
|
1
|
+
# coding: utf-8
|
2
|
+
lib = File.expand_path('../lib', __FILE__)
|
3
|
+
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
4
|
+
require 'mesopotamian_math/numerals'
|
5
|
+
require 'mesopotamian_math/conversions'
|
6
|
+
require 'mesopotamian_math/version'
|
7
|
+
|
8
|
+
Gem::Specification.new do |spec|
|
9
|
+
spec.name = "mesopotamian"
|
10
|
+
spec.version = MesopotamianMath::Conversions.dec_value(MesopotamianMath::VERSION).to_s
|
11
|
+
spec.authors = ["Jan Lindblom"]
|
12
|
+
spec.email = ["janlindblom@fastmail.fm"]
|
13
|
+
|
14
|
+
spec.summary = %q{Mesopotamian mathematics.}
|
15
|
+
spec.homepage = "https://bitbucket.org/janlindblom/babylon"
|
16
|
+
spec.license = "MIT"
|
17
|
+
|
18
|
+
spec.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
19
|
+
spec.bindir = "exe"
|
20
|
+
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
21
|
+
spec.require_paths = ["lib"]
|
22
|
+
|
23
|
+
spec.add_development_dependency "bundler", "~> 1.3"
|
24
|
+
spec.add_development_dependency "rake", "~> 10.0"
|
25
|
+
spec.add_development_dependency "pry", "~> 0.10.2"
|
26
|
+
spec.add_development_dependency "yard", "~> 0.8.7.6"
|
27
|
+
spec.add_development_dependency "rspec", "~> 3.3.0"
|
28
|
+
end
|
metadata
ADDED
@@ -0,0 +1,128 @@
|
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
|
+
name: mesopotamian
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: '1'
|
5
|
+
platform: ruby
|
6
|
+
authors:
|
7
|
+
- Jan Lindblom
|
8
|
+
autorequire:
|
9
|
+
bindir: exe
|
10
|
+
cert_chain: []
|
11
|
+
date: 2015-10-08 00:00:00.000000000 Z
|
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: '1.3'
|
20
|
+
type: :development
|
21
|
+
prerelease: false
|
22
|
+
version_requirements: !ruby/object:Gem::Requirement
|
23
|
+
requirements:
|
24
|
+
- - "~>"
|
25
|
+
- !ruby/object:Gem::Version
|
26
|
+
version: '1.3'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: rake
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - "~>"
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '10.0'
|
34
|
+
type: :development
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - "~>"
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '10.0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: pry
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - "~>"
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: 0.10.2
|
48
|
+
type: :development
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - "~>"
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: 0.10.2
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: yard
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - "~>"
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: 0.8.7.6
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - "~>"
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: 0.8.7.6
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: rspec
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - "~>"
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: 3.3.0
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - "~>"
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: 3.3.0
|
83
|
+
description:
|
84
|
+
email:
|
85
|
+
- janlindblom@fastmail.fm
|
86
|
+
executables: []
|
87
|
+
extensions: []
|
88
|
+
extra_rdoc_files: []
|
89
|
+
files:
|
90
|
+
- ".gitignore"
|
91
|
+
- ".rspec"
|
92
|
+
- ".travis.yml"
|
93
|
+
- CODE_OF_CONDUCT.md
|
94
|
+
- Gemfile
|
95
|
+
- LICENSE.txt
|
96
|
+
- README.md
|
97
|
+
- Rakefile
|
98
|
+
- lib/mesopotamian.rb
|
99
|
+
- lib/mesopotamian_math/conversions.rb
|
100
|
+
- lib/mesopotamian_math/numerals.rb
|
101
|
+
- lib/mesopotamian_math/version.rb
|
102
|
+
- mesopotamian.gemspec
|
103
|
+
homepage: https://bitbucket.org/janlindblom/babylon
|
104
|
+
licenses:
|
105
|
+
- MIT
|
106
|
+
metadata: {}
|
107
|
+
post_install_message:
|
108
|
+
rdoc_options: []
|
109
|
+
require_paths:
|
110
|
+
- lib
|
111
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
112
|
+
requirements:
|
113
|
+
- - ">="
|
114
|
+
- !ruby/object:Gem::Version
|
115
|
+
version: '0'
|
116
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
117
|
+
requirements:
|
118
|
+
- - ">="
|
119
|
+
- !ruby/object:Gem::Version
|
120
|
+
version: '0'
|
121
|
+
requirements: []
|
122
|
+
rubyforge_project:
|
123
|
+
rubygems_version: 2.4.5
|
124
|
+
signing_key:
|
125
|
+
specification_version: 4
|
126
|
+
summary: Mesopotamian mathematics.
|
127
|
+
test_files: []
|
128
|
+
has_rdoc:
|