mdless 2.0.16 → 2.0.17

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
  SHA256:
3
- metadata.gz: 3c2164454fac4fd82af1ef1594166585de749e87cca73c7c83c25c38c3288dd9
4
- data.tar.gz: 7b2008f35bd4ddc66fac4438fda186964a538ef0715739410b0b4c429323d96b
3
+ metadata.gz: 9d80ed856b198db9752c7ac96f964b2b2e05f7706288aef8fbf901417952a967
4
+ data.tar.gz: ad820a3d6a885fc2f50decf0b6f52444d267ca84f9b3bbf5f3945cce8413df15
5
5
  SHA512:
6
- metadata.gz: e119669e34faaa577b8956eb5817f3b391887108e425b0cb5fcb630f14ea5aa6ffa3282c531c7602fc07912c7a75299bd10169d9ba95375485c664226f30a930
7
- data.tar.gz: caae8bb09f9c48e25ad144b401ff74a58a379bb5b10b63ffa66c3afef707ccd39af6699a7301c3467ba180395d8e4ab025cd9a10900d44ae7dfafadde2954fa3
6
+ metadata.gz: 60dcb01d030a0115bb49616dd507c53a2b605dc8f0d28a194092150489c36adfb33450b7ba3c87f54b4048bc6b5114cfce2b914c240e129a2cbf36f4d76ec420
7
+ data.tar.gz: b67938b0f651c324845d107074f04a647d8b46c60ee09386be627a1ad2d5ff50b08f31ef9a12984a6a209aeaa7d632cb47313c425c01a47f49b6b72b7a1f6022
data/README.md CHANGED
@@ -60,8 +60,6 @@ The pager used is determined by system configuration in this order of preference
60
60
  -h, --help Display this screen
61
61
  -i, --images=TYPE Include [local|remote (both)|none] images in output (requires chafa or imgcat, default none).
62
62
  -I, --all-images Include local and remote images in output (requires imgcat or chafa)
63
- --syntax Syntax highlight code blocks
64
- --links=FORMAT Link style ([inline, reference, paragraph], default inline, "paragraph" will position reference links after each paragraph)
65
63
  -l, --list List headers in document and exit
66
64
  -p, --[no-]pager Formatted output to pager (default on)
67
65
  -P Disable pager (same as --no-pager)
@@ -71,6 +69,14 @@ The pager used is determined by system configuration in this order of preference
71
69
  -v, --version Display version number
72
70
  -w, --width=COLUMNS Column width to format for (default: terminal width)
73
71
  --[no-]inline_footnotes Display footnotes immediately after the paragraph that references them
72
+ --[no-]intra-emphasis Parse emphasis inside of words (e.g. Mark_down_)
73
+ --[no-]lax-spacing Allow lax spacing
74
+ --links=FORMAT Link style ([inline, reference, paragraph], default inline,
75
+ "paragraph" will position reference links after each paragraph)
76
+ --[no-]syntax Syntax highlight code blocks
77
+ --taskpaper=OPTION Highlight TaskPaper format (true|false|auto)
78
+ --update_config Update the configuration file with new keys and current command line options
79
+ --[no-]wiki-links Highlight [[wiki links]]
74
80
 
75
81
  ## Configuration
76
82
 
@@ -61,6 +61,7 @@ module CLIMarkdown
61
61
  @log.warn('images turned on but imgcat/chafa not found')
62
62
  end
63
63
  end
64
+
64
65
  opts.on('-I', '--all-images', 'Include local and remote images in output (requires imgcat or chafa)') do
65
66
  if exec_available('imgcat') || exec_available('chafa') # && ENV['TERM_PROGRAM'] == 'iTerm.app'
66
67
  @options[:local_images] = true
@@ -70,51 +71,6 @@ module CLIMarkdown
70
71
  end
71
72
  end
72
73
 
