tdiary-style-gfm 0.3.0 → 0.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 6d08896f8c420b7cef71a6bc5e2f7d7e96109c8e
4
- data.tar.gz: ee091d95476362f46cd2d8ceb289990be65aace6
3
+ metadata.gz: 84c351385fbace2c88da6e58abc74fe0802b7040
4
+ data.tar.gz: c4742ac8975495f1309127486ab8f2a5e4263676
5
5
  SHA512:
6
- metadata.gz: 473081f8f4f360d3f0688426ef9398e66e15cb6972c96690edae0ef739b51eaa7fab1aa02762eeb31d7221d6c1b5d1af1c40db8ae1574569cb6f6587d4c07187
7
- data.tar.gz: 845992b4f857fae7ba795161afcf6a943ba4f51951801f5b37e0c014a759113d2d9d179ec3448cbd32927718eef9d99c75a8b6f7dff9f3c17a15bf5d2804b349
6
+ metadata.gz: 157321f0e60906168fa50a190237ffc22be727085a1b22ba4d852369cd7b07d910288e7eedfd08f3dcd409e230040ab12cd59494aae71a78093143e0ff94907e
7
+ data.tar.gz: 78f8fb6def0b3de1742669a8cb2203942f668eb10e7f8078391b5e710fe0bacb7dfa31465530e64384b0cd002489507e874f92b5966c0dcfece530c6ff1772fe
data/README.md CHANGED
@@ -6,7 +6,7 @@
6
6
 
7
7
  ## Installation
8
8
 
9
- Add this line to your application's Gemfile:
9
+ Add this line to your tDiary's Gemfile.local:
10
10
 
11
11
  gem 'tdiary-style-gfm'
12
12
 
@@ -14,10 +14,6 @@ And then execute:
14
14
 
15
15
  $ bundle
16
16
 
17
- Or install it yourself as:
18
-
19
- $ gem install tdiary-style-gfm
20
-
21
17
  ## Usage
22
18
 
23
19
  if you want to use this style, add @style into tdiary.conf below:
@@ -65,8 +65,8 @@ module TDiary
65
65
  # 2. Apply markdown conversion
66
66
  r = GitHub::Markdown.to_html(r, :gfm) do |code, lang|
67
67
  begin
68
- formatter = Rouge::Formatters::HTML.new(css_class: 'highlight')
69
- lexer = Rouge::Lexers.const_get(lang.capitalize.to_sym).new
68
+ formatter = Rouge::Formatters::HTMLPygments.new(Rouge::Formatters::HTML.new, 'highlight')
69
+ lexer = Rouge::Lexer.find(lang)
70
70
  formatter.format(lexer.lex(code))
71
71
  rescue Exception => ex
72
72
  "<div class=\"highlight\"><pre>#{CGI.escapeHTML(code)}</pre></div>"
@@ -1,7 +1,7 @@
1
1
  module TDiary
2
2
  module Style
3
3
  module Gfm
4
- VERSION = "0.3.0"
4
+ VERSION = "0.4.0"
5
5
  end
6
6
  end
7
7
  end
@@ -205,7 +205,6 @@ http://example.com is example.com
205
205
  <h3><%= subtitle_proc( Time.at( 1041346800 ), "subTitle" ) %></h3>
206
206
  <pre class="highlight"><code><span class="vi">@foo</span>
207
207
  </code></pre>
208
-
209
208
  <p><a href="http://example.com">http://example.com</a> is example.com</p>
210
209
  <%=section_leave_proc( Time.at( 1041346800 ) )%>
211
210
  </div>
@@ -328,8 +327,7 @@ http://example.com is example.com
328
327
  <pre class="highlight"><code> <span class="k">def</span> <span class="nf">class</span>
329
328
  <span class="vi">@foo</span> <span class="o">=</span> <span class="s1">'bar'</span>
330
329
  <span class="k">end</span>
331
- </code></pre>
332
- <%=section_leave_proc( Time.at( 1041346800 ) )%>
330
+ </code></pre><%=section_leave_proc( Time.at( 1041346800 ) )%>
333
331
  </div>
334
332
  EOF
335
333
  end
@@ -449,7 +447,7 @@ http://example.com is example.com
449
447
  <div class="section">
450
448
  <%=section_enter_proc( Time.at( 1041346800 ) )%>
451
449
  <h3><%= subtitle_proc( Time.at( 1041346800 ), "subTitle" ) %></h3>
452
- <p><img src='http://www.emoji-cheat-sheet.com/graphics/emojis/sushi.png' width='20' height='20' title='sushi' alt='sushi' class='emoji' /> は美味しい</p>
450
+ <p><img src='http://www.webpagefx.com/tools/emoji-cheat-sheet/graphics/emojis/sushi.png' width='20' height='20' title='sushi' alt='sushi' class='emoji' /> は美味しい</p>
453
451
  <%=section_leave_proc( Time.at( 1041346800 ) )%>
454
452
  </div>
455
453
  EOF
@@ -19,7 +19,7 @@ Gem::Specification.new do |spec|
19
19
  spec.require_paths = ["lib"]
20
20
 
21
21
  spec.add_dependency 'github-markdown'
22
- spec.add_dependency 'rouge'
22
+ spec.add_dependency 'rouge', '>= 2.0'
23
23
  spec.add_dependency 'twitter-text'
24
24
  spec.add_dependency 'emot'
25
25
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tdiary-style-gfm
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.0
4
+ version: 0.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - SHIBATA Hiroshi
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-01-05 00:00:00.000000000 Z
11
+ date: 2016-08-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: github-markdown
@@ -30,14 +30,14 @@ dependencies:
30
30
  requirements:
31
31
  - - ">="
32
32
  - !ruby/object:Gem::Version
33
- version: '0'
33
+ version: '2.0'
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - ">="
39
39
  - !ruby/object:Gem::Version
40
- version: '0'
40
+ version: '2.0'
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: twitter-text
43
43
  requirement: !ruby/object:Gem::Requirement
@@ -148,11 +148,10 @@ required_rubygems_version: !ruby/object:Gem::Requirement
148
148
  version: '0'
149
149
  requirements: []
150
150
  rubyforge_project:
151
- rubygems_version: 2.5.1
151
+ rubygems_version: 2.6.6
152
152
  signing_key:
153
153
  specification_version: 4
154
154
  summary: GFM Style for tDiary
155
155
  test_files:
156
156
  - spec/spec_helper.rb
157
157
  - spec/tdiary/style/gfm_spec.rb
158
- has_rdoc: