kitabu 2.0.0 → 2.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (72) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +1 -1
  3. data/Gemfile.lock +1 -1
  4. data/README.md +7 -5
  5. data/lib/kitabu.rb +12 -1
  6. data/lib/kitabu/cli.rb +1 -1
  7. data/lib/kitabu/exporter.rb +5 -5
  8. data/lib/kitabu/{parser.rb → exporter/base.rb} +9 -11
  9. data/lib/kitabu/exporter/css.rb +24 -0
  10. data/lib/kitabu/{parser → exporter}/epub.rb +2 -2
  11. data/lib/kitabu/exporter/html.rb +109 -0
  12. data/lib/kitabu/{parser → exporter}/mobi.rb +2 -2
  13. data/lib/kitabu/exporter/pdf.rb +43 -0
  14. data/lib/kitabu/{parser → exporter}/txt.rb +2 -2
  15. data/lib/kitabu/footnotes/base.rb +33 -0
  16. data/lib/kitabu/footnotes/html.rb +52 -0
  17. data/lib/kitabu/footnotes/pdf.rb +47 -0
  18. data/lib/kitabu/source_list.rb +73 -0
  19. data/lib/kitabu/stats.rb +1 -1
  20. data/lib/kitabu/stream.rb +1 -1
  21. data/lib/kitabu/toc/html.rb +6 -6
  22. data/lib/kitabu/version.rb +1 -1
  23. data/spec/kitabu/exporter/css_spec.rb +16 -0
  24. data/spec/kitabu/{parser → exporter}/epub_spec.rb +3 -3
  25. data/spec/kitabu/exporter/html_spec.rb +36 -0
  26. data/spec/kitabu/{parser → exporter}/mobi_spec.rb +3 -3
  27. data/spec/kitabu/{parser → exporter}/pdf_spec.rb +3 -3
  28. data/spec/kitabu/{parser → exporter}/txt_spec.rb +3 -3
  29. data/spec/kitabu/footnotes/html_spec.rb +67 -0
  30. data/spec/kitabu/{parser/html_spec.rb → source_list_spec.rb} +5 -34
  31. data/spec/kitabu/stats_spec.rb +7 -7
  32. data/templates/templates/styles/pdf.scss +1 -47
  33. data/templates/text/04_Dynamic_Content.erb +1 -1
  34. metadata +29 -54
  35. data/examples/kitabu/output/epub/images/.gitkeep +0 -0
  36. data/examples/kitabu/output/epub/images/kitabu-icon.png +0 -0
  37. data/examples/kitabu/output/epub/images/kitabu-icon.svg +0 -19
  38. data/examples/kitabu/output/epub/images/kitabu-word.png +0 -0
  39. data/examples/kitabu/output/epub/images/kitabu-word.svg +0 -14
  40. data/examples/kitabu/output/epub/images/kitabu.png +0 -0
  41. data/examples/kitabu/output/epub/images/kitabu.svg +0 -20
  42. data/examples/kitabu/output/epub/section_0.html +0 -266
  43. data/examples/kitabu/output/epub/section_1.html +0 -246
  44. data/examples/kitabu/output/epub/section_2.html +0 -520
  45. data/examples/kitabu/output/epub/section_3.html +0 -282
  46. data/examples/kitabu/output/epub/section_4.html +0 -276
  47. data/examples/kitabu/output/epub/styles/epub.css +0 -437
  48. data/examples/kitabu/output/epub/styles/html.css +0 -712
  49. data/examples/kitabu/output/epub/styles/pdf.css +0 -840
  50. data/examples/kitabu/output/epub/styles/print.css +0 -1278
  51. data/examples/kitabu/output/epub/toc.html +0 -37
  52. data/examples/kitabu/output/images/.gitkeep +0 -0
  53. data/examples/kitabu/output/images/kitabu-icon.png +0 -0
  54. data/examples/kitabu/output/images/kitabu-icon.svg +0 -19
  55. data/examples/kitabu/output/images/kitabu-word.png +0 -0
  56. data/examples/kitabu/output/images/kitabu-word.svg +0 -14
  57. data/examples/kitabu/output/images/kitabu.png +0 -0
  58. data/examples/kitabu/output/images/kitabu.svg +0 -20
  59. data/examples/kitabu/output/kitabu.epub +0 -0
  60. data/examples/kitabu/output/kitabu.html +0 -513
  61. data/examples/kitabu/output/kitabu.mobi +0 -0
  62. data/examples/kitabu/output/kitabu.pdf +0 -0
  63. data/examples/kitabu/output/kitabu.pdf.html +0 -729
  64. data/examples/kitabu/output/kitabu.print.html +0 -729
  65. data/examples/kitabu/output/kitabu.print.pdf +0 -0
  66. data/examples/kitabu/output/kitabu.txt +0 -440
  67. data/examples/kitabu/output/styles/epub.css +0 -437
  68. data/examples/kitabu/output/styles/html.css +0 -712
  69. data/examples/kitabu/output/styles/pdf.css +0 -840
  70. data/examples/kitabu/output/styles/print.css +0 -1278
  71. data/lib/kitabu/parser/html.rb +0 -208
  72. data/lib/kitabu/parser/pdf.rb +0 -88
@@ -220,36 +220,6 @@ li code {
220
220
  margin-top: 15px;
221
221
  }
