scriptura 0.0.1 → 0.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +4 -4
- data/lib/scriptura/data.rb +1 -1
- data/lib/scriptura/scripture.rb +20 -18
- data/lib/scriptura/scripture_book.rb +1 -1
- data/lib/scriptura/scripture_chapter.rb +1 -1
- data/lib/scriptura/scripture_reference.rb +1 -1
- data/lib/scriptura/scripture_verse.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 71f2fba3eaf12626327a69e587d3fc5aaea6f8fd
|
4
|
+
data.tar.gz: a066d5c0f2ac52efd7d32b04259008a518cc4881
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 96f6bab5c39b9cc1cdd6963164981bc520b5f1fd6cef6dfd267b5013cdb21e46ee25898d8f5f52dc14d89036b2362765cc0bb1a40510fb75f0a9632a91df0d7f
|
7
|
+
data.tar.gz: b4d01e1a3838e8828a35c2bc3c9dc3cb2ef6a2752fee5ec9dafd533a9c6fd78491478ea37ea4a0f01171e04beae0587f3f8b16d217b821a6262f116c456ebd7a
|
data/README.md
CHANGED
@@ -1,4 +1,4 @@
|
|
1
|
-
|
1
|
+
|
2
2
|
[![Code Climate](https://codeclimate.com/github/gaganawhad/scriptura.png)](https://codeclimate.com/github/gaganawhad/scriptura)
|
3
3
|
|
4
4
|
This is a ruby library that provides operations related with meta information about the Bible
|
@@ -20,17 +20,17 @@ Or install it yourself as:
|
|
20
20
|
## Usage
|
21
21
|
|
22
22
|
There are four main classes in this library:
|
23
|
-
-
|
23
|
+
- Scripture
|
24
24
|
- ScriptureBook
|
25
25
|
- ScriptureChapter
|
26
26
|
- ScriptureVerse
|
27
27
|
- ScriptureReference
|
28
28
|
|
29
|
-
###
|
29
|
+
###Scripture
|
30
30
|
|
31
31
|
The way it is written, this is actually a module that encapsulates methods that scope the entire bible
|
32
32
|
```ruby
|
33
|
-
>
|
33
|
+
> Scripture.book_names
|
34
34
|
=> ["Genesis", "Exodus", "Leviticus", ... , "Revelation"]
|
35
35
|
|
36
36
|
```
|
data/lib/scriptura/data.rb
CHANGED
data/lib/scriptura/scripture.rb
CHANGED
@@ -1,25 +1,27 @@
|
|
1
|
-
module
|
2
|
-
|
3
|
-
|
4
|
-
|
5
|
-
|
1
|
+
module Scriptura
|
2
|
+
module Scripture
|
3
|
+
def self.old_testament_books
|
4
|
+
books = []
|
5
|
+
(1..39).each do |book_number|
|
6
|
+
books << ScriptureBook.new(book_number)
|
7
|
+
end
|
8
|
+
books
|
6
9
|
end
|
7
|
-
books
|
8
|
-
end
|
9
10
|
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
|
11
|
+
def self.new_testament_books
|
12
|
+
books = []
|
13
|
+
(40..66).each do |book_number|
|
14
|
+
books << ScriptureBook.new(book_number)
|
15
|
+
end
|
16
|
+
books
|
14
17
|
end
|
15
|
-
books
|
16
|
-
end
|
17
18
|
|
18
|
-
|
19
|
-
|
20
|
-
|
19
|
+
def self.books
|
20
|
+
old_testament_books + new_testament_books
|
21
|
+
end
|
21
22
|
|
22
|
-
|
23
|
-
|
23
|
+
def self.book_names
|
24
|
+
books.map(&:name)
|
25
|
+
end
|
24
26
|
end
|
25
27
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: scriptura
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Gagan Awhad
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-
|
11
|
+
date: 2013-11-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rspec
|