73
- @options[:syntax_higlight] ||= false
74
- opts.on('--syntax', 'Syntax highlight code blocks') do |p|
75
- @options[:syntax_higlight] = p
76
- end
77
-
78
- @options[:update_config] ||= false
79
- opts.on('--update_config', 'Update the configuration file with new keys and current command line options') do
80
- @options[:update_config] = true
81
- end
82
-
83
- @options[:taskpaper] ||= false
84
- opts.on('--taskpaper=OPTION', 'Highlight TaskPaper format (true|false|auto)') do |tp|
85
- @options[:taskpaper] = case tp
86
- when /^[ty1]/
87
- true
88
- when /^a/
89
- :auto
90
- else
91
- false
92
- end
93
- end
94
-
95
- @options[:links] ||= :inline
96
- opts.on('--links=FORMAT',
97
- 'Link style ([inline, reference, paragraph], default inline, "paragraph" will position reference links after each paragraph)') do |fmt|
98
- @options[:links] = case fmt
99
- when /^:?r/i
100
- :reference
101
- when /^:?p/i
102
- :paragraph
103
- else
104
- :inline
105
- end
106
- end
107
-
108
- @options[:lax_spacing] ||= true
109
- opts.on('--[no-]lax-spacing', 'Allow lax spacing') do |opt|
110
- @options[:lax_spacing] = opt
111
- end
112
-
113
- @options[:intra_emphasis] ||= true
114
- opts.on('--[no-]intra-emphasis', 'Parse emphasis inside of words (e.g. Mark_down_)') do |opt|
115
- @options[:intra_emphasis] = opt
116
- end
117
-
118
74
  @options[:list] ||= false
119
75
  opts.on('-l', '--list', 'List headers in document and exit') do
120
76
  @options[:list] = true
@@ -146,11 +102,6 @@ module CLIMarkdown
146
102
  @options[:at_tags] = true
147
103
  end
148
104
 
149
- @options[:wiki_links] ||= false
150
- opts.on('--[no-]wiki-links', 'Highlight [[wiki links]]') do |opt|
151
- @options[:wiki_links] = opt
152
- end
153
-
154
105
  opts.on('-v', '--version', 'Display version number') do
155
106
  puts version
156
107
  exit
@@ -166,6 +117,68 @@ module CLIMarkdown
166
117
  'Display footnotes immediately after the paragraph that references them') do |p|
167
118
  @options[:inline_footnotes] = p
168
119
  end
120
+
121
+ @options[:intra_emphasis] ||= true
122
+ opts.on('--[no-]intra-emphasis', 'Parse emphasis inside of words (e.g. Mark_down_)') do |opt|
123
+ @options[:intra_emphasis] = opt
124
+ end
125
+
126
+ @options[:lax_spacing] ||= true
127
+ opts.on('--[no-]lax-spacing', 'Allow lax spacing') do |opt|
128
+ @options[:lax_spacing] = opt
129
+ end
130
+
131
+ @options[:links] ||= :inline
132
+ opts.on('--links=FORMAT',
133
+ 'Link style ([inline, reference, paragraph], default inline,
134
+ "paragraph" will position reference links after each paragraph)') do |fmt|
135
+ @options[:links] = case fmt
136
+ when /^:?r/i
137
+ :reference
138
+ when /^:?p/i
139
+ :paragraph
140
+ else
141
+ :inline
142
+ end
143
+ end
144
+
145
+ @options[:syntax_higlight] ||= false
146
+ opts.on('--[no-]syntax', 'Syntax highlight code blocks') do |p|
147
+ @options[:syntax_higlight] = p
148
+ end
149
+
150
+ @options[:taskpaper] = if @options[:taskpaper]
151
+ case @options[:taskpaper].to_s
152
+ when /^[ty1]/
153
+ true
154
+ when /^a/
155
+ :auto
156
+ else
157
+ false
158
+ end
159
+ else
160
+ false
161
+ end
162
+ opts.on('--taskpaper=OPTION', 'Highlight TaskPaper format (true|false|auto)') do |tp|
163
+ @options[:taskpaper] = case tp
164
+ when /^[ty1]/
165
+ true
166
+ when /^a/
167
+ :auto
168
+ else
169
+ false
170
+ end
171
+ end
172
+
173
+ @options[:update_config] ||= false
174
+ opts.on('--update_config', 'Update the configuration file with new keys and current command line options') do
175
+ @options[:update_config] = true
176
+ end
177
+
178
+ @options[:wiki_links] ||= false
179
+ opts.on('--[no-]wiki-links', 'Highlight [[wiki links]]') do |opt|
180
+ @options[:wiki_links] = opt
181
+ end
169
182
  end
170
183
 
171
184
  begin
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module CLIMarkdown
4
- VERSION = '2.0.16'
4
+ VERSION = '2.0.17'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mdless
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.16
4
+ version: 2.0.17
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brett Terpstra
@@ -114,7 +114,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
114
114
  - !ruby/object:Gem::Version
115
115
  version: '0'
116
116
  requirements: []
117
- rubygems_version: 3.2.15
117
+ rubygems_version: 3.2.16
118
118
  signing_key:
119
119
  specification_version: 4
120
120
  summary: A pager like less, but for Markdown files