bookshop 0.0.15 → 0.0.16
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG +16 -0
- data/README.rdoc +10 -7
- data/bookshop.gemspec +3 -4
- data/lib/bookshop/commands/build.rb +8 -3
- data/lib/bookshop/generators/bookshop/app/app_generator.rb +7 -7
- data/lib/bookshop/generators/bookshop/app/templates/README.rdoc +10 -7
- data/lib/bookshop/generators/bookshop/app/templates/book/book.html.erb +7 -253
- data/lib/bookshop/generators/bookshop/app/templates/book/ch01/adding_images.html.erb +15 -0
- data/lib/bookshop/generators/bookshop/app/templates/book/ch01/ch01.html.erb +26 -0
- data/lib/bookshop/generators/bookshop/app/templates/book/ch01/dev_of_the_web.html.erb +19 -0
- data/lib/bookshop/generators/bookshop/app/templates/book/ch01/the_web.html.erb +12 -0
- data/lib/bookshop/generators/bookshop/app/templates/book/ch02/ch02.html.erb +63 -0
- data/lib/bookshop/generators/bookshop/app/templates/book/ch02/rules_and_css.html.erb +41 -0
- data/lib/bookshop/generators/bookshop/app/templates/book/cover.html.erb +27 -0
- data/lib/bookshop/generators/bookshop/app/templates/book/preface.html.erb +23 -0
- data/lib/bookshop/generators/bookshop/app/templates/book/toc.html.erb +25 -0
- data/lib/bookshop/version.rb +1 -1
- metadata +18 -28
- data/lib/bookshop/generators/bookshop/app/tools/COPYING.txt +0 -19
- data/lib/bookshop/generators/bookshop/app/tools/README.txt +0 -61
- data/lib/bookshop/generators/bookshop/app/tools/epubcheck-1.2.jar +0 -0
- data/lib/bookshop/generators/bookshop/app/tools/jigsaw_license.txt +0 -66
- data/lib/bookshop/generators/bookshop/app/tools/jing_license.txt +0 -12
- data/lib/bookshop/generators/bookshop/app/tools/kindlegen +0 -0
- data/lib/bookshop/generators/bookshop/app/tools/lib/jing.jar +0 -0
- data/lib/bookshop/generators/bookshop/app/tools/lib/saxon.jar +0 -0
data/CHANGELOG
CHANGED
@@ -1,3 +1,19 @@
|
|
1
|
+
0.0.16:
|
2
|
+
Features
|
3
|
+
Added importing <%= import(your_source_file.html.erb) %> functionality for ERB source
|
4
|
+
files, providing subtemplating, allowing for cleaner code layouts.
|
5
|
+
|
6
|
+
Documentation
|
7
|
+
Edited the example book which is generated with 'bookshop new'. The new layout
|
8
|
+
demonstrates how to utilize the <%= import(your_source_file.html.erb) %> for
|
9
|
+
including sub-files.
|
10
|
+
|
11
|
+
Removed 'Tools' subfolder including Kindlegen and Epubcheck - I will include them
|
12
|
+
in a future release. But removed for now to save bandwidth and reduce gem size.
|
13
|
+
|
14
|
+
Made 'book/' the assumed directory for source in 'bookshop build' command and
|
15
|
+
removed 'book/' prefix in all of the layout imports
|
16
|
+
|
1
17
|
0.0.15:
|
2
18
|
Features
|
3
19
|
Added ERB functionality to the book source
|
data/README.rdoc
CHANGED
@@ -1,10 +1,10 @@
|
|
1
1
|
== Welcome to bookshop
|
2
2
|
|
3
|
-
bookShop is a publishing framework for html-to-(e)book toolchain happiness and sustainable productivity. The framework is optimized to help developers quickly ramp-up, allowing them to more rapidly jump in and develop their html-to-(e)book (print-pdf, epub, mobi, etc.) flows, by favoring convention over configuration, setting them up with best practices, standards and tools from the start.
|
3
|
+
bookShop is a publishing framework for html-to-pdf/(e)book toolchain happiness and sustainable productivity. The framework is optimized to help developers quickly ramp-up, allowing them to more rapidly jump in and develop their html-to-(e)book (print-pdf, epub, mobi, etc.) flows, by favoring convention over configuration, setting them up with best practices, standards and tools from the start.
|
4
4
|
|
5
5
|
bookshop hopes to simplify the process by:
|
6
6
|
* using common developer tools like HTML, CSS, etc. to make the creation of your book comfortable and familiar, greatly reducing the learning curve for your developers, authors, agents, and other team members
|
7
|
-
* providing a Ruby Gem to make building a book from HTML as easy as '
|
7
|
+
* providing a Ruby Gem to make building a book from HTML as easy as 'gem install bookshop'
|
8
8
|
* pulling all the html-to-(e)book tools together into one place (wkhtmltopdf, kindlegen, epubcheck)
|
9
9
|
* sticking with open-source tools
|
10
10
|
* giving the developer a set of scripts to automate the redundant stuff
|
@@ -17,7 +17,6 @@ bookshop hopes to simplify the process by:
|
|
17
17
|
|
18
18
|
* Ruby v1.8.7 or v1.9.2 http://www.ruby-lang.org/en/downloads/
|
19
19
|
* Rubygems v1.3.6 http://docs.rubygems.org/read/chapter/3
|
20
|
-
* Java v1.6 http://www.java.com/
|
21
20
|
|
22
21
|
== Installation
|
23
22
|
|
@@ -62,13 +61,18 @@ All of the source documents/code/assets (yay... HTML/CSS) for your book are stor
|
|
62
61
|
|
63
62
|
or
|
64
63
|
|
64
|
+
items = [ "ball", "stick", "corgi" ]
|
65
|
+
|
65
66
|
<ul>
|
66
|
-
<%
|
67
|
-
<li><%=
|
67
|
+
<% items.each do |item| %>
|
68
|
+
<li><%= item %></li>
|
68
69
|
<% end %>
|
69
70
|
</ul>
|
70
71
|
|
71
72
|
* include other files or template structures
|
73
|
+
|
74
|
+
<%= import(your_source_file.erb.html) %>
|
75
|
+
|
72
76
|
* explore other creative ways to structure and enhance your book (we'd love to see how you are doing it)
|
73
77
|
|
74
78
|
When the book is built, your master +book/book.html.erb+ file will be compiled into the final HTML which will be used to build the book types.
|
@@ -164,5 +168,4 @@ We would like to thank:
|
|
164
168
|
* The Ruby/Rubygems Team www.ruby-lang.org/
|
165
169
|
* The Thor Team - https://github.com/wycats/thor
|
166
170
|
* Hakon Wium Lie and Bert Bos for developing the book microformat http://www.alistapart.com/articles/boom
|
167
|
-
* The WKHTMLTOPDF team http://code.google.com/p/wkhtmltopdf/
|
168
|
-
* The EPUBCHECK team http://code.google.com/p/epubcheck/
|
171
|
+
* The WKHTMLTOPDF team http://code.google.com/p/wkhtmltopdf/
|
data/bookshop.gemspec
CHANGED
@@ -9,10 +9,10 @@ Gem::Specification.new do |s|
|
|
9
9
|
s.authors = ['D.a. Thompson']
|
10
10
|
s.email = ['da@blueheadpublishing.com']
|
11
11
|
s.homepage = "http://rubygems.org/gems/bookshop"
|
12
|
-
s.summary = "A publishing framework for html-to-(e)book toolchain happiness and sustainable productivity."
|
13
|
-
s.description = "bookShop is a publishing framework for html-to-(e)book toolchain happiness and sustainable productivity.
|
12
|
+
s.summary = "A publishing framework for html-to-pdf/(e)book toolchain happiness and sustainable productivity."
|
13
|
+
s.description = "bookShop is a publishing framework for html-to-pdf/(e)book toolchain happiness and sustainable productivity.
|
14
14
|
The framework is optimized to help developers quickly ramp-up, allowing them to more rapidly
|
15
|
-
jump in and develop their html-to-(e)book (print-pdf, epub, mobi, etc.) flows, by favoring convention over
|
15
|
+
jump in and develop their html-to-pdf/(e)book (print-pdf, epub, mobi, etc.) flows, by favoring convention over
|
16
16
|
configuration, setting them up with best practices, standards and tools from the start."
|
17
17
|
s.license = "MIT"
|
18
18
|
|
@@ -22,7 +22,6 @@ Gem::Specification.new do |s|
|
|
22
22
|
|
23
23
|
|
24
24
|
s.add_dependency "thor", ">= 0.14.6"
|
25
|
-
s.add_dependency "nokogiri"
|
26
25
|
s.add_development_dependency "bundler", ">= 1.0.0"
|
27
26
|
s.add_development_dependency "rspec"
|
28
27
|
|
@@ -17,7 +17,10 @@ module Bookshop
|
|
17
17
|
build = ARGV.shift
|
18
18
|
build = aliases[build] || build
|
19
19
|
|
20
|
-
|
20
|
+
# Renders <%= import(source.html.erb) %> files with ERB
|
21
|
+
def self.import(file)
|
22
|
+
ERB.new(File.read('book/'+file)).result(binding).gsub(/\n$/,'')
|
23
|
+
end
|
21
24
|
|
22
25
|
# Define arguments and options
|
23
26
|
argument :type
|
@@ -27,6 +30,8 @@ module Bookshop
|
|
27
30
|
File.dirname(__FILE__)
|
28
31
|
end
|
29
32
|
|
33
|
+
erb = import('book.html.erb')
|
34
|
+
|
30
35
|
case build
|
31
36
|
|
32
37
|
# 'build html' creates a html version of the book
|
@@ -37,7 +42,7 @@ module Bookshop
|
|
37
42
|
|
38
43
|
puts "Generating new html from erb"
|
39
44
|
File.open('builds/html/book.html', 'a') do |f|
|
40
|
-
f << erb
|
45
|
+
f << erb
|
41
46
|
end
|
42
47
|
|
43
48
|
FileUtils.cp_r('book/css/', 'builds/html/', :verbose => true)
|
@@ -53,7 +58,7 @@ module Bookshop
|
|
53
58
|
# Generate the html from ERB
|
54
59
|
puts "Generating new html from erb"
|
55
60
|
File.open('builds/html/book.html', 'a') do |f|
|
56
|
-
f << erb
|
61
|
+
f << erb
|
57
62
|
end
|
58
63
|
|
59
64
|
# Copy over html assets
|
@@ -23,15 +23,15 @@ module Bookshop
|
|
23
23
|
end
|
24
24
|
|
25
25
|
# Adds third-party tools
|
26
|
-
def add_tools
|
27
|
-
|
28
|
-
end
|
26
|
+
# def add_tools
|
27
|
+
# directory "tools/", "#{app_path}/tools/"
|
28
|
+
# end
|
29
29
|
|
30
30
|
# Change the permissions so tools are executable
|
31
|
-
def chmod_tools
|
32
|
-
|
33
|
-
|
34
|
-
end
|
31
|
+
# def chmod_tools
|
32
|
+
# chmod "#{app_path}/tools/epubcheck-1.2.jar", 0755
|
33
|
+
# chmod "#{app_path}/tools/kindlegen", 0755
|
34
|
+
# end
|
35
35
|
|
36
36
|
protected
|
37
37
|
|
@@ -1,10 +1,10 @@
|
|
1
1
|
== Welcome to bookshop
|
2
2
|
|
3
|
-
bookShop is a publishing framework for html-to-(e)book toolchain happiness and sustainable productivity. The framework is optimized to help developers quickly ramp-up, allowing them to more rapidly jump in and develop their html-to-(e)book (print-pdf, epub, mobi, etc.) flows, by favoring convention over configuration, setting them up with best practices, standards and tools from the start.
|
3
|
+
bookShop is a publishing framework for html-to-pdf/(e)book toolchain happiness and sustainable productivity. The framework is optimized to help developers quickly ramp-up, allowing them to more rapidly jump in and develop their html-to-(e)book (print-pdf, epub, mobi, etc.) flows, by favoring convention over configuration, setting them up with best practices, standards and tools from the start.
|
4
4
|
|
5
5
|
bookshop hopes to simplify the process by:
|
6
6
|
* using common developer tools like HTML, CSS, etc. to make the creation of your book comfortable and familiar, greatly reducing the learning curve for your developers, authors, agents, and other team members
|
7
|
-
* providing a Ruby Gem to make building a book from HTML as easy as '
|
7
|
+
* providing a Ruby Gem to make building a book from HTML as easy as 'gem install bookshop'
|
8
8
|
* pulling all the html-to-(e)book tools together into one place (wkhtmltopdf, kindlegen, epubcheck)
|
9
9
|
* sticking with open-source tools
|
10
10
|
* giving the developer a set of scripts to automate the redundant stuff
|
@@ -17,7 +17,6 @@ bookshop hopes to simplify the process by:
|
|
17
17
|
|
18
18
|
* Ruby v1.8.7 or v1.9.2 http://www.ruby-lang.org/en/downloads/
|
19
19
|
* Rubygems v1.3.6 http://docs.rubygems.org/read/chapter/3
|
20
|
-
* Java v1.6 http://www.java.com/
|
21
20
|
|
22
21
|
== Installation
|
23
22
|
|
@@ -62,13 +61,18 @@ All of the source documents/code/assets (yay... HTML/CSS) for your book are stor
|
|
62
61
|
|
63
62
|
or
|
64
63
|
|
64
|
+
items = [ "ball", "stick", "corgi" ]
|
65
|
+
|
65
66
|
<ul>
|
66
|
-
<%
|
67
|
-
<li><%=
|
67
|
+
<% items.each do |item| %>
|
68
|
+
<li><%= item %></li>
|
68
69
|
<% end %>
|
69
70
|
</ul>
|
70
71
|
|
71
72
|
* include other files or template structures
|
73
|
+
|
74
|
+
<%= import(your_source_file.erb.html) %>
|
75
|
+
|
72
76
|
* explore other creative ways to structure and enhance your book (we'd love to see how you are doing it)
|
73
77
|
|
74
78
|
When the book is built, your master +book/book.html.erb+ file will be compiled into the final HTML which will be used to build the book types.
|
@@ -164,5 +168,4 @@ We would like to thank:
|
|
164
168
|
* The Ruby/Rubygems Team www.ruby-lang.org/
|
165
169
|
* The Thor Team - https://github.com/wycats/thor
|
166
170
|
* Hakon Wium Lie and Bert Bos for developing the book microformat http://www.alistapart.com/articles/boom
|
167
|
-
* The WKHTMLTOPDF team http://code.google.com/p/wkhtmltopdf/
|
168
|
-
* The EPUBCHECK team http://code.google.com/p/epubcheck/
|
171
|
+
* The WKHTMLTOPDF team http://code.google.com/p/wkhtmltopdf/
|
@@ -3,264 +3,18 @@
|
|
3
3
|
<html><head>
|
4
4
|
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
|
5
5
|
<title>Cascading Style Sheets - Designing for the Web</title>
|
6
|
-
<meta name="author" content="H�kon Wium Lie">
|
7
6
|
<link rel="stylesheet" type="text/css" href="css/stylesheet.css">
|
8
7
|
</head>
|
9
8
|
<body>
|
10
9
|
|
11
|
-
|
12
|
-
|
13
|
-
|
14
|
-
<h2>Designing for the Web</h2>
|
15
|
-
<h3>Third Edition</h3>
|
16
|
-
<p>Sample document</p>
|
17
|
-
</div>
|
10
|
+
<%= import('cover.html.erb')%>
|
11
|
+
<%= import('toc.html.erb')%>
|
12
|
+
<%= import('preface.html.erb')%>
|
18
13
|
|
19
|
-
|
20
|
-
|
21
|
-
<h2 class="no-toc">Designing for the Web</h2>
|
22
|
-
<h3 class="no-toc">Third Edition</h3>
|
23
|
-
</div>
|
14
|
+
<!-- Chapter 01 has the imports included inside of it -->
|
15
|
+
<%= import('ch01/ch01.html.erb')%>
|
24
16
|
|
25
|
-
|
26
|
-
|
27
|
-
<h2 class="no-toc">Designing for the Web</h2>
|
28
|
-
<h3 class="no-toc">Third Edition</h3>
|
29
|
-
|
30
|
-
<p class="no-toc">H�kon Wium Lie<br>Bert Bos</p>
|
31
|
-
<!-- also, the publisher's name would typically be printed here -->
|
32
|
-
</div>
|
33
|
-
|
34
|
-
<div class="imprint">
|
35
|
-
<p>Copyright � 2005 H�kon Wium Lie and Bert Bos</p>
|
36
|
-
|
37
|
-
</div>
|
38
|
-
|
39
|
-
<div class="toc" id="toc-h-1">
|
40
|
-
<h1>Table of Contents</h1>
|
41
|
-
|
42
|
-
<ul class="toc">
|
43
|
-
<li class="frontmatter"><a href="#toc-h-1">Table of Contents</a></li>
|
44
|
-
<li class="frontmatter"><a href="#preface-h-1">Preface</a></li>
|
45
|
-
<li class="chapter"><a href="#html-h-1">The Web and HTML</a>
|
46
|
-
<ul>
|
47
|
-
<li class="section"><a href="#the-web">The Web</a>
|
48
|
-
<ul>
|
49
|
-
<li class="section"><a href="#development">Development of the Web</a></li>
|
50
|
-
<li class="section"><a href="#images">Adding images</a></li>
|
51
|
-
</ul>
|
52
|
-
</li>
|
53
|
-
</ul>
|
54
|
-
</li>
|
55
|
-
<li class="chapter"><a href="#css-h-1">CSS</a>
|
56
|
-
<ul>
|
57
|
-
<li class="section"><a href="#rules">Rules and Style Sheets</a></li>
|
58
|
-
</ul>
|
59
|
-
</li>
|
60
|
-
<li class="endmatter"><a href="#index-h-1">Index</a></li>
|
61
|
-
</ul>
|
62
|
-
|
63
|
-
</div>
|
64
|
-
|
65
|
-
<div class="preface" id="preface-h-1">
|
66
|
-
<h1>Preface</h1>
|
67
|
-
|
68
|
-
<p>This is a sample document whose purpose is to show how CSS can be
|
69
|
-
used to print a book. To make the document more lively, excerpts from
|
70
|
-
the third edition of “Cascading Style Sheets — designing
|
71
|
-
for tbe Web” have been included.<span class="footnote"> That
|
72
|
-
book <em>was</em> produced using the methods described in the
|
73
|
-
document, and it was published by Addison-Wesley in 2005.</span> The
|
74
|
-
excerpts have been selected for their example values and they appear,
|
75
|
-
in this document, out of order.</p>
|
76
|
-
|
77
|
-
<p>The PDF version of this document is produced directly from the HTML
|
78
|
-
and CSS sources by the Prince formatter.</p>
|
79
|
-
|
80
|
-
<p>We encourage you to reuse the structure, markup and style sheet of
|
81
|
-
this sample document. In your own book, however, you need to provide
|
82
|
-
the content yourself.</p>
|
83
|
-
|
84
|
-
<p class="author">H�kon Wium Lie & Bert Bos<br>
|
85
|
-
Oslo/Antibes<br>November 2005</p>
|
86
|
-
|
87
|
-
</div>
|
88
|
-
|
89
|
-
<div class="chapter" id="html-h-1">
|
90
|
-
<h1 style="counter-reset: page 1">The Web and HTML</h1>
|
91
|
-
|
92
|
-
<p class="sidenote">The box <a class="pageref" href="#specs">“CSS Specifications”</a> lists the different CSS specifications.</p>
|
93
|
-
|
94
|
-
<p>Cascading Style Sheets (CSS) represent a major breakthrough in
|
95
|
-
how Web-page designers work by expanding their ability to
|
96
|
-
control the appearance of Web pages, which are the documents
|
97
|
-
that people publish on the Web.</p>
|
98
|
-
|
99
|
-
<p>For the first few years after the World Wide Web (the Web) was
|
100
|
-
created in 1990, people who wanted to put pages on the Web had
|
101
|
-
little control over what those pages looked like. In the
|
102
|
-
beginning, authors could only specify structural aspects of
|
103
|
-
their pages (for example, that some piece of text would be a
|
104
|
-
heading or some other piece would be straight text). Also,
|
105
|
-
there were ways to make text bold or italic, among a few other
|
106
|
-
effects, but that's where their control ended.</p>
|
107
|
-
|
108
|
-
<div class="section" id="the-web">
|
109
|
-
<h2>The Web</h2>
|
110
|
-
|
111
|
-
<p>The Web is a vast collection of documents on the <dfn id="dfn-internet">Internet</dfn> that are linked together via
|
112
|
-
hyperlinks. The Internet consists of millions of computers worldwide
|
113
|
-
that communicate electronically. A <dfn id="dfn-hyperlink">hyperlink</dfn> is a predefined link between two
|
114
|
-
documents. The hyperlinks allow a user to access documents on various
|
115
|
-
Web servers without concern for where they are located. A <dfn id="dfn-web-server">Web server</dfn> is a computer on the Internet
|
116
|
-
that serves out Web pages on request. From a document on a Web server
|
117
|
-
in California, the user is just one mouse click away from a document
|
118
|
-
that is stored, perhaps, on a Web server in France. Hyperlinks are
|
119
|
-
integral to the Web. Without them, there would be no Web.</p>
|
120
|
-
|
121
|
-
|
122
|
-
<div class="section" id="development">
|
123
|
-
<h3>Development of the Web</h3>
|
124
|
-
|
125
|
-
<p>The Web was invented around 1990 by Tim Berners-Lee with
|
126
|
-
Robert Cailliau as a close ally. Both of them were then
|
127
|
-
working at <dfn id="dfn-cern">CERN</dfn>, which is the European Laboratory for Particle
|
128
|
-
Physics. Tim is a graduate of Oxford University and a
|
129
|
-
long-time computer and software expert, and is now the director
|
130
|
-
of the <dfn id="dfn-w3c">World Wide Web Consortium (W3C)</dfn>, an organization that
|
131
|
-
coordinates the development of the Web. He also is a
|
132
|
-
principal research scientist at Massachusetts Institute of
|
133
|
-
Technology's Laboratory for Computer Science and Artificial
|
134
|
-
Intelligence (MIT CSAIL). Robert is a 30-year veteran at
|
135
|
-
CERN, where he still works. Robert organized the
|
136
|
-
first Web conference in Geneva in 1993. Both Tim and Robert
|
137
|
-
were awarded the ACM Software System Award in 1995 because
|
138
|
-
of their work on the Web.</p>
|
139
|
-
</div>
|
140
|
-
</div>
|
141
|
-
|
142
|
-
|
143
|
-
<div class="section" id="images">
|
144
|
-
<h3>Adding images</h3>
|
145
|
-
|
146
|
-
<p>Images proliferate on the Web. It wasn't until the Mosaic browser
|
147
|
-
added support for images in 1993 that a critical mass of people
|
148
|
-
realized the potential of the Web. You can add images to your
|
149
|
-
documents with the <span class="element">img</span> element –
|
150
|
-
<span class="element">img</span> is short for image.</p>
|
151
|
-
|
152
|
-
<p>When the image is ready, the page looks like <a class="figref" href="#fig-loaded">this figure</a>.</p>
|
153
|
-
|
154
|
-
<div class="figure" id="fig-loaded">
|
155
|
-
<p class="caption">The image has been loaded.</p>
|
156
|
-
<p class="art"><img alt="[image]" src="images/html-18.png" style="width: 100%;"></p>
|
157
|
-
</div>
|
158
|
-
|
159
|
-
</div>
|
160
|
-
</div>
|
161
|
-
|
162
|
-
<div class="chapter" id="css-h-1">
|
163
|
-
<h1>CSS</h1>
|
164
|
-
|
165
|
-
<p class="sidenote">HTML is the most popular document format on the
|
166
|
-
Web, and it is used in most of the examples in this book.</p>
|
167
|
-
|
168
|
-
<p>As we explained in <a class="chapref" href="http://people.opera.com/howcome/2005/ala/html-h-1"><q>The Web and HTML,</q></a>
|
169
|
-
HTML elements enable Web-page designers to
|
170
|
-
mark up a document's structure. The HTML specification lists
|
171
|
-
guidelines on how browsers should display these elements. For example,
|
172
|
-
you can be reasonably sure that the contents of a <span class="element">strong</span> element will be displayed as boldfaced.
|
173
|
-
Also, you can pretty much trust that most browsers will display the
|
174
|
-
content of an <span class="element">h1</span> element using a big font
|
175
|
-
size – at least bigger than the <span class="element">p</span>
|
176
|
-
element and bigger than the <span class="element">h2</span> element.
|
177
|
-
But beyond trust and hope, you don't have any control over your text's
|
178
|
-
appearance.</p>
|
179
|
-
|
180
|
-
<div class="sidebar" id="specs">
|
181
|
-
<h2 class="no-toc">CSS specifications</h2>
|
182
|
-
|
183
|
-
<p>Cascading Style Sheets is formally described in three W3C
|
184
|
-
specifications: CSS1, CSS2, and CSS 2.1. (As discussed in the
|
185
|
-
previous chapter, W3C is the organization that coordinates the
|
186
|
-
technical development of the Web.) The first specification, CSS1,
|
187
|
-
was issued in December 1996 and describes a simple style sheet
|
188
|
-
language mostly for screen-based presentations. CSS1 has around 50
|
189
|
-
properties (for example, <span class="property">color</span> and
|
190
|
-
<span class="property">font-size</span>). CSS2 was finalized in May
|
191
|
-
1998 and builds on CSS1. CSS2 includes all CSS1 properties and adds
|
192
|
-
around 70 of its own, such as properties to describe aural
|
193
|
-
presentations and page breaks.</p>
|
194
|
-
|
195
|
-
<p>CSS 2.1 is the most recent specification published by W3C. It
|
196
|
-
adds some new features, but CSS 2.1 is mostly a scaled-down version
|
197
|
-
of CSS2. CSS2 was an ambitious attempt to describe functionality,
|
198
|
-
which Web authors had requested. However, not all the functionality
|
199
|
-
is reliably supported by all browsers. CSS 2.1 is a specification
|
200
|
-
that describes the parts that <em>are</em> supported by two or
|
201
|
-
more browsers. Because CSS 2.1 is similar to CSS2, the
|
202
|
-
specification was given a minor version number (that is, 2.1)
|
203
|
-
rather than a major number (such as CSS3).</p>
|
204
|
-
</div>
|
205
|
-
|
206
|
-
|
207
|
-
<div class="section" id="rules">
|
208
|
-
<h2>Rules and Style Sheets</h2>
|
209
|
-
|
210
|
-
<p>You can create style sheets in two ways. You can either use a
|
211
|
-
normal text editor and write the style sheets <q>by hand</q> or you
|
212
|
-
can use a dedicated tool – for example, a Web authoring tool.
|
213
|
-
The dedicated tools enable you to create style sheets without learning
|
214
|
-
the syntax of the CSS language. However, in many cases, the designer
|
215
|
-
wants to tweak the style sheet by hand afterwards, so we recommend
|
216
|
-
that you learn to write and edit CSS by hand. Let's get started! Here
|
217
|
-
is a simple example:</p>
|
218
|
-
|
219
|
-
<pre class="CSS">h1 { color: green }
|
220
|
-
</pre>
|
221
|
-
|
222
|
-
<p>This code is a simple CSS rule that contains one rule. A <dfn id="dfn-rule">rule</dfn> is a statement about one stylistic aspect of
|
223
|
-
one or more elements. A <dfn id="dfn-style-sheet">style sheet</dfn> is
|
224
|
-
a set of one or more rules that apply to an HTML document. This rule
|
225
|
-
sets the color of all first-level headings (<span class="element">h1</span>).</p>
|
226
|
-
|
227
|
-
|
228
|
-
<div class="table">
|
229
|
-
<p class="caption">HTML extension elements and their CSS equivalent.</p>
|
230
|
-
<table class="lined">
|
231
|
-
<thead>
|
232
|
-
<tr><th>Element</th><th>CSS equivalent</th></tr>
|
233
|
-
</thead>
|
234
|
-
<tbody>
|
235
|
-
<tr><td><code><tt></code></td>
|
236
|
-
<td><span class="css">font-family: monospace</span></td></tr>
|
237
|
-
<tr><td><code><i></code></td>
|
238
|
-
<td><span class="css">font-style: italic</span></td></tr>
|
239
|
-
<tr><td><code><b></code></td>
|
240
|
-
<td><span class="css">font-weight: bold</span></td></tr>
|
241
|
-
<tr><td><code><u></code></td>
|
242
|
-
<td><span class="css">text-decoration: underline</span></td></tr>
|
243
|
-
</tbody>
|
244
|
-
</table>
|
245
|
-
</div>
|
246
|
-
|
247
|
-
</div>
|
248
|
-
</div>
|
249
|
-
|
250
|
-
<div class="index" id="index-h-1">
|
251
|
-
<h1>Index</h1>
|
252
|
-
|
253
|
-
<ul class="index">
|
254
|
-
<li><a href="#dfn-cern">CERN</a></li>
|
255
|
-
<li><a href="#dfn-internet">Internet</a></li>
|
256
|
-
<li><a href="#dfn-hyperlink">hyperlink</a></li>
|
257
|
-
<li><a href="#dfn-rule">rule</a></li>
|
258
|
-
<li><a href="#dfn-style-sheet">style sheet</a></li>
|
259
|
-
<li><a href="#dfn-w3c">W3C</a></li>
|
260
|
-
<li><a href="#dfn-web-server">Web server</a></li>
|
261
|
-
<li><a href="#dfn-w3c">World Wide Web Consortium</a></li>
|
262
|
-
</ul>
|
263
|
-
|
264
|
-
</div>
|
17
|
+
<!-- Chapter 01 has the imports included inside of it -->
|
18
|
+
<%= import('ch02/ch02.html.erb')%>
|
265
19
|
|
266
20
|
</body></html>
|
@@ -0,0 +1,15 @@
|
|
1
|
+
<div class="section" id="images">
|
2
|
+
<h3>Adding images</h3>
|
3
|
+
|
4
|
+
<p>Images proliferate on the Web. It wasn't until the Mosaic browser
|
5
|
+
added support for images in 1993 that a critical mass of people
|
6
|
+
realized the potential of the Web. You can add images to your
|
7
|
+
documents with the <span class="element">img</span> element –
|
8
|
+
<span class="element">img</span> is short for image.</p>
|
9
|
+
|
10
|
+
<p>When the image is ready, the page looks like <a class="figref" href="#fig-loaded">this figure</a>.</p>
|
11
|
+
|
12
|
+
<div class="figure" id="fig-loaded">
|
13
|
+
<p class="caption">The image has been loaded.</p>
|
14
|
+
<p class="art"><img alt="[image]" src="images/html-18.png" style="width: 100%;"></p>
|
15
|
+
</div>
|
@@ -0,0 +1,26 @@
|
|
1
|
+
<div class="chapter" id="html-h-1">
|
2
|
+
<h1 style="counter-reset: page 1">The Web and HTML</h1>
|
3
|
+
|
4
|
+
<p class="sidenote">The box <a class="pageref" href="#specs">“CSS Specifications”</a> lists the different CSS specifications.</p>
|
5
|
+
|
6
|
+
<p>Cascading Style Sheets (CSS) represent a major breakthrough in
|
7
|
+
how Web-page designers work by expanding their ability to
|
8
|
+
control the appearance of Web pages, which are the documents
|
9
|
+
that people publish on the Web.</p>
|
10
|
+
|
11
|
+
<p>For the first few years after the World Wide Web (the Web) was
|
12
|
+
created in 1990, people who wanted to put pages on the Web had
|
13
|
+
little control over what those pages looked like. In the
|
14
|
+
beginning, authors could only specify structural aspects of
|
15
|
+
their pages (for example, that some piece of text would be a
|
16
|
+
heading or some other piece would be straight text). Also,
|
17
|
+
there were ways to make text bold or italic, among a few other
|
18
|
+
effects, but that's where their control ended.</p>
|
19
|
+
|
20
|
+
<%= import('ch01/the_web.html.erb')%>
|
21
|
+
<%= import('ch01/dev_of_the_web.html.erb')%>
|
22
|
+
<%= import('ch01/adding_images.html.erb')%>
|
23
|
+
|
24
|
+
|
25
|
+
</div>
|
26
|
+
</div>
|
@@ -0,0 +1,19 @@
|
|
1
|
+
<div class="section" id="development">
|
2
|
+
<h3>Development of the Web</h3>
|
3
|
+
|
4
|
+
<p>The Web was invented around 1990 by Tim Berners-Lee with
|
5
|
+
Robert Cailliau as a close ally. Both of them were then
|
6
|
+
working at <dfn id="dfn-cern">CERN</dfn>, which is the European Laboratory for Particle
|
7
|
+
Physics. Tim is a graduate of Oxford University and a
|
8
|
+
long-time computer and software expert, and is now the director
|
9
|
+
of the <dfn id="dfn-w3c">World Wide Web Consortium (W3C)</dfn>, an organization that
|
10
|
+
coordinates the development of the Web. He also is a
|
11
|
+
principal research scientist at Massachusetts Institute of
|
12
|
+
Technology's Laboratory for Computer Science and Artificial
|
13
|
+
Intelligence (MIT CSAIL). Robert is a 30-year veteran at
|
14
|
+
CERN, where he still works. Robert organized the
|
15
|
+
first Web conference in Geneva in 1993. Both Tim and Robert
|
16
|
+
were awarded the ACM Software System Award in 1995 because
|
17
|
+
of their work on the Web.</p>
|
18
|
+
</div>
|
19
|
+
</div>
|
@@ -0,0 +1,12 @@
|
|
1
|
+
<div class="section" id="the-web">
|
2
|
+
<h2>The Web</h2>
|
3
|
+
|
4
|
+
<p>The Web is a vast collection of documents on the <dfn id="dfn-internet">Internet</dfn> that are linked together via
|
5
|
+
hyperlinks. The Internet consists of millions of computers worldwide
|
6
|
+
that communicate electronically. A <dfn id="dfn-hyperlink">hyperlink</dfn> is a predefined link between two
|
7
|
+
documents. The hyperlinks allow a user to access documents on various
|
8
|
+
Web servers without concern for where they are located. A <dfn id="dfn-web-server">Web server</dfn> is a computer on the Internet
|
9
|
+
that serves out Web pages on request. From a document on a Web server
|
10
|
+
in California, the user is just one mouse click away from a document
|
11
|
+
that is stored, perhaps, on a Web server in France. Hyperlinks are
|
12
|
+
integral to the Web. Without them, there would be no Web.</p>
|
@@ -0,0 +1,63 @@
|
|
1
|
+
<div class="chapter" id="css-h-1">
|
2
|
+
<h1>CSS</h1>
|
3
|
+
|
4
|
+
<p class="sidenote">HTML is the most popular document format on the
|
5
|
+
Web, and it is used in most of the examples in this book.</p>
|
6
|
+
|
7
|
+
<p>As we explained in <a class="chapref" href="http://people.opera.com/howcome/2005/ala/html-h-1"><q>The Web and HTML,</q></a>
|
8
|
+
HTML elements enable Web-page designers to
|
9
|
+
mark up a document's structure. The HTML specification lists
|
10
|
+
guidelines on how browsers should display these elements. For example,
|
11
|
+
you can be reasonably sure that the contents of a <span class="element">strong</span> element will be displayed as boldfaced.
|
12
|
+
Also, you can pretty much trust that most browsers will display the
|
13
|
+
content of an <span class="element">h1</span> element using a big font
|
14
|
+
size – at least bigger than the <span class="element">p</span>
|
15
|
+
element and bigger than the <span class="element">h2</span> element.
|
16
|
+
But beyond trust and hope, you don't have any control over your text's
|
17
|
+
appearance.</p>
|
18
|
+
|
19
|
+
<div class="sidebar" id="specs">
|
20
|
+
<h2 class="no-toc">CSS specifications</h2>
|
21
|
+
|
22
|
+
<p>Cascading Style Sheets is formally described in three W3C
|
23
|
+
specifications: CSS1, CSS2, and CSS 2.1. (As discussed in the
|
24
|
+
previous chapter, W3C is the organization that coordinates the
|
25
|
+
technical development of the Web.) The first specification, CSS1,
|
26
|
+
was issued in December 1996 and describes a simple style sheet
|
27
|
+
language mostly for screen-based presentations. CSS1 has around 50
|
28
|
+
properties (for example, <span class="property">color</span> and
|
29
|
+
<span class="property">font-size</span>). CSS2 was finalized in May
|
30
|
+
1998 and builds on CSS1. CSS2 includes all CSS1 properties and adds
|
31
|
+
around 70 of its own, such as properties to describe aural
|
32
|
+
presentations and page breaks.</p>
|
33
|
+
|
34
|
+
<p>CSS 2.1 is the most recent specification published by W3C. It
|
35
|
+
adds some new features, but CSS 2.1 is mostly a scaled-down version
|
36
|
+
of CSS2. CSS2 was an ambitious attempt to describe functionality,
|
37
|
+
which Web authors had requested. However, not all the functionality
|
38
|
+
is reliably supported by all browsers. CSS 2.1 is a specification
|
39
|
+
that describes the parts that <em>are</em> supported by two or
|
40
|
+
more browsers. Because CSS 2.1 is similar to CSS2, the
|
41
|
+
specification was given a minor version number (that is, 2.1)
|
42
|
+
rather than a major number (such as CSS3).</p>
|
43
|
+
</div>
|
44
|
+
|
45
|
+
<%= import('ch02/rules_and_css.html.erb')%>
|
46
|
+
|
47
|
+
</div>
|
48
|
+
|
49
|
+
<div class="index" id="index-h-1">
|
50
|
+
<h1>Index</h1>
|
51
|
+
|
52
|
+
<ul class="index">
|
53
|
+
<li><a href="#dfn-cern">CERN</a></li>
|
54
|
+
<li><a href="#dfn-internet">Internet</a></li>
|
55
|
+
<li><a href="#dfn-hyperlink">hyperlink</a></li>
|
56
|
+
<li><a href="#dfn-rule">rule</a></li>
|
57
|
+
<li><a href="#dfn-style-sheet">style sheet</a></li>
|
58
|
+
<li><a href="#dfn-w3c">W3C</a></li>
|
59
|
+
<li><a href="#dfn-web-server">Web server</a></li>
|
60
|
+
<li><a href="#dfn-w3c">World Wide Web Consortium</a></li>
|
61
|
+
</ul>
|
62
|
+
|
63
|
+
</div>
|
@@ -0,0 +1,41 @@
|
|
1
|
+
<div class="section" id="rules">
|
2
|
+
<h2>Rules and Style Sheets</h2>
|
3
|
+
|
4
|
+
<p>You can create style sheets in two ways. You can either use a
|
5
|
+
normal text editor and write the style sheets <q>by hand</q> or you
|
6
|
+
can use a dedicated tool – for example, a Web authoring tool.
|
7
|
+
The dedicated tools enable you to create style sheets without learning
|
8
|
+
the syntax of the CSS language. However, in many cases, the designer
|
9
|
+
wants to tweak the style sheet by hand afterwards, so we recommend
|
10
|
+
that you learn to write and edit CSS by hand. Let's get started! Here
|
11
|
+
is a simple example:</p>
|
12
|
+
|
13
|
+
<pre class="CSS">h1 { color: green }
|
14
|
+
</pre>
|
15
|
+
|
16
|
+
<p>This code is a simple CSS rule that contains one rule. A <dfn id="dfn-rule">rule</dfn> is a statement about one stylistic aspect of
|
17
|
+
one or more elements. A <dfn id="dfn-style-sheet">style sheet</dfn> is
|
18
|
+
a set of one or more rules that apply to an HTML document. This rule
|
19
|
+
sets the color of all first-level headings (<span class="element">h1</span>).</p>
|
20
|
+
|
21
|
+
|
22
|
+
<div class="table">
|
23
|
+
<p class="caption">HTML extension elements and their CSS equivalent.</p>
|
24
|
+
<table class="lined">
|
25
|
+
<thead>
|
26
|
+
<tr><th>Element</th><th>CSS equivalent</th></tr>
|
27
|
+
</thead>
|
28
|
+
<tbody>
|
29
|
+
<tr><td><code><tt></code></td>
|
30
|
+
<td><span class="css">font-family: monospace</span></td></tr>
|
31
|
+
<tr><td><code><i></code></td>
|
32
|
+
<td><span class="css">font-style: italic</span></td></tr>
|
33
|
+
<tr><td><code><b></code></td>
|
34
|
+
<td><span class="css">font-weight: bold</span></td></tr>
|
35
|
+
<tr><td><code><u></code></td>
|
36
|
+
<td><span class="css">text-decoration: underline</span></td></tr>
|
37
|
+
</tbody>
|
38
|
+
</table>
|
39
|
+
</div>
|
40
|
+
|
41
|
+
</div>
|
@@ -0,0 +1,27 @@
|
|
1
|
+
<div class="frontcover">
|
2
|
+
<img src="images/canvas.jpg">
|
3
|
+
<h1>Cascading Style Sheets</h1>
|
4
|
+
<h2>Designing for the Web</h2>
|
5
|
+
<h3>Third Edition</h3>
|
6
|
+
<p>Sample document</p>
|
7
|
+
</div>
|
8
|
+
|
9
|
+
<div class="halftitlepage">
|
10
|
+
<h1 class="no-toc">Cascading Style Sheets</h1>
|
11
|
+
<h2 class="no-toc">Designing for the Web</h2>
|
12
|
+
<h3 class="no-toc">Third Edition</h3>
|
13
|
+
</div>
|
14
|
+
|
15
|
+
<div class="titlepage">
|
16
|
+
<h1 class="no-toc">Cascading Style Sheets</h1>
|
17
|
+
<h2 class="no-toc">Designing for the Web</h2>
|
18
|
+
<h3 class="no-toc">Third Edition</h3>
|
19
|
+
|
20
|
+
<p class="no-toc">Håkon Wium Lie<br>Bert Bos</p>
|
21
|
+
<!-- also, the publisher's name would typically be printed here -->
|
22
|
+
</div>
|
23
|
+
|
24
|
+
<div class="imprint">
|
25
|
+
<p>Copyright © 2005 Håkon Wium Lie and Bert Bos</p>
|
26
|
+
|
27
|
+
</div>
|
@@ -0,0 +1,23 @@
|
|
1
|
+
<div class="preface" id="preface-h-1">
|
2
|
+
<h1>Preface</h1>
|
3
|
+
|
4
|
+
<p>This is a sample document whose purpose is to show how CSS can be
|
5
|
+
used to print a book. To make the document more lively, excerpts from
|
6
|
+
the third edition of “Cascading Style Sheets — designing
|
7
|
+
for tbe Web” have been included.<span class="footnote"> That
|
8
|
+
book <em>was</em> produced using the methods described in the
|
9
|
+
document, and it was published by Addison-Wesley in 2005.</span> The
|
10
|
+
excerpts have been selected for their example values and they appear,
|
11
|
+
in this document, out of order.</p>
|
12
|
+
|
13
|
+
<p>The PDF version of this document is produced directly from the HTML
|
14
|
+
and CSS sources by the Prince formatter.</p>
|
15
|
+
|
16
|
+
<p>We encourage you to reuse the structure, markup and style sheet of
|
17
|
+
this sample document. In your own book, however, you need to provide
|
18
|
+
the content yourself.</p>
|
19
|
+
|
20
|
+
<p class="author">Håkon Wium Lie & Bert Bos<br>
|
21
|
+
Oslo/Antibes<br>November 2005</p>
|
22
|
+
|
23
|
+
</div>
|
@@ -0,0 +1,25 @@
|
|
1
|
+
<div class="toc" id="toc-h-1">
|
2
|
+
<h1>Table of Contents</h1>
|
3
|
+
|
4
|
+
<ul class="toc">
|
5
|
+
<li class="frontmatter"><a href="#toc-h-1">Table of Contents</a></li>
|
6
|
+
<li class="frontmatter"><a href="#preface-h-1">Preface</a></li>
|
7
|
+
<li class="chapter"><a href="#html-h-1">The Web and HTML</a>
|
8
|
+
<ul>
|
9
|
+
<li class="section"><a href="#the-web">The Web</a>
|
10
|
+
<ul>
|
11
|
+
<li class="section"><a href="#development">Development of the Web</a></li>
|
12
|
+
<li class="section"><a href="#images">Adding images</a></li>
|
13
|
+
</ul>
|
14
|
+
</li>
|
15
|
+
</ul>
|
16
|
+
</li>
|
17
|
+
<li class="chapter"><a href="#css-h-1">CSS</a>
|
18
|
+
<ul>
|
19
|
+
<li class="section"><a href="#rules">Rules and Style Sheets</a></li>
|
20
|
+
</ul>
|
21
|
+
</li>
|
22
|
+
<li class="endmatter"><a href="#index-h-1">Index</a></li>
|
23
|
+
</ul>
|
24
|
+
|
25
|
+
</div>
|
data/lib/bookshop/version.rb
CHANGED
metadata
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
name: bookshop
|
3
3
|
version: !ruby/object:Gem::Version
|
4
4
|
prerelease:
|
5
|
-
version: 0.0.
|
5
|
+
version: 0.0.16
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
8
8
|
- D.a. Thompson
|
@@ -10,7 +10,7 @@ autorequire:
|
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
12
|
|
13
|
-
date: 2011-12-
|
13
|
+
date: 2011-12-11 00:00:00 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: thor
|
@@ -23,43 +23,32 @@ dependencies:
|
|
23
23
|
version: 0.14.6
|
24
24
|
type: :runtime
|
25
25
|
version_requirements: *id001
|
26
|
-
- !ruby/object:Gem::Dependency
|
27
|
-
name: nokogiri
|
28
|
-
prerelease: false
|
29
|
-
requirement: &id002 !ruby/object:Gem::Requirement
|
30
|
-
none: false
|
31
|
-
requirements:
|
32
|
-
- - ">="
|
33
|
-
- !ruby/object:Gem::Version
|
34
|
-
version: "0"
|
35
|
-
type: :runtime
|
36
|
-
version_requirements: *id002
|
37
26
|
- !ruby/object:Gem::Dependency
|
38
27
|
name: bundler
|
39
28
|
prerelease: false
|
40
|
-
requirement: &
|
29
|
+
requirement: &id002 !ruby/object:Gem::Requirement
|
41
30
|
none: false
|
42
31
|
requirements:
|
43
32
|
- - ">="
|
44
33
|
- !ruby/object:Gem::Version
|
45
34
|
version: 1.0.0
|
46
35
|
type: :development
|
47
|
-
version_requirements: *
|
36
|
+
version_requirements: *id002
|
48
37
|
- !ruby/object:Gem::Dependency
|
49
38
|
name: rspec
|
50
39
|
prerelease: false
|
51
|
-
requirement: &
|
40
|
+
requirement: &id003 !ruby/object:Gem::Requirement
|
52
41
|
none: false
|
53
42
|
requirements:
|
54
43
|
- - ">="
|
55
44
|
- !ruby/object:Gem::Version
|
56
45
|
version: "0"
|
57
46
|
type: :development
|
58
|
-
version_requirements: *
|
47
|
+
version_requirements: *id003
|
59
48
|
description: |-
|
60
|
-
bookShop is a publishing framework for html-to-(e)book toolchain happiness and sustainable productivity.
|
49
|
+
bookShop is a publishing framework for html-to-pdf/(e)book toolchain happiness and sustainable productivity.
|
61
50
|
The framework is optimized to help developers quickly ramp-up, allowing them to more rapidly
|
62
|
-
jump in and develop their html-to-(e)book (print-pdf, epub, mobi, etc.) flows, by favoring convention over
|
51
|
+
jump in and develop their html-to-pdf/(e)book (print-pdf, epub, mobi, etc.) flows, by favoring convention over
|
63
52
|
configuration, setting them up with best practices, standards and tools from the start.
|
64
53
|
email:
|
65
54
|
- da@blueheadpublishing.com
|
@@ -87,9 +76,18 @@ files:
|
|
87
76
|
- lib/bookshop/generators/bookshop/app/templates/CHANGELOG
|
88
77
|
- lib/bookshop/generators/bookshop/app/templates/README.rdoc
|
89
78
|
- lib/bookshop/generators/bookshop/app/templates/book/book.html.erb
|
79
|
+
- lib/bookshop/generators/bookshop/app/templates/book/ch01/adding_images.html.erb
|
80
|
+
- lib/bookshop/generators/bookshop/app/templates/book/ch01/ch01.html.erb
|
81
|
+
- lib/bookshop/generators/bookshop/app/templates/book/ch01/dev_of_the_web.html.erb
|
82
|
+
- lib/bookshop/generators/bookshop/app/templates/book/ch01/the_web.html.erb
|
83
|
+
- lib/bookshop/generators/bookshop/app/templates/book/ch02/ch02.html.erb
|
84
|
+
- lib/bookshop/generators/bookshop/app/templates/book/ch02/rules_and_css.html.erb
|
85
|
+
- lib/bookshop/generators/bookshop/app/templates/book/cover.html.erb
|
90
86
|
- lib/bookshop/generators/bookshop/app/templates/book/css/stylesheet.css
|
91
87
|
- lib/bookshop/generators/bookshop/app/templates/book/images/canvas.jpg
|
92
88
|
- lib/bookshop/generators/bookshop/app/templates/book/images/html-18.png
|
89
|
+
- lib/bookshop/generators/bookshop/app/templates/book/preface.html.erb
|
90
|
+
- lib/bookshop/generators/bookshop/app/templates/book/toc.html.erb
|
93
91
|
- lib/bookshop/generators/bookshop/app/templates/builds/epub/.empty_directory
|
94
92
|
- lib/bookshop/generators/bookshop/app/templates/builds/html/.empty_directory
|
95
93
|
- lib/bookshop/generators/bookshop/app/templates/builds/mobi/.empty_directory
|
@@ -97,14 +95,6 @@ files:
|
|
97
95
|
- lib/bookshop/generators/bookshop/app/templates/config/application.rb
|
98
96
|
- lib/bookshop/generators/bookshop/app/templates/config/boot.rb
|
99
97
|
- lib/bookshop/generators/bookshop/app/templates/script/bookshop
|
100
|
-
- lib/bookshop/generators/bookshop/app/tools/COPYING.txt
|
101
|
-
- lib/bookshop/generators/bookshop/app/tools/README.txt
|
102
|
-
- lib/bookshop/generators/bookshop/app/tools/epubcheck-1.2.jar
|
103
|
-
- lib/bookshop/generators/bookshop/app/tools/jigsaw_license.txt
|
104
|
-
- lib/bookshop/generators/bookshop/app/tools/jing_license.txt
|
105
|
-
- lib/bookshop/generators/bookshop/app/tools/kindlegen
|
106
|
-
- lib/bookshop/generators/bookshop/app/tools/lib/jing.jar
|
107
|
-
- lib/bookshop/generators/bookshop/app/tools/lib/saxon.jar
|
108
98
|
- lib/bookshop/generators/bookshop/generator/USAGE
|
109
99
|
- lib/bookshop/generators/bookshop/generator/generator_generator.rb
|
110
100
|
- lib/bookshop/generators/bookshop/generator/templates/%file_name%_generator.rb.tt
|
@@ -140,6 +130,6 @@ rubyforge_project: bookshop
|
|
140
130
|
rubygems_version: 1.8.5
|
141
131
|
signing_key:
|
142
132
|
specification_version: 3
|
143
|
-
summary: A publishing framework for html-to-(e)book toolchain happiness and sustainable productivity.
|
133
|
+
summary: A publishing framework for html-to-pdf/(e)book toolchain happiness and sustainable productivity.
|
144
134
|
test_files: []
|
145
135
|
|
@@ -1,19 +0,0 @@
|
|
1
|
-
Copyright (c) 2007 Adobe Systems Incorporated
|
2
|
-
|
3
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
4
|
-
this software and associated documentation files (the "Software"), to deal in
|
5
|
-
the Software without restriction, including without limitation the rights to
|
6
|
-
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
7
|
-
the Software, and to permit persons to whom the Software is furnished to do so,
|
8
|
-
subject to the following conditions:
|
9
|
-
|
10
|
-
The above copyright notice and this permission notice shall be included in all
|
11
|
-
copies or substantial portions of the Software.
|
12
|
-
|
13
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
14
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
15
|
-
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
16
|
-
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
17
|
-
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
18
|
-
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
19
|
-
|
@@ -1,61 +0,0 @@
|
|
1
|
-
This folder contains the distribution of epubcheck project.
|
2
|
-
|
3
|
-
EpubCheck is a tool to validate IDPF Epub files. It can detect many
|
4
|
-
types of errors in Epub. OCF container structure, OPF and OPS mark-up,
|
5
|
-
and internal reference consistency are checked. EpubCheck can be run
|
6
|
-
as a standalone command-line tool, installed as a web application or
|
7
|
-
used as a library.
|
8
|
-
|
9
|
-
Epubcheck project home: http://code.google.com/p/epubcheck/
|
10
|
-
|
11
|
-
BUILDING
|
12
|
-
|
13
|
-
To build epubcheck from the sources you need Java Development Kit (JDK) 1.5 or above
|
14
|
-
and Apache ant (http://ant.apache.org/) 1.6 or above installed
|
15
|
-
|
16
|
-
Run
|
17
|
-
|
18
|
-
ant -f build.xml
|
19
|
-
|
20
|
-
RUNNING
|
21
|
-
|
22
|
-
To run the tool you need Java Runtime (1.5 or above). Any OS should do. Run
|
23
|
-
it from the command line:
|
24
|
-
|
25
|
-
java -jar epubcheck-x.x.x.jar file.epub
|
26
|
-
|
27
|
-
All detected errors are simply printed to stderr.
|
28
|
-
|
29
|
-
USING AS A LIBRARY
|
30
|
-
|
31
|
-
You can also use EpubCheck as a library in your Java application. EpubCheck
|
32
|
-
public interfaces can be found in com.adobe.epubcheck.api package. EpubCheck
|
33
|
-
class can be used to instantiate a validation engine. Use one of its
|
34
|
-
constructors and then call validate() method. Report is an interface that
|
35
|
-
you can implement to get a list of the errors and warnings reported by the
|
36
|
-
validation engine (instead of the error list being printed out).
|
37
|
-
|
38
|
-
LICENSING
|
39
|
-
|
40
|
-
See COPYING.txt
|
41
|
-
|
42
|
-
AUTHORS
|
43
|
-
|
44
|
-
Peter Sorotokin
|
45
|
-
Garth Conboy
|
46
|
-
Markus Gylling
|
47
|
-
Piotr Kula
|
48
|
-
|
49
|
-
Most of the EpubCheck functionality comes from the schema validation tool Jing
|
50
|
-
and schemas that were developed by IDPF and DAISY. EpubCheck development was
|
51
|
-
largely done at Adobe Systems.
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
Binary file
|
@@ -1,66 +0,0 @@
|
|
1
|
-
Jigsaw Copying Conditions
|
2
|
-
|
3
|
-
W3C IPR SOFTWARE NOTICE
|
4
|
-
|
5
|
-
Copyright � 1995-1998 World Wide Web Consortium, (Massachusetts Institute of
|
6
|
-
Technology, Institut National de Recherche en Informatique et en
|
7
|
-
Automatique, Keio University). All Rights Reserved.
|
8
|
-
http://www.w3.org/Consortium/Legal/
|
9
|
-
|
10
|
-
This W3C work (including software, documents, or other related items) is
|
11
|
-
being provided by the copyright holders under the following license. By
|
12
|
-
obtaining, using and/or copying this work, you (the licensee) agree that you
|
13
|
-
have read, understood, and will comply with the following terms and
|
14
|
-
conditions:
|
15
|
-
|
16
|
-
Permission to use, copy, and modify this software and its documentation,
|
17
|
-
with or without modification, for any purpose and without fee or royalty is
|
18
|
-
hereby granted, provided that you include the following on ALL copies of the
|
19
|
-
software and documentation or portions thereof, including modifications,
|
20
|
-
that you make:
|
21
|
-
|
22
|
-
1. The full text of this NOTICE in a location viewable to users of the
|
23
|
-
redistributed or derivative work.
|
24
|
-
2. Any pre-existing intellectual property disclaimers, notices, or terms
|
25
|
-
and conditions. If none exist, a short notice of the following form
|
26
|
-
(hypertext is preferred, text is permitted) should be used within the
|
27
|
-
body of any redistributed or derivative code: "Copyright � World Wide
|
28
|
-
Web Consortium, (Massachusetts Institute of Technology, Institut
|
29
|
-
National de Recherche en Informatique et en Automatique, Keio
|
30
|
-
University). All Rights Reserved. http://www.w3.org/Consortium/Legal/"
|
31
|
-
3. Notice of any changes or modifications to the W3C files, including the
|
32
|
-
date changes were made. (We recommend you provide URIs to the location
|
33
|
-
from which the code is derived).
|
34
|
-
|
35
|
-
In addition, creators of derivitive works must include the full text of this
|
36
|
-
NOTICE in a location viewable to users of the derivitive work.
|
37
|
-
|
38
|
-
THIS SOFTWARE AND DOCUMENTATION IS PROVIDED "AS IS," AND COPYRIGHT HOLDERS
|
39
|
-
MAKE NO REPRESENTATIONS OR WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT
|
40
|
-
LIMITED TO, WARRANTIES OF MERCHANTABILITY OR FITNESS FOR ANY PARTICULAR
|
41
|
-
PURPOSE OR THAT THE USE OF THE SOFTWARE OR DOCUMENTATION WILL NOT INFRINGE
|
42
|
-
ANY THIRD PARTY PATENTS, COPYRIGHTS, TRADEMARKS OR OTHER RIGHTS.
|
43
|
-
|
44
|
-
COPYRIGHT HOLDERS WILL NOT BE LIABLE FOR ANY DIRECT, INDIRECT, SPECIAL OR
|
45
|
-
CONSEQUENTIAL DAMAGES ARISING OUT OF ANY USE OF THE SOFTWARE OR
|
46
|
-
DOCUMENTATION.
|
47
|
-
|
48
|
-
The name and trademarks of copyright holders may NOT be used in advertising
|
49
|
-
or publicity pertaining to the software without specific, written prior
|
50
|
-
permission. Title to copyright in this software and any associated
|
51
|
-
documentation will at all times remain with copyright holders.
|
52
|
-
|
53
|
-
____________________________________
|
54
|
-
|
55
|
-
This formulation of W3C's notice and license became active on August 14
|
56
|
-
1998. See the older formulation for the policy prior to this date. Please
|
57
|
-
see our Copyright FAQ for common questions about using materials from our
|
58
|
-
site, including specific terms and conditions for packages like libwww,
|
59
|
-
Amaya, and Jigsaw. Other questions about this notice can be directed to
|
60
|
-
site-policy@w3.org .
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
webmaster
|
66
|
-
(last updated 14-Aug-1998)
|
@@ -1,12 +0,0 @@
|
|
1
|
-
Jing Copying Conditions
|
2
|
-
|
3
|
-
Copyright (c) 2001-2003 Thai Open Source Software Center Ltd
|
4
|
-
All rights reserved.
|
5
|
-
|
6
|
-
Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:
|
7
|
-
|
8
|
-
* Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
|
9
|
-
* Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
|
10
|
-
* Neither the name of the Thai Open Source Software Center Ltd nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.
|
11
|
-
|
12
|
-
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
Binary file
|
Binary file
|
Binary file
|