gh-preview 1.0.1 → 1.0.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.travis.yml +3 -4
- data/Rakefile +1 -0
- data/bin/gh-preview +1 -1
- data/lib/gh_preview/config.rb +4 -7
- data/lib/gh_preview/converter.rb +12 -15
- data/lib/gh_preview/version.rb +1 -1
- data/spec/spec_helper.rb +2 -3
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 5bc8e42509d3b867406d43355408042c4e5564c8
|
4
|
+
data.tar.gz: b1e60332bfd48625c74e3dad264b436417a3fc29
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 33b38150a7c1cff5537c6d28fa418c7bed49c181455ef65de886d68c3874130df80f10a24ddd7bae392b20ccdc7f5ddd535fdf054920d312b556f6c576f8e2f7
|
7
|
+
data.tar.gz: 87d083671e0180c008ae60861286d0e462b162c42ee5a126444b551b7140e33e815658408bb0ce6e5fa8c012780464b6447b300ca527f9c9c42df6ef53b844b3
|
data/.travis.yml
CHANGED
data/Rakefile
CHANGED
data/bin/gh-preview
CHANGED
data/lib/gh_preview/config.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
module GhPreview
|
2
2
|
module Config
|
3
|
-
|
3
|
+
module_function
|
4
4
|
|
5
5
|
NAME = 'GitHub Preview'
|
6
6
|
GITHUB_URL = 'https://github.com/jbox-web/gh-preview'
|
@@ -16,12 +16,9 @@ module GhPreview
|
|
16
16
|
end
|
17
17
|
|
18
18
|
|
19
|
-
|
20
|
-
|
21
|
-
|
22
|
-
def gem_path
|
23
|
-
Gem::Specification.find_by_name('gh-preview').gem_dir
|
24
|
-
end
|
19
|
+
def gem_path
|
20
|
+
Gem::Specification.find_by_name('gh-preview').gem_dir
|
21
|
+
end
|
25
22
|
|
26
23
|
end
|
27
24
|
end
|
data/lib/gh_preview/converter.rb
CHANGED
@@ -3,29 +3,26 @@ require 'task_list/filter'
|
|
3
3
|
|
4
4
|
module GhPreview
|
5
5
|
module Converter
|
6
|
-
|
6
|
+
module_function
|
7
7
|
|
8
8
|
def to_html(markdown)
|
9
9
|
pipeline.call(markdown)[:output].to_s
|
10
10
|
end
|
11
11
|
|
12
12
|
|
13
|
-
|
14
|
-
|
15
|
-
|
16
|
-
def pipeline
|
17
|
-
HTML::Pipeline.new(filters)
|
18
|
-
end
|
13
|
+
def pipeline
|
14
|
+
HTML::Pipeline.new(filters)
|
15
|
+
end
|
19
16
|
|
20
17
|
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
18
|
+
def filters
|
19
|
+
[
|
20
|
+
GhPreview::RedcarpetFilter,
|
21
|
+
TaskList::Filter,
|
22
|
+
HTML::Pipeline::AutolinkFilter,
|
23
|
+
HTML::Pipeline::TableOfContentsFilter
|
24
|
+
]
|
25
|
+
end
|
29
26
|
|
30
27
|
end
|
31
28
|
end
|
data/lib/gh_preview/version.rb
CHANGED
data/spec/spec_helper.rb
CHANGED
@@ -7,10 +7,9 @@ require 'codeclimate-test-reporter'
|
|
7
7
|
require 'support/helper'
|
8
8
|
|
9
9
|
## Configure SimpleCov
|
10
|
-
SimpleCov.formatter = SimpleCov::Formatter::MultiFormatter[
|
10
|
+
SimpleCov.formatter = SimpleCov::Formatter::MultiFormatter.new([
|
11
11
|
SimpleCov::Formatter::HTMLFormatter,
|
12
|
-
|
13
|
-
]
|
12
|
+
])
|
14
13
|
|
15
14
|
## Start Simplecov
|
16
15
|
SimpleCov.start do
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gh-preview
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.0.
|
4
|
+
version: 1.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nicolas Rodriguez
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-12-28 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rake
|
@@ -339,7 +339,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
339
339
|
version: '0'
|
340
340
|
requirements: []
|
341
341
|
rubyforge_project:
|
342
|
-
rubygems_version: 2.
|
342
|
+
rubygems_version: 2.5.2
|
343
343
|
signing_key:
|
344
344
|
specification_version: 4
|
345
345
|
summary: A small gem to preview GitHub README files
|