222
222
 
223
- // Footnotes
224
- .fn {
225
- counter-increment: footnote;
226
- display: prince-footnote;
227
- font-size: 9pt;
228
- footnote-style-position: inside;
229
- line-height: 1.4;
230
- position: footnote;
231
- }
232
-
233
- .fn::footnote-call {
234
- content: "";
235
- font-size: 80%;
236
- }
237
-
238
- .fn::footnote-marker {
239
- padding-right: 0.4em;
240
- vertical-align: super;
241
- display: none;
242
- }
243
-
244
- .footnote a,
245
- .fn a {
246
- color: #000;
247
- }
248
-
249
- .fn code {
250
- font-size: 8pt;
251
- }
252
-
253
223
  // Table of contents
254
224
  .table-of-contents {
255
225
  page: chapter;
@@ -314,28 +284,12 @@ li code {
314
284
  }
315
285
 
316
286
  // Footnotes
317
- .chapters {
318
- counter-reset: fnref;
319
- counter-reset: fndesc;
320
- }
321
-
322
- .fn-ref {
323
- counter-increment: fnref;
324
- }
325
-
326
- .fn-desc {
327
- counter-increment: fndesc;
287
+ .footnote {
328
288
  display: prince-footnote;
329
289
  footnote-style-position: inside;
330
290
  position: footnote;
331
291
  }
332
292
 
333
- .fn-desc:footnote-marker {
334
- vertical-align: super;
335
- content: counter(fndesc);
336
- margin-right: 5px;
337
- }
338
-
339
293
  // Notes
340
294
  .note {
341
295
  font-size: 13px;
@@ -57,7 +57,7 @@ By default, this will generate a `<div class="note info">` tag, but you can use
57
57
 
58
58
  ### Escaping ERb code
59
59
 
60
- If you want to write a book about Rails, you're likely to use lots of ERb tags. In this case, make sure you escape the `<% %>` and `<%= %>` markers as `<%% %>` and `<%%= %>`; otherwise you'll have a syntax error.
60
+ If you want to write a book about Rails, you're likely to use lots of ERb tags. In this case, make sure you escape the `<%% %>` and `<%%= %>` markers as `<%%% %>` and `<%%%= %>`; otherwise you'll have a syntax error.
61
61
 
62
62
  ```
63
63
  <%%%= Date.today %>
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kitabu
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.0
4
+ version: 2.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Nando Vieira
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-03-14 00:00:00.000000000 Z
11
+ date: 2015-03-15 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -259,59 +259,28 @@ files:
259
259
  - attachments/kitabu.mobi
260
260
  - attachments/kitabu.pdf
261
261
  - bin/kitabu
262
- - examples/kitabu/output/epub/images/.gitkeep
263
- - examples/kitabu/output/epub/images/kitabu-icon.png
264
- - examples/kitabu/output/epub/images/kitabu-icon.svg
265
- - examples/kitabu/output/epub/images/kitabu-word.png
266
- - examples/kitabu/output/epub/images/kitabu-word.svg
267
- - examples/kitabu/output/epub/images/kitabu.png
268
- - examples/kitabu/output/epub/images/kitabu.svg
269
- - examples/kitabu/output/epub/section_0.html
270
- - examples/kitabu/output/epub/section_1.html
271
- - examples/kitabu/output/epub/section_2.html
272
- - examples/kitabu/output/epub/section_3.html
273
- - examples/kitabu/output/epub/section_4.html
274
- - examples/kitabu/output/epub/styles/epub.css
275
- - examples/kitabu/output/epub/styles/html.css
276
- - examples/kitabu/output/epub/styles/pdf.css
277
- - examples/kitabu/output/epub/styles/print.css
278
- - examples/kitabu/output/epub/toc.html
279
- - examples/kitabu/output/images/.gitkeep
280
- - examples/kitabu/output/images/kitabu-icon.png
281
- - examples/kitabu/output/images/kitabu-icon.svg
282
- - examples/kitabu/output/images/kitabu-word.png
283
- - examples/kitabu/output/images/kitabu-word.svg
284
- - examples/kitabu/output/images/kitabu.png
285
- - examples/kitabu/output/images/kitabu.svg
286
- - examples/kitabu/output/kitabu.epub
287
- - examples/kitabu/output/kitabu.html
288
- - examples/kitabu/output/kitabu.mobi
289
- - examples/kitabu/output/kitabu.pdf
290
- - examples/kitabu/output/kitabu.pdf.html
291
- - examples/kitabu/output/kitabu.print.html
292
- - examples/kitabu/output/kitabu.print.pdf
293
- - examples/kitabu/output/kitabu.txt
294
- - examples/kitabu/output/styles/epub.css
295
- - examples/kitabu/output/styles/html.css
296
- - examples/kitabu/output/styles/pdf.css
297
- - examples/kitabu/output/styles/print.css
298
262
  - kitabu.gemspec
299
263
  - lib/kitabu.rb
300
264
  - lib/kitabu/cli.rb
301
265
  - lib/kitabu/dependency.rb
302
266
  - lib/kitabu/errors.rb
303
267
  - lib/kitabu/exporter.rb
268
+ - lib/kitabu/exporter/base.rb
269
+ - lib/kitabu/exporter/css.rb
270
+ - lib/kitabu/exporter/epub.rb
271
+ - lib/kitabu/exporter/html.rb
272
+ - lib/kitabu/exporter/mobi.rb
273
+ - lib/kitabu/exporter/pdf.rb
274
+ - lib/kitabu/exporter/txt.rb
304
275
  - lib/kitabu/extensions/rouge.rb
305
276
  - lib/kitabu/extensions/string.rb
277
+ - lib/kitabu/footnotes/base.rb
278
+ - lib/kitabu/footnotes/html.rb
279
+ - lib/kitabu/footnotes/pdf.rb
306
280
  - lib/kitabu/generator.rb
307
281
  - lib/kitabu/helpers.rb
308
282
  - lib/kitabu/markdown.rb
309
- - lib/kitabu/parser.rb
310
- - lib/kitabu/parser/epub.rb
311
- - lib/kitabu/parser/html.rb
312
- - lib/kitabu/parser/mobi.rb
313
- - lib/kitabu/parser/pdf.rb
314
- - lib/kitabu/parser/txt.rb
283
+ - lib/kitabu/source_list.rb
315
284
  - lib/kitabu/stats.rb
316
285
  - lib/kitabu/stream.rb
317
286
  - lib/kitabu/syntax/highlight.rb
@@ -324,14 +293,17 @@ files:
324
293
  - spec/kitabu/cli/permalinks_spec.rb
325
294
  - spec/kitabu/cli/stats_spec.rb
326
295
  - spec/kitabu/cli/version_spec.rb
296
+ - spec/kitabu/exporter/css_spec.rb
297
+ - spec/kitabu/exporter/epub_spec.rb
298
+ - spec/kitabu/exporter/html_spec.rb
299
+ - spec/kitabu/exporter/mobi_spec.rb
300
+ - spec/kitabu/exporter/pdf_spec.rb
301
+ - spec/kitabu/exporter/txt_spec.rb
327
302
  - spec/kitabu/extensions/string_spec.rb
303
+ - spec/kitabu/footnotes/html_spec.rb
328
304
  - spec/kitabu/generator_spec.rb
329
305
  - spec/kitabu/markdown_spec.rb
330
- - spec/kitabu/parser/epub_spec.rb
331
- - spec/kitabu/parser/html_spec.rb
332
- - spec/kitabu/parser/mobi_spec.rb
333
- - spec/kitabu/parser/pdf_spec.rb
334
- - spec/kitabu/parser/txt_spec.rb
306
+ - spec/kitabu/source_list_spec.rb
335
307
  - spec/kitabu/stats_spec.rb
336
308
  - spec/kitabu/toc/html_spec.rb
337
309
  - spec/spec_helper.rb
@@ -421,14 +393,17 @@ test_files:
421
393
  - spec/kitabu/cli/permalinks_spec.rb
422
394
  - spec/kitabu/cli/stats_spec.rb
423
395
  - spec/kitabu/cli/version_spec.rb
396
+ - spec/kitabu/exporter/css_spec.rb
397
+ - spec/kitabu/exporter/epub_spec.rb
398
+ - spec/kitabu/exporter/html_spec.rb
399
+ - spec/kitabu/exporter/mobi_spec.rb
400
+ - spec/kitabu/exporter/pdf_spec.rb
401
+ - spec/kitabu/exporter/txt_spec.rb
424
402
  - spec/kitabu/extensions/string_spec.rb
403
+ - spec/kitabu/footnotes/html_spec.rb
425
404
  - spec/kitabu/generator_spec.rb
426
405
  - spec/kitabu/markdown_spec.rb
427
- - spec/kitabu/parser/epub_spec.rb
428
- - spec/kitabu/parser/html_spec.rb
429
- - spec/kitabu/parser/mobi_spec.rb
430
- - spec/kitabu/parser/pdf_spec.rb
431
- - spec/kitabu/parser/txt_spec.rb
406
+ - spec/kitabu/source_list_spec.rb
432
407
  - spec/kitabu/stats_spec.rb
433
408
  - spec/kitabu/toc/html_spec.rb
434
409
  - spec/spec_helper.rb
@@ -1,19 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8" standalone="no"?>
2
- <svg width="79px" height="108px" viewBox="0 0 79 108" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
3
- <!-- Generator: Sketch 3.2.2 (9983) - http://www.bohemiancoding.com/sketch -->
4
- <title>kitabu-icon</title>
5
- <desc>Created with Sketch.</desc>
6
- <defs></defs>
7
- <g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" sketch:type="MSPage">
8
- <g id="Artboard-1" sketch:type="MSArtboardGroup" transform="translate(-731.000000, -27.000000)" fill="#FFFFFF">
9
- <g id="kitabu-icon" sketch:type="MSLayerGroup" transform="translate(731.000000, 27.000000)">
10
- <g id="icon" transform="translate(0.895522, 0.000000)" sketch:type="MSShapeGroup">
11
- <path d="M22.5432836,0.158684932 L22.5432836,0.225876712 L0.0402985075,22.6918219 L0.0402985075,107.69689 L77.9477612,107.69689 L77.9477612,0.158684932 L22.5432836,0.158684932 L22.5432836,0.158684932 Z M68.9925373,98.7379863 L8.99552239,98.7379863 L8.99552239,31.650726 L31.4985075,31.650726 L31.4985075,9.11758904 L68.9925373,9.11758904 L68.9925373,98.7379863 L68.9925373,98.7379863 Z" id="Fill-811"></path>
12
- <path d="M16.9567164,41.0710137 L53.0014925,41.0710137 L53.0014925,48.2246986 L16.9567164,48.2246986 L16.9567164,41.0710137 Z" id="Fill-812"></path>
13
- <path d="M16.9567164,57.1895753 L42.4641791,57.1895753 L42.4641791,64.3432603 L16.9567164,64.3432603 L16.9567164,57.1895753 Z" id="Fill-813"></path>
14
- <path d="M16.9567164,73.2006301 L60.7552239,73.2006301 L60.7552239,80.3543151 L16.9567164,80.3543151 L16.9567164,73.2006301 Z" id="Fill-814"></path>
15
- </g>
16
- </g>
17
- </g>
18
- </g>
19
- </svg>
@@ -1,14 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8" standalone="no"?>
2
- <svg width="197px" height="63px" viewBox="0 0 197 63" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
3
- <!-- Generator: Sketch 3.2.2 (9983) - http://www.bohemiancoding.com/sketch -->
4
- <title>kitabu-word</title>
5
- <desc>Created with Sketch.</desc>
6
- <defs></defs>
7
- <g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" sketch:type="MSPage">
8
- <g id="Artboard-1" sketch:type="MSArtboardGroup" transform="translate(-76.000000, -61.000000)" fill="#FFFFFF">
9
- <g id="kitabu-word" sketch:type="MSLayerGroup" transform="translate(76.000000, 61.000000)">
10
- <path d="M28.5288568,61.6462919 C30.9812881,61.6462919 32.9263198,59.7041663 32.9263198,57.2553991 C32.9263198,56.4109967 32.67262,55.482154 31.9960872,54.5533113 L19.5647976,38.2563439 L30.6430217,29.8123193 C31.7423874,28.9679169 32.3343536,27.6168729 32.3343536,26.3502692 C32.3343536,23.9015021 30.3893219,21.9593765 27.9368906,21.9593765 C26.9220914,21.9593765 26.0764255,22.2126972 24.9770597,23.0570997 L9.67050582,35.0476145 L9.67050582,5.24020784 C9.67050582,2.70700047 7.64090751,0.849315068 5.10390963,0.849315068 C2.48234515,0.849315068 0.537313433,2.70700047 0.537313433,5.24020784 L0.537313433,57.2553991 C0.537313433,59.7886065 2.48234515,61.6462919 5.10390963,61.6462919 C7.64090751,61.6462919 9.67050582,59.7886065 9.67050582,57.2553991 L9.67050582,45.0960038 L12.3766369,42.9849976 L24.9770597,59.8730468 C25.7381591,60.8863297 26.9220914,61.6462919 28.5288568,61.6462919 L28.5288568,61.6462919 Z M47.9791739,26.5191497 C47.9791739,23.9859424 45.9495756,21.9593765 43.4125777,21.9593765 C40.8755798,21.9593765 38.8459815,23.9859424 38.8459815,26.5191497 L38.8459815,57.0865187 C38.8459815,59.619726 40.8755798,61.6462919 43.4125777,61.6462919 C45.9495756,61.6462919 47.9791739,59.619726 47.9791739,57.0865187 L47.9791739,26.5191497 Z M43.4125777,17.3996032 C46.9643747,17.3996032 48.9094065,15.3730373 48.9094065,12.0798677 C48.9094065,8.19561644 46.9643747,6.50681153 43.4125777,6.50681153 C39.9453473,6.50681153 38.0003155,8.19561644 38.0003155,12.0798677 C38.0003155,15.3730373 39.9453473,17.3996032 43.4125777,17.3996032 L43.4125777,17.3996032 Z M59.3956644,22.6348984 L57.4506327,22.6348984 C55.3364678,22.6348984 53.6451358,24.3237034 53.6451358,26.4347095 C53.6451358,28.5457156 55.3364678,30.2345205 57.4506327,30.2345205 L59.3956644,30.2345205 L59.3956644,50.1624185 C59.3956644,56.8331979 64.0468272,61.6462919 71.5732542,61.6462919 C73.7719857,61.6462919 75.5478843,59.8730468 75.5478843,57.6776004 C75.5478843,55.482154 73.7719857,53.7089088 71.5732542,53.7089088 C70.0510555,53.7089088 68.3597236,52.6111856 68.3597236,50.66906 L68.3597236,30.2345205 L72.1652204,30.2345205 C74.2793853,30.2345205 75.9707172,28.5457156 75.9707172,26.4347095 C75.9707172,24.3237034 74.2793853,22.6348984 72.1652204,22.6348984 L68.3597236,22.6348984 L68.3597236,15.5419178 C68.3597236,13.0931507 66.3301253,11.0665848 63.877694,11.0665848 C61.4252627,11.0665848 59.3956644,13.0931507 59.3956644,15.5419178 L59.3956644,22.6348984 Z M97.4506327,29.5589986 C102.355495,29.5589986 105.146193,32.092206 105.146193,35.892017 L105.146193,37.4119414 L94.0679688,37.4119414 C86.710675,37.4119414 80.3681802,41.4650732 80.3681802,49.3180161 C80.3681802,56.9176382 85.865009,62.0684932 94.1525354,62.0684932 C99.2265312,62.0684932 102.947461,60.8018895 105.23076,57.1709589 C105.23076,59.619726 107.260358,61.6462919 109.712789,61.6462919 C112.16522,61.6462919 114.194819,59.619726 114.194819,57.1709589 L114.194819,35.554256 C114.194819,26.60359 107.936891,21.452735 97.4506327,21.452735 C90.1779054,21.452735 85.9495756,24.2392631 83.5817109,26.8569107 C82.8206115,27.7013132 82.4823451,28.7145961 82.4823451,29.6434388 C82.4823451,31.8388852 84.2582437,33.6121304 86.4569752,33.6121304 C87.4717743,33.6121304 88.1483071,33.3588096 88.9939731,32.7677279 C91.108138,31.2478035 93.7297024,29.5589986 97.4506327,29.5589986 L97.4506327,29.5589986 Z M96.5204001,54.468871 C91.7846707,54.468871 89.5013726,52.5267454 89.5013726,49.3180161 C89.5013726,46.2781672 91.5309709,44.5049221 95.2519012,44.5049221 L105.146193,44.5049221 L105.146193,46.8692489 C105.146193,51.5979027 101.00243,54.468871 96.5204001,54.468871 L96.5204001,54.468871 Z M131.361838,33.5276901 C131.361838,33.5276901 134.659935,29.2212376 139.733931,29.2212376 C145.484459,29.2212376 148.782557,33.4432499 148.782557,41.8028342 C148.782557,50.0779783 145.569026,54.2999906 139.733931,54.2999906 C134.829068,54.2999906 131.361838,51.006821 131.361838,45.180444 L131.361838,33.5276901 Z M140.664163,21.452735 C136.604967,21.452735 133.05317,23.1415399 131.361838,24.8303448 L131.361838,5.40908833 C131.361838,2.87588096 129.332239,0.849315068 126.795242,0.849315068 C124.258244,0.849315068 122.228645,2.87588096 122.228645,5.40908833 L122.228645,45.180444 C122.228645,56.4109967 129.501373,62.0684932 139.733931,62.0684932 C151.150421,62.0684932 157.831182,55.5665942 157.831182,41.8028342 C157.831182,28.0390742 151.319554,21.452735 140.664163,21.452735 L140.664163,21.452735 Z M167.894607,21.9593765 C165.357609,21.9593765 163.328011,23.9859424 163.328011,26.5191497 L163.328011,46.193727 C163.328011,54.468871 166.456975,62.0684932 180.072197,62.0684932 C193.602853,62.0684932 196.731817,54.468871 196.731817,46.193727 L196.731817,26.5191497 C196.731817,23.9859424 194.702218,21.9593765 192.16522,21.9593765 C189.628223,21.9593765 187.598624,23.9859424 187.598624,26.5191497 L187.598624,46.193727 C187.598624,50.0779783 186.245559,53.7933491 180.072197,53.7933491 C173.814269,53.7933491 172.461203,50.0779783 172.461203,46.193727 L172.461203,26.5191497 C172.461203,23.9859424 170.431605,21.9593765 167.894607,21.9593765 L167.894607,21.9593765 Z" id="kitabu" sketch:type="MSShapeGroup"></path>
11
- </g>
12
- </g>
13
- </g>
14
- </svg>
@@ -1,20 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8" standalone="no"?>
2
- <svg width="299px" height="108px" viewBox="0 0 299 108" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:sketch="http://www.bohemiancoding.com/sketch/ns">
3
- <!-- Generator: Sketch 3.2.2 (9983) - http://www.bohemiancoding.com/sketch -->
4
- <title>kitabu</title>
5
- <desc>Created with Sketch.</desc>
6
- <defs></defs>
7
- <g id="Page-1" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd" sketch:type="MSPage">
8
- <g id="Artboard-1" sketch:type="MSArtboardGroup" transform="translate(-306.000000, -171.000000)" fill="#FFFFFF">
9
- <g id="kitabu" sketch:type="MSLayerGroup" transform="translate(306.000000, 171.000000)">
10
- <g id="icon" transform="translate(220.895522, 0.000000)" sketch:type="MSShapeGroup">
11
- <path d="M22.5432836,0.158684932 L22.5432836,0.225876712 L0.0402985075,22.6918219 L0.0402985075,107.69689 L77.9477612,107.69689 L77.9477612,0.158684932 L22.5432836,0.158684932 L22.5432836,0.158684932 Z M68.9925373,98.7379863 L8.99552239,98.7379863 L8.99552239,31.650726 L31.4985075,31.650726 L31.4985075,9.11758904 L68.9925373,9.11758904 L68.9925373,98.7379863 L68.9925373,98.7379863 Z" id="Fill-811"></path>
12
- <path d="M16.9567164,41.0710137 L53.0014925,41.0710137 L53.0014925,48.2246986 L16.9567164,48.2246986 L16.9567164,41.0710137 Z" id="Fill-812"></path>
13
- <path d="M16.9567164,57.1895753 L42.4641791,57.1895753 L42.4641791,64.3432603 L16.9567164,64.3432603 L16.9567164,57.1895753 Z" id="Fill-813"></path>
14
- <path d="M16.9567164,73.2006301 L60.7552239,73.2006301 L60.7552239,80.3543151 L16.9567164,80.3543151 L16.9567164,73.2006301 Z" id="Fill-814"></path>
15
- </g>
16
- <path d="M28.5288568,92.6462919 C30.9812881,92.6462919 32.9263198,90.7041663 32.9263198,88.2553991 C32.9263198,87.4109967 32.67262,86.482154 31.9960872,85.5533113 L19.5647976,69.2563439 L30.6430217,60.8123193 C31.7423874,59.9679169 32.3343536,58.6168729 32.3343536,57.3502692 C32.3343536,54.9015021 30.3893219,52.9593765 27.9368906,52.9593765 C26.9220914,52.9593765 26.0764255,53.2126972 24.9770597,54.0570997 L9.67050582,66.0476145 L9.67050582,36.2402078 C9.67050582,33.7070005 7.64090751,31.8493151 5.10390963,31.8493151 C2.48234515,31.8493151 0.537313433,33.7070005 0.537313433,36.2402078 L0.537313433,88.2553991 C0.537313433,90.7886065 2.48234515,92.6462919 5.10390963,92.6462919 C7.64090751,92.6462919 9.67050582,90.7886065 9.67050582,88.2553991 L9.67050582,76.0960038 L12.3766369,73.9849976 L24.9770597,90.8730468 C25.7381591,91.8863297 26.9220914,92.6462919 28.5288568,92.6462919 L28.5288568,92.6462919 Z M47.9791739,57.5191497 C47.9791739,54.9859424 45.9495756,52.9593765 43.4125777,52.9593765 C40.8755798,52.9593765 38.8459815,54.9859424 38.8459815,57.5191497 L38.8459815,88.0865187 C38.8459815,90.619726 40.8755798,92.6462919 43.4125777,92.6462919 C45.9495756,92.6462919 47.9791739,90.619726 47.9791739,88.0865187 L47.9791739,57.5191497 Z M43.4125777,48.3996032 C46.9643747,48.3996032 48.9094065,46.3730373 48.9094065,43.0798677 C48.9094065,39.1956164 46.9643747,37.5068115 43.4125777,37.5068115 C39.9453473,37.5068115 38.0003155,39.1956164 38.0003155,43.0798677 C38.0003155,46.3730373 39.9453473,48.3996032 43.4125777,48.3996032 L43.4125777,48.3996032 Z M59.3956644,53.6348984 L57.4506327,53.6348984 C55.3364678,53.6348984 53.6451358,55.3237034 53.6451358,57.4347095 C53.6451358,59.5457156 55.3364678,61.2345205 57.4506327,61.2345205 L59.3956644,61.2345205 L59.3956644,81.1624185 C59.3956644,87.8331979 64.0468272,92.6462919 71.5732542,92.6462919 C73.7719857,92.6462919 75.5478843,90.8730468 75.5478843,88.6776004 C75.5478843,86.482154 73.7719857,84.7089088 71.5732542,84.7089088 C70.0510555,84.7089088 68.3597236,83.6111856 68.3597236,81.66906 L68.3597236,61.2345205 L72.1652204,61.2345205 C74.2793853,61.2345205 75.9707172,59.5457156 75.9707172,57.4347095 C75.9707172,55.3237034 74.2793853,53.6348984 72.1652204,53.6348984 L68.3597236,53.6348984 L68.3597236,46.5419178 C68.3597236,44.0931507 66.3301253,42.0665848 63.877694,42.0665848 C61.4252627,42.0665848 59.3956644,44.0931507 59.3956644,46.5419178 L59.3956644,53.6348984 Z M97.4506327,60.5589986 C102.355495,60.5589986 105.146193,63.092206 105.146193,66.892017 L105.146193,68.4119414 L94.0679688,68.4119414 C86.710675,68.4119414 80.3681802,72.4650732 80.3681802,80.3180161 C80.3681802,87.9176382 85.865009,93.0684932 94.1525354,93.0684932 C99.2265312,93.0684932 102.947461,91.8018895 105.23076,88.1709589 C105.23076,90.619726 107.260358,92.6462919 109.712789,92.6462919 C112.16522,92.6462919 114.194819,90.619726 114.194819,88.1709589 L114.194819,66.554256 C114.194819,57.60359 107.936891,52.452735 97.4506327,52.452735 C90.1779054,52.452735 85.9495756,55.2392631 83.5817109,57.8569107 C82.8206115,58.7013132 82.4823451,59.7145961 82.4823451,60.6434388 C82.4823451,62.8388852 84.2582437,64.6121304 86.4569752,64.6121304 C87.4717743,64.6121304 88.1483071,64.3588096 88.9939731,63.7677279 C91.108138,62.2478035 93.7297024,60.5589986 97.4506327,60.5589986 L97.4506327,60.5589986 Z M96.5204001,85.468871 C91.7846707,85.468871 89.5013726,83.5267454 89.5013726,80.3180161 C89.5013726,77.2781672 91.5309709,75.5049221 95.2519012,75.5049221 L105.146193,75.5049221 L105.146193,77.8692489 C105.146193,82.5979027 101.00243,85.468871 96.5204001,85.468871 L96.5204001,85.468871 Z M131.361838,64.5276901 C131.361838,64.5276901 134.659935,60.2212376 139.733931,60.2212376 C145.484459,60.2212376 148.782557,64.4432499 148.782557,72.8028342 C148.782557,81.0779783 145.569026,85.2999906 139.733931,85.2999906 C134.829068,85.2999906 131.361838,82.006821 131.361838,76.180444 L131.361838,64.5276901 Z M140.664163,52.452735 C136.604967,52.452735 133.05317,54.1415399 131.361838,55.8303448 L131.361838,36.4090883 C131.361838,33.875881 129.332239,31.8493151 126.795242,31.8493151 C124.258244,31.8493151 122.228645,33.875881 122.228645,36.4090883 L122.228645,76.180444 C122.228645,87.4109967 129.501373,93.0684932 139.733931,93.0684932 C151.150421,93.0684932 157.831182,86.5665942 157.831182,72.8028342 C157.831182,59.0390742 151.319554,52.452735 140.664163,52.452735 L140.664163,52.452735 Z M167.894607,52.9593765 C165.357609,52.9593765 163.328011,54.9859424 163.328011,57.5191497 L163.328011,77.193727 C163.328011,85.468871 166.456975,93.0684932 180.072197,93.0684932 C193.602853,93.0684932 196.731817,85.468871 196.731817,77.193727 L196.731817,57.5191497 C196.731817,54.9859424 194.702218,52.9593765 192.16522,52.9593765 C189.628223,52.9593765 187.598624,54.9859424 187.598624,57.5191497 L187.598624,77.193727 C187.598624,81.0779783 186.245559,84.7933491 180.072197,84.7933491 C173.814269,84.7933491 172.461203,81.0779783 172.461203,77.193727 L172.461203,57.5191497 C172.461203,54.9859424 170.431605,52.9593765 167.894607,52.9593765 L167.894607,52.9593765 Z" sketch:type="MSShapeGroup"></path>
17
- </g>
18
- </g>
19
- </g>
20
- </svg>
@@ -1,266 +0,0 @@
1
- <?xml version="1.0" encoding="UTF-8"?>
2
- <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
3
- <html class="epub" xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
4
- <head>
5
- <title></title>
6
- <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
7
- <link name="stylesheet" rel="stylesheet" type="text/css" href="styles/epub.css" />
8
- <style type="text/css">.highlight table td { padding: 5px; }
9
- .highlight table pre { margin: 0; }
10
- .highlight .cm {
11
- color: #999988;
12
- font-style: italic;
13
- }
14
- .highlight .cp {
15
- color: #999999;
16
- font-weight: bold;
17
- }
18
- .highlight .c1 {
19
- color: #999988;
20
- font-style: italic;
21
- }
22
- .highlight .cs {
23
- color: #999999;
24
- font-weight: bold;
25
- font-style: italic;
26
- }
27
- .highlight .c, .highlight .cd {
28
- color: #999988;
29
- font-style: italic;
30
- }
31
- .highlight .err {
32
- color: #a61717;
33
- background-color: #e3d2d2;
34
- }
35
- .highlight .gd {
36
- color: #000000;
37
- background-color: #ffdddd;
38
- }
39
- .highlight .ge {
40
- color: #000000;
41
- font-style: italic;
42
- }
43
- .highlight .gr {
44
- color: #aa0000;
45
- }
46
- .highlight .gh {
47
- color: #999999;
48
- }
49
- .highlight .gi {
50
- color: #000000;
51
- background-color: #ddffdd;
52
- }
53
- .highlight .go {
54
- color: #888888;
55
- }
56
- .highlight .gp {
57
- color: #555555;
58
- }
59
- .highlight .gs {
60
- font-weight: bold;
61
- }
62
- .highlight .gu {
63
- color: #aaaaaa;
64
- }
65
- .highlight .gt {
66
- color: #aa0000;
67
- }
68
- .highlight .kc {
69
- color: #000000;
70
- font-weight: bold;
71
- }
72
- .highlight .kd {
73
- color: #000000;
74
- font-weight: bold;
75
- }
76
- .highlight .kn {
77
- color: #000000;
78
- font-weight: bold;
79
- }
80
- .highlight .kp {
81
- color: #000000;
82
- font-weight: bold;
83
- }
84
- .highlight .kr {
85
- color: #000000;
86
- font-weight: bold;
87
- }
88
- .highlight .kt {
89
- color: #445588;
90
- font-weight: bold;
91
- }
92
- .highlight .k, .highlight .kv {
93
- color: #000000;
94
- font-weight: bold;
95
- }
96
- .highlight .mf {
97
- color: #009999;
98
- }
99
- .highlight .mh {
100
- color: #009999;
101
- }
102
- .highlight .il {
103
- color: #009999;
104
- }
105
- .highlight .mi {
106
- color: #009999;
107
- }
108
- .highlight .mo {
109
- color: #009999;
110
- }
111
- .highlight .m, .highlight .mb, .highlight .mx {
112
- color: #009999;
113
- }
114
- .highlight .sb {
115
- color: #d14;
116
- }
117
- .highlight .sc {
118
- color: #d14;
119
- }
120
- .highlight .sd {
121
- color: #d14;
122
- }
123
- .highlight .s2 {
124
- color: #d14;
125
- }
126
- .highlight .se {
127
- color: #d14;
128
- }
129
- .highlight .sh {
130
- color: #d14;
131
- }
132
- .highlight .si {
133
- color: #d14;
134
- }
135
- .highlight .sx {
136
- color: #d14;
137
- }
138
- .highlight .sr {
139
- color: #009926;
140
- }
141
- .highlight .s1 {
142
- color: #d14;
143
- }
144
- .highlight .ss {
145
- color: #990073;
146
- }
147
- .highlight .s {
148
- color: #d14;
149
- }
150
- .highlight .na {
151
- color: #008080;
152
- }
153
- .highlight .bp {
154
- color: #999999;
155
- }
156
- .highlight .nb {
157
- color: #0086B3;
158
- }
159
- .highlight .nc {
160
- color: #445588;
161
- font-weight: bold;
162
- }
163
- .highlight .no {
164
- color: #008080;
165
- }
166
- .highlight .nd {
167
- color: #3c5d5d;
168
- font-weight: bold;
169
- }
170
- .highlight .ni {
171
- color: #800080;
172
- }
173
- .highlight .ne {
174
- color: #990000;
175
- font-weight: bold;
176
- }
177
- .highlight .nf {
178
- color: #990000;
179
- font-weight: bold;
180
- }
181
- .highlight .nl {
182
- color: #990000;
183
- font-weight: bold;
184
- }
185
- .highlight .nn {
186
- color: #555555;
187
- }
188
- .highlight .nt {
189
- color: #000080;
190
- }
191
- .highlight .vc {
192
- color: #008080;
193
- }
194
- .highlight .vg {
195
- color: #008080;
196
- }
197
- .highlight .vi {
198
- color: #008080;
199
- }
200
- .highlight .nv {
201
- color: #008080;
202
- }
203
- .highlight .ow {
204
- color: #000000;
205
- font-weight: bold;
206
- }
207
- .highlight .o {
208
- color: #000000;
209
- font-weight: bold;
210
- }
211
- .highlight .w {
212
- color: #bbbbbb;
213
- }
214
- .highlight {
215
- background-color: #f8f8f8;
216
- }</style>
217
- </head>
218
-
219
- <body>
220
- <div class="chapter">
221
- <h2 id="getting-started">Getting Started</h2>
222
-
223
- <p>This guide is designed for beginners who want to get started with Kitabu from scratch. However, to get the most out of it, you need to have some prerequisites installed:</p>
224
-
225
- <ul>
226
- <li>The <a href="http://ruby-lang.org">Ruby</a> interpreter version 2.0.0 or greater.</li>
227
- <li>The <a href="http://princexml.com">PrinceXML</a> converter version 9.0 or greater.</li>
228
- <li>The <a href="http://www.amazon.com/gp/feature.html?docId=1000765211">KindleGen</a> converter.</li>
229
- </ul>
230
-
231
- <h3 id="installing-ruby">Installing Ruby</h3>
232
-
233
- <p>To install Ruby, consider using <a href="http://rvm.io">RVM</a> or <a href="http://rbenv.org">rbenv</a>, both available for Mac OSX and Linux distros. If you’re running a Windows, well, I can’t help you. I don’t even know if Kitabu runs over Windows boxes, so if you find any bugs, make sure you <a href="http://github.com/fnando/kitabu/issues">let me know</a>.</p>
234
-
235
- <h3 id="installing-princexml">Installing PrinceXML</h3>
236
-
237
- <p><a href="http://princexml.com">PrinceXML</a> is the best HTML to PDF converter available. You can use advanced CSS features to style your book in any way you want. But good things don’t come for free, and PrinceXML is no exception. The Professional License, which you grant you a installation on a single computer by a single user costs 495USD. If you don’t like the price tag, consider using <a href="http://docraptor.com">DocRaptor</a> when you’re ready to publish your book.</p>
238
-
239
- <p>To install PrinceXML, go to the website and download the correct version for your platform; you can choose from Mac OSX, to Linux and Windows.</p>
240
-
241
- <h3 id="installing-kindlegen">Installing KindleGen</h3>
242
-
243
- <p>KindleGen is the command-line tool that allows you to convert e-pubs into <code>.mobi</code> files. You can’t sell these files, though.<sup id="fnref1"><a href="section_4.html#fn1" rel="footnote">1</a></sup> So if that’s the case, consider using <a href="http://calibre-ebook.com/">Calibre</a> for this task.<sup id="fnref2"><a href="section_0.html#fn2" rel="footnote">2</a></sup></p>
244
-
245
- <p>If you’re running <a href="http://brew.sh">Homebrew</a> on the Mac OSX, you can install it with <code>brew install kindlegen</code>. Go to <a href="http://www.amazon.com/gp/feature.html?docId=1000765211">KindleGen’s website</a> and download the appropriate installer otherwise.</p>
246
-
247
- <div class="footnotes">
248
- <hr />
249
- <ol>
250
-
251
- <li id="fn1">
252
- <p>You can, but that would be a violation of Amazon’s terms of use. <a href="section_4.html#fnref1" rev="footnote">↩</a></p>
253
- </li>
254
-
255
- <li id="fn2">
256
- <p>Calibre is not perfect, but does a good job. <a href="section_0.html#fnref2" rev="footnote">↩</a></p>
257
- </li>
258
-
259
- </ol>
260
- </div>
261
-
262
-
263
-
264
- </div>
265
- </body>
266
- </html>