ffnpdf 0.0.5 → 0.0.6

Sign up to get free protection for your applications and to get access to all the features.
data/README.md CHANGED
@@ -6,9 +6,15 @@ This gem scrapes stories from FanFiction.net and generates LaTeX PDFs. Polished
6
6
 
7
7
  ## Installation
8
8
 
9
- To install this stupid gem:
9
+ Ruby hackers already know how to install this stupid gem. But for everyone else, here's how to install it in Ubuntu.
10
10
 
11
- gem install ffnpdf
11
+ First install [Ruby](http://www.ruby-lang.org). I'm guessing the gem won't work with ruby 1.8 so you'll need to install ruby 1.9:
12
+
13
+ sudo apt-get install ruby1.9.1 ruby1.9.1-dev build-essential libxml2 libxml2-dev libxslt1-dev
14
+
15
+ Then install the gem via `gem install`:
16
+
17
+ sudo gem install ffnpdf
12
18
 
13
19
  It also requires [pandoc](http://johnmacfarlane.net/pandoc/) as well as a bunch of extra stuff related to LaTeX/XeTeX. In Ubuntu, you can install this using the following command:
14
20
 
@@ -58,6 +64,10 @@ This command
58
64
 
59
65
  This command does only the second step of the Build i.e. converts `combined.md` to `combined.pdf`.
60
66
 
67
+ ## How-To Videos
68
+
69
+ I've made a YouTube playlist with demos and how-tos [here](http://www.youtube.com/playlist?list=PLA7C6F157E1651A69).
70
+
61
71
  ## Known Issues
62
72
 
63
73
  **Page numbering in bookmark is incorrect for stories with long Table of Contents**
@@ -71,7 +71,7 @@ module Ffnpdf
71
71
 
72
72
  doc = chapter1.doc
73
73
 
74
- title = doc.xpath("//div/div/b")[0].text
74
+ title = doc.xpath("//div/table//b")[0].text
75
75
  author = doc.xpath("//div/table//a[not(@title or @onclick)]")[0].text
76
76
 
77
77
  generate_template(title, author, get_doc_date(doc))
@@ -89,7 +89,7 @@ module Ffnpdf
89
89
  end
90
90
 
91
91
  def get_doc_date(doc)
92
- parsing = doc.xpath('//div[@style="padding-left:1em;padding-right:1em;padding-top:0.5em;"]')[0].text
92
+ parsing = doc.xpath('//div[@style="color:gray;"]')[0].text
93
93
  match = /Updated: (.{8})/.match parsing
94
94
  if match
95
95
  return Date.strptime(match[1], "%m-%d-%y").strftime("%d %B %Y")
@@ -1,3 +1,3 @@
1
1
  module Ffnpdf
2
- VERSION = "0.0.5"
2
+ VERSION = "0.0.6"
3
3
  end
@@ -2,7 +2,7 @@ require 'spec_helper'
2
2
 
3
3
  describe Ffnpdf do
4
4
  it "has the correct version" do
5
- Ffnpdf::VERSION.should == "0.0.5"
5
+ Ffnpdf::VERSION.should == "0.0.6"
6
6
  end
7
7
  end
8
8
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ffnpdf
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.5
4
+ version: 0.0.6
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,11 +9,11 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-02-16 00:00:00.000000000 Z
12
+ date: 2012-06-16 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rspec
16
- requirement: &82658630 !ruby/object:Gem::Requirement
16
+ requirement: !ruby/object:Gem::Requirement
17
17
  none: false
18
18
  requirements:
19
19
  - - ! '>='
@@ -21,10 +21,15 @@ dependencies:
21
21
  version: '0'
22
22
  type: :development
23
23
  prerelease: false
24
- version_requirements: *82658630
24
+ version_requirements: !ruby/object:Gem::Requirement
25
+ none: false
26
+ requirements:
27
+ - - ! '>='
28
+ - !ruby/object:Gem::Version
29
+ version: '0'
25
30
  - !ruby/object:Gem::Dependency
26
31
  name: test_notifier
27
- requirement: &82658340 !ruby/object:Gem::Requirement
32
+ requirement: !ruby/object:Gem::Requirement
28
33
  none: false
29
34
  requirements:
30
35
  - - ! '>='
@@ -32,10 +37,15 @@ dependencies:
32
37
  version: '0'
33
38
  type: :development
34
39
  prerelease: false
35
- version_requirements: *82658340
40
+ version_requirements: !ruby/object:Gem::Requirement
41
+ none: false
42
+ requirements:
43
+ - - ! '>='
44
+ - !ruby/object:Gem::Version
45
+ version: '0'
36
46
  - !ruby/object:Gem::Dependency
37
47
  name: autotest
38
- requirement: &82658070 !ruby/object:Gem::Requirement
48
+ requirement: !ruby/object:Gem::Requirement
39
49
  none: false
40
50
  requirements:
41
51
  - - ! '>='
@@ -43,10 +53,15 @@ dependencies:
43
53
  version: '0'
44
54
  type: :development
45
55
  prerelease: false
46
- version_requirements: *82658070
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ none: false
58
+ requirements:
59
+ - - ! '>='
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
47
62
  - !ruby/object:Gem::Dependency
48
63
  name: nokogiri
49
- requirement: &82657820 !ruby/object:Gem::Requirement
64
+ requirement: !ruby/object:Gem::Requirement
50
65
  none: false
51
66
  requirements:
52
67
  - - ! '>='
@@ -54,10 +69,15 @@ dependencies:
54
69
  version: '0'
55
70
  type: :development
56
71
  prerelease: false
57
- version_requirements: *82657820
72
+ version_requirements: !ruby/object:Gem::Requirement
73
+ none: false
74
+ requirements:
75
+ - - ! '>='
76
+ - !ruby/object:Gem::Version
77
+ version: '0'
58
78
  - !ruby/object:Gem::Dependency
59
79
  name: httparty
60
- requirement: &82657380 !ruby/object:Gem::Requirement
80
+ requirement: !ruby/object:Gem::Requirement
61
81
  none: false
62
82
  requirements:
63
83
  - - ! '>='
@@ -65,10 +85,15 @@ dependencies:
65
85
  version: '0'
66
86
  type: :development
67
87
  prerelease: false
68
- version_requirements: *82657380
88
+ version_requirements: !ruby/object:Gem::Requirement
89
+ none: false
90
+ requirements:
91
+ - - ! '>='
92
+ - !ruby/object:Gem::Version
93
+ version: '0'
69
94
  - !ruby/object:Gem::Dependency
70
95
  name: nokogiri
71
- requirement: &82657020 !ruby/object:Gem::Requirement
96
+ requirement: !ruby/object:Gem::Requirement
72
97
  none: false
73
98
  requirements:
74
99
  - - ! '>='
@@ -76,10 +101,15 @@ dependencies:
76
101
  version: '0'
77
102
  type: :runtime
78
103
  prerelease: false
79
- version_requirements: *82657020
104
+ version_requirements: !ruby/object:Gem::Requirement
105
+ none: false
106
+ requirements:
107
+ - - ! '>='
108
+ - !ruby/object:Gem::Version
109
+ version: '0'
80
110
  - !ruby/object:Gem::Dependency
81
111
  name: httparty
82
- requirement: &82656690 !ruby/object:Gem::Requirement
112
+ requirement: !ruby/object:Gem::Requirement
83
113
  none: false
84
114
  requirements:
85
115
  - - ! '>='
@@ -87,7 +117,12 @@ dependencies:
87
117
  version: '0'
88
118
  type: :runtime
89
119
  prerelease: false
90
- version_requirements: *82656690
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ none: false
122
+ requirements:
123
+ - - ! '>='
124
+ - !ruby/object:Gem::Version
125
+ version: '0'
91
126
  description: Scrapes a story off FF.net, converts it to Markdown, and turns it to
92
127
  PDF with LaTeX
93
128
  email:
@@ -138,7 +173,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
138
173
  version: '0'
139
174
  requirements: []
140
175
  rubyforge_project: ffnpdf
141
- rubygems_version: 1.8.10
176
+ rubygems_version: 1.8.24
142
177
  signing_key:
143
178
  specification_version: 3
144
179
  summary: PDF generator for FF.net stories