paru 0.4.2.1 → 0.4.2.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 +4 -4
- data/lib/paru.rb +1 -1
- data/lib/paru/filter/table.rb +5 -5
- data/lib/paru/pandoc_options_version_2.yaml +6 -5
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fd011d45f260f628085c1309382ee4d0975da0fb04c65e3cbc486cfc4bad108a
|
4
|
+
data.tar.gz: 87091ed969e5696f89da14957824ca58678d495e371662529ea38e0ad3c14e9c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3c8f667cc992e1b303f6d98f91566ad2ed5c4ee540560bf305c93ad70f06a6b9be857ca5aa679ad68d1270fedd21a275340a492426292de7deae991079da6ed4
|
7
|
+
data.tar.gz: 36cec3b8820d887b436d989a01f19ccf869ad72e91661b58e66c43af52b94baf37a88bb011c629473e33a22a1fdd712314e35792a5d3e385111a74b7034c4f33
|
data/lib/paru.rb
CHANGED
data/lib/paru/filter/table.rb
CHANGED
@@ -86,7 +86,7 @@ module Paru
|
|
86
86
|
#
|
87
87
|
# @return [String[][]] This Table as a 2D array of cells
|
88
88
|
# represented by their markdown strings.
|
89
|
-
def to_array(
|
89
|
+
def to_array(config = {})
|
90
90
|
headers = if config.has_key? :headers then config[:headers] else false end
|
91
91
|
footers = if config.has_key? :footers then config[:footers] else false end
|
92
92
|
|
@@ -111,9 +111,9 @@ module Paru
|
|
111
111
|
#
|
112
112
|
# @param filename [String] filename to write to
|
113
113
|
# @param config [Hash] See #to_array for config options
|
114
|
-
def to_file(filename,
|
114
|
+
def to_file(filename, config = {})
|
115
115
|
CSV.open(filename, "wb") do |csv|
|
116
|
-
to_array(config).each {|row| csv << row}
|
116
|
+
to_array(**config).each {|row| csv << row}
|
117
117
|
end
|
118
118
|
end
|
119
119
|
|
@@ -130,7 +130,7 @@ module Paru
|
|
130
130
|
# default to false.
|
131
131
|
#
|
132
132
|
# @return [Table]
|
133
|
-
def self.from_array(data,
|
133
|
+
def self.from_array(data, config = {})
|
134
134
|
# With the updated Table definition, it has become complicated
|
135
135
|
# to construct a table manually. It has gotten easier to just
|
136
136
|
# construct a string containing a table in Pandoc's markdown and
|
@@ -180,7 +180,7 @@ module Paru
|
|
180
180
|
# @param config [Hash] See #from_file for details
|
181
181
|
#
|
182
182
|
# @return [Table]
|
183
|
-
def self.from_file(filename,
|
183
|
+
def self.from_file(filename, config = {})
|
184
184
|
data = []
|
185
185
|
CSV.foreach(filename) do |row|
|
186
186
|
data << row
|
@@ -44,8 +44,10 @@ help: true
|
|
44
44
|
# General reader options:
|
45
45
|
#####
|
46
46
|
shift_heading_level_by: 1
|
47
|
+
base_header_level: 1
|
48
|
+
strip_empty_paragraphs: true
|
47
49
|
indented_code_classes: ""
|
48
|
-
default_image_extension: ""
|
50
|
+
default_image_extension: "png"
|
49
51
|
file_scope: true
|
50
52
|
filter: [""]
|
51
53
|
lua_filter: [""]
|
@@ -68,7 +70,6 @@ eol: "native"
|
|
68
70
|
dpi: 96
|
69
71
|
wrap: "auto"
|
70
72
|
columns: 78
|
71
|
-
strip_comments: true
|
72
73
|
toc: true
|
73
74
|
table_of_contents: true
|
74
75
|
toc_depth: 3
|
@@ -91,7 +92,8 @@ html_q_tags: true
|
|
91
92
|
ascii: true
|
92
93
|
reference_links: true
|
93
94
|
reference_location: "block"
|
94
|
-
|
95
|
+
markdown_headings: "atx"
|
96
|
+
atx_headers: false
|
95
97
|
top_level_division: "section"
|
96
98
|
number_sections: true
|
97
99
|
number_offset: 2
|
@@ -99,7 +101,6 @@ listings: true
|
|
99
101
|
incremental: true
|
100
102
|
slide_level: 1
|
101
103
|
section_divs: true
|
102
|
-
default_image_extension: "png"
|
103
104
|
email_obfuscation: "none"
|
104
105
|
id_prefix: ""
|
105
106
|
title_prefix: ""
|
@@ -119,7 +120,7 @@ pdf_engine_opt: [""]
|
|
119
120
|
citeproc: true
|
120
121
|
bibliography: ""
|
121
122
|
csl: ""
|
122
|
-
citation_abbreviations:
|
123
|
+
citation_abbreviations: ""
|
123
124
|
natbib: true
|
124
125
|
biblatex: true
|
125
126
|
#####
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: paru
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.2.
|
4
|
+
version: 0.4.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Huub de Beer
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2021-08-12 00:00:00.000000000 Z
|
12
12
|
dependencies: []
|
13
13
|
description: Control pandoc with Ruby and write pandoc filters in Ruby
|
14
14
|
email: Huub@heerdebeer.org
|