pandoc-ruby 0.7.2 → 0.7.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 17b3f81bb4b27fe9caf0f61c14043084c0f02776
4
- data.tar.gz: aa1251098ed96b13d1690f17055f230aa50bbc29
3
+ metadata.gz: e19f0c6cc6cd66943e74800edbc5bb43c551db7a
4
+ data.tar.gz: 9fef27d8c653f5386ec638b785396c97a0362c2a
5
5
  SHA512:
6
- metadata.gz: 9dbf61c66d2e5e4f2bf6c7f16d587b36f99d90fea3c7a3d4d5ea84aac57b2b54da11066edd88f159a71f28c00d3827fa8a6a3e21105ac876c0688bb1ada53bae
7
- data.tar.gz: 7dc6c106893b19897971b80a217d3ca4fe8f897ef5e627d4ee52d65b1e7cc07c332c60c83dabc4ab5fb4fe8bed2a4142a3445fb25cb2f222e9ed2199820204b7
6
+ metadata.gz: 69b11985fe7068135927b4a2a1219b577cf1fae4bdbcc26094f6a3dc265e9c3aea4af84c84fbd6ef7cece2c39ca878a1e33543f0bf35a97c4df42bd3ab0d83c6
7
+ data.tar.gz: f7569bb7b4ae538fe4b2b606a9ad9ef4086e55d51d919d46c18259e6aed83a071f32eab03e13995a7337da494882355cbf7e4541bc6c89d97ec80fe49a482b52
data/lib/pandoc-ruby.rb CHANGED
@@ -183,8 +183,8 @@ private
183
183
  # and written to, then read back into the program as a string, then the
184
184
  # temp file is closed and unlinked.
185
185
  def convert_binary
186
+ tmp_file = Tempfile.new('pandoc-conversion')
186
187
  begin
187
- tmp_file = Tempfile.new('pandoc-conversion')
188
188
  self.options += [{:output => tmp_file.path}]
189
189
  self.option_string = "#{self.option_string} --output #{tmp_file.path}"
190
190
  execute(command_with_options)
@@ -221,7 +221,7 @@ private
221
221
  def prepare_options(opts = [])
222
222
  opts.inject('') do |string, (option, value)|
223
223
  string += case
224
- when value != nil
224
+ when value
225
225
  create_option(option, value)
226
226
  when option.respond_to?(:each_pair)
227
227
  prepare_options(option)
@@ -238,15 +238,15 @@ private
238
238
  return if !flag
239
239
  set_pandoc_ruby_options(flag, argument)
240
240
  if !!argument
241
- "#{option_flag(flag)} #{argument}"
241
+ "#{format_flag(flag)} #{argument}"
242
242
  else
243
- option_flag(flag)
243
+ format_flag(flag)
244
244
  end
245
245
  end
246
246
 
247
247
  # Formats an option flag in order to be used with the pandoc command line
248
248
  # tool.
249
- def option_flag(flag)
249
+ def format_flag(flag)
250
250
  if flag.length == 1
251
251
  " -#{flag}"
252
252
  else
data/pandoc-ruby.gemspec CHANGED
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = "pandoc-ruby"
8
- s.version = "0.7.2"
8
+ s.version = "0.7.3"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["William Melody"]
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pandoc-ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.7.2
4
+ version: 0.7.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - William Melody