pandocomatic 0.2.0.1 → 0.2.0.2

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: '0394005bd3b640c3aa35feace7ba875e7aca6f06'
4
- data.tar.gz: d445c734dcee87ca77ba202ffd8fd6a87bd6c8cb
3
+ metadata.gz: 653f8e6c1f7f11317cb4c866f56e93eb724b5f66
4
+ data.tar.gz: 25b56957a923d4a9a5d5d5f70a566fbbc106d0d4
5
5
  SHA512:
6
- metadata.gz: 45f4fb78309fbcfd4cf776dfe935e1e94e0d3d616023c4eeb51b1c570f2412ff676dabd795e9332f527868cbb0641160fb5fe8ec659022e9e88c65518a6120bf
7
- data.tar.gz: 1e9a3d78c2f0be0c9a86341864788ebcd1d7acb9bcc03356f16a220f646e8f243dac7e1cb919120aabd839d33a323bc2a1e156f8f53f59cddfaf35061975f632
6
+ metadata.gz: 4988f18e8e4f5a836e56582e0bafd23faaac1ecf7bed8a7821ca94053f4099d742e55e9cbb9a8d47a3479049932b287618ee4b5a293c38a385ea0ce2ce1047ff
7
+ data.tar.gz: 21fa2d133ade10f877ab730fda87f1c813d11e05e374e582a5588a18dccf51bd95d90864ff22b6aafddb3f0d7b9fa97772c74cb5158c7e3a293bebe59fdc20d4
@@ -74,7 +74,11 @@ module Pandocomatic
74
74
  # configuration files, unless explicitly set to not skip via the
75
75
  # "unskip" option
76
76
 
77
- @settings = {'skip' => ['.*', 'pandocomatic.yaml']}
77
+ @settings = {
78
+ 'skip' => ['.*', 'pandocomatic.yaml'],
79
+ 'recursive' => true,
80
+ 'follow-links' => false
81
+ }
78
82
 
79
83
  @templates = {}
80
84
  @convert_patterns = {}
@@ -270,7 +274,7 @@ module Pandocomatic
270
274
  updated_path = Configuration.which path
271
275
  end
272
276
 
273
- if updated_path.nil? or not updated_path.start_with? '/' then
277
+ if updated_path.nil? or not check_executable then
274
278
  # refers to data-dir
275
279
  updated_path = File.join @data_dir, path
276
280
  end
@@ -484,8 +488,8 @@ module Pandocomatic
484
488
  ENV['PATH'].split(File::PATH_SEPARATOR).each do |path|
485
489
  exts.each { |ext|
486
490
  exe = File.join(path, "#{cmd}#{ext}")
487
- return exe if File.executable?(exe) &&
488
- !File.directory?(exe)
491
+ return exe if File.executable?(exe) and
492
+ not File.directory?(exe)
489
493
  }
490
494
  end
491
495
  return nil
@@ -50,7 +50,7 @@ module Pandocomatic
50
50
  ERROR_STATUS = 1266 # This is the sum of the ascii values of the characters in 'pandocomatic'
51
51
 
52
52
  # Pandocomatic's current version
53
- VERSION = [0, 2, 0, 1]
53
+ VERSION = [0, 2, 0, 2]
54
54
 
55
55
  # Pandocomatic's default configuration file
56
56
  CONFIG_FILE = 'pandocomatic.yaml'
@@ -168,6 +168,12 @@ module Pandocomatic
168
168
  # No data-dir option given: try to find the default one from pandoc
169
169
  begin
170
170
  data_dir = Paru::Pandoc.info()[:data_dir]
171
+
172
+ # If pandoc's data dir does not exist, however, fall back
173
+ # to the current directory
174
+ unless File.exist? File.absolute_path(data_dir)
175
+ data_dir = Dir.pwd
176
+ end
171
177
  rescue Paru::Error => e
172
178
  # If pandoc cannot be run, continuing probably does not work out
173
179
  # anyway, so raise pandoc error
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pandocomatic
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.0.1
4
+ version: 0.2.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Huub de Beer
@@ -19,7 +19,7 @@ dependencies:
19
19
  version: 0.2.5
20
20
  - - ">="
21
21
  - !ruby/object:Gem::Version
22
- version: 0.2.5.10
22
+ version: 0.2.5.11
23
23
  type: :runtime
24
24
  prerelease: false
25
25
  version_requirements: !ruby/object:Gem::Requirement
@@ -29,7 +29,7 @@ dependencies:
29
29
  version: 0.2.5
30
30
  - - ">="
31
31
  - !ruby/object:Gem::Version
32
- version: 0.2.5.10
32
+ version: 0.2.5.11
33
33
  - !ruby/object:Gem::Dependency
34
34
  name: trollop
35
35
  requirement: !ruby/object:Gem::Requirement
@@ -154,7 +154,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
154
154
  requirements:
155
155
  - pandoc, a universal document converer <http://pandoc.org>
156
156
  rubyforge_project:
157
- rubygems_version: 2.5.2
157
+ rubygems_version: 2.6.11
158
158
  signing_key:
159
159
  specification_version: 4
160
160
  summary: Automating the use of pandoc