walterdavis-eeepub 0.6.2 → 0.6.3
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.
- data/VERSION +1 -1
- data/examples/simple_epub.rb +0 -1
- data/lib/eeepub/easy.rb +0 -1
- data/lib/eeepub/maker.rb +2 -3
- data/lib/eeepub/opf.rb +1 -2
- data/spec/eeepub/easy_spec.rb +0 -1
- data/spec/eeepub/maker_spec.rb +0 -5
- data/spec/eeepub/opf_spec.rb +0 -3
- metadata +6 -7
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.6.
|
1
|
+
0.6.3
|
data/examples/simple_epub.rb
CHANGED
data/lib/eeepub/easy.rb
CHANGED
data/lib/eeepub/maker.rb
CHANGED
@@ -26,7 +26,6 @@ module EeePub
|
|
26
26
|
[
|
27
27
|
:title,
|
28
28
|
:creator,
|
29
|
-
:author,
|
30
29
|
:publisher,
|
31
30
|
:date,
|
32
31
|
:language,
|
@@ -57,7 +56,7 @@ module EeePub
|
|
57
56
|
|
58
57
|
def identifier(id, options)
|
59
58
|
@identifiers ||= []
|
60
|
-
@identifiers << {:value => id, :scheme => options[:scheme]}
|
59
|
+
@identifiers << {:value => id, :scheme => options[:scheme], :id => options[:id]}
|
61
60
|
end
|
62
61
|
|
63
62
|
# @param [Proc] block the block for initialize
|
@@ -96,8 +95,8 @@ module EeePub
|
|
96
95
|
OPF.new(
|
97
96
|
:title => @titles,
|
98
97
|
:identifier => @identifiers,
|
98
|
+
:unique_identifier => 'BookId',
|
99
99
|
:creator => @creators,
|
100
|
-
:author => @authors,
|
101
100
|
:publisher => @publishers,
|
102
101
|
:date => @dates,
|
103
102
|
:language => @languages,
|
data/lib/eeepub/opf.rb
CHANGED
@@ -9,7 +9,6 @@ module EeePub
|
|
9
9
|
:description,
|
10
10
|
:relation,
|
11
11
|
:creator,
|
12
|
-
:author,
|
13
12
|
:publisher,
|
14
13
|
:rights,
|
15
14
|
:manifest,
|
@@ -71,7 +70,7 @@ module EeePub
|
|
71
70
|
builder.dc :identifier, i[:value], attrs
|
72
71
|
end
|
73
72
|
|
74
|
-
[:title, :language, :subject, :description, :relation, :creator, :
|
73
|
+
[:title, :language, :subject, :description, :relation, :creator, :publisher, :date, :rights].each do |i|
|
75
74
|
value = self.send(i)
|
76
75
|
next unless value
|
77
76
|
|
data/spec/eeepub/easy_spec.rb
CHANGED
data/spec/eeepub/maker_spec.rb
CHANGED
@@ -5,7 +5,6 @@ describe "EeePub::Maker" do
|
|
5
5
|
@maker = EeePub::Maker.new do
|
6
6
|
title 'sample'
|
7
7
|
creator 'jugyo'
|
8
|
-
author 'foo bar'
|
9
8
|
publisher 'jugyo.org'
|
10
9
|
date "2010-05-06"
|
11
10
|
language 'en'
|
@@ -27,7 +26,6 @@ describe "EeePub::Maker" do
|
|
27
26
|
|
28
27
|
it { @maker.instance_variable_get(:@titles).should == ['sample'] }
|
29
28
|
it { @maker.instance_variable_get(:@creators).should == ['jugyo'] }
|
30
|
-
it { @maker.instance_variable_get(:@authors).should == ['foo bar'] }
|
31
29
|
it { @maker.instance_variable_get(:@publishers).should == ['jugyo.org'] }
|
32
30
|
it { @maker.instance_variable_get(:@dates).should == ["2010-05-06"] }
|
33
31
|
it { @maker.instance_variable_get(:@identifiers).should == [{:value => 'http://example.com/book/foo', :scheme => 'URL'}] }
|
@@ -56,7 +54,6 @@ describe "EeePub::Maker" do
|
|
56
54
|
mock(EeePub::OPF).new(
|
57
55
|
:title => ["sample"],
|
58
56
|
:creator => ["jugyo"],
|
59
|
-
:author => ["foo bar"],
|
60
57
|
:date => ["2010-05-06"],
|
61
58
|
:language => ['en'],
|
62
59
|
:subject => ['epub sample'],
|
@@ -81,7 +78,6 @@ describe "EeePub::Maker" do
|
|
81
78
|
@maker = EeePub::Maker.new do
|
82
79
|
title 'sample'
|
83
80
|
creator 'jugyo'
|
84
|
-
author 'foo bar'
|
85
81
|
publisher 'jugyo.org'
|
86
82
|
date "2010-05-06"
|
87
83
|
language 'en'
|
@@ -109,7 +105,6 @@ describe "EeePub::Maker" do
|
|
109
105
|
mock(EeePub::OPF).new(
|
110
106
|
:title => ["sample"],
|
111
107
|
:creator => ["jugyo"],
|
112
|
-
:author => ["foo bar"],
|
113
108
|
:date => ["2010-05-06"],
|
114
109
|
:language => ['en'],
|
115
110
|
:subject => ['epub sample'],
|
data/spec/eeepub/opf_spec.rb
CHANGED
@@ -30,7 +30,6 @@ describe "EeePub::OPF" do
|
|
30
30
|
['dc:description', ''],
|
31
31
|
['dc:relation', ''],
|
32
32
|
['dc:creator', ''],
|
33
|
-
['dc:author', ''],
|
34
33
|
['dc:publisher', ''],
|
35
34
|
['dc:rights', ''],
|
36
35
|
].each do |xpath, expect|
|
@@ -118,7 +117,6 @@ describe "EeePub::OPF" do
|
|
118
117
|
:description => 'description',
|
119
118
|
:relation => 'relation',
|
120
119
|
:creator => 'creator',
|
121
|
-
:author => 'author',
|
122
120
|
:publisher => 'publisher',
|
123
121
|
:rights => 'rights'
|
124
122
|
)
|
@@ -136,7 +134,6 @@ describe "EeePub::OPF" do
|
|
136
134
|
['dc:description', 'description'],
|
137
135
|
['dc:relation', 'relation'],
|
138
136
|
['dc:creator', 'creator'],
|
139
|
-
['dc:author', 'author'],
|
140
137
|
['dc:publisher', 'publisher'],
|
141
138
|
['dc:rights', 'rights'],
|
142
139
|
].each do |xpath, expect|
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: walterdavis-eeepub
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 1
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 6
|
9
|
-
-
|
10
|
-
version: 0.6.
|
9
|
+
- 3
|
10
|
+
version: 0.6.3
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- jugyo
|
@@ -16,8 +16,7 @@ autorequire:
|
|
16
16
|
bindir: bin
|
17
17
|
cert_chain: []
|
18
18
|
|
19
|
-
date: 2011-
|
20
|
-
default_executable:
|
19
|
+
date: 2011-04-20 00:00:00 Z
|
21
20
|
dependencies:
|
22
21
|
- !ruby/object:Gem::Dependency
|
23
22
|
name: builder
|
@@ -92,7 +91,6 @@ files:
|
|
92
91
|
- spec/eeepub/opf_spec.rb
|
93
92
|
- spec/eeepub_spec.rb
|
94
93
|
- spec/spec_helper.rb
|
95
|
-
has_rdoc: true
|
96
94
|
homepage: http://github.com/walterdavis/eeepub
|
97
95
|
licenses: []
|
98
96
|
|
@@ -122,7 +120,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
122
120
|
requirements: []
|
123
121
|
|
124
122
|
rubyforge_project:
|
125
|
-
rubygems_version: 1.
|
123
|
+
rubygems_version: 1.7.2
|
126
124
|
signing_key:
|
127
125
|
specification_version: 3
|
128
126
|
summary: ePub generator
|
@@ -135,3 +133,4 @@ test_files:
|
|
135
133
|
- spec/eeepub/opf_spec.rb
|
136
134
|
- spec/eeepub_spec.rb
|
137
135
|
- spec/spec_helper.rb
|
136
|
+
has_rdoc:
|