gitlab-markup 1.6.3 → 1.6.4
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 +5 -5
- data/CONTRIBUTING.md +10 -5
- data/HISTORY.md +4 -0
- data/gitlab-markup.gemspec +16 -11
- data/lib/github-markup.rb +1 -1
- data/lib/github/commands/rest2html +2 -2
- data/test/markup_test.rb +3 -2
- data/test/markups/README.rst.html +5 -10
- metadata +24 -22
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
2
|
+
SHA256:
|
3
|
+
metadata.gz: '088585ef527b31da2dd72c9a6efe953a04276e6ca5a0cf411b0b8c32547b27ff'
|
4
|
+
data.tar.gz: ad0c68e99b095ef0f5f94e5d2343003b555f3ad220ae309db55c0627c8419f42
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 7e9841bddbba24c743d6da4fc6cba9bc3bf04019cc3b16a79d51b15638d778bfab192f3ecf17b64ea7c18470ec701c266ae630c22dc3936d0eed11530d956142
|
7
|
+
data.tar.gz: ffc895e79b9f1bc84e0214a1e9e7fcebcac0d0d8ab8ee33a7359cbe19ef3debffd0497500fa537ad024ec9297f5134c5e6aefb3d5069e886c304f613eb50d286
|
data/CONTRIBUTING.md
CHANGED
@@ -6,13 +6,18 @@ all contributions. By participating in this project, you agree to abide by the
|
|
6
6
|
|
7
7
|
This library's only job is to decide which markup format to use and call out to an external library to convert the markup to HTML (see the [README](README.md) for more information on how markup is rendered)
|
8
8
|
|
9
|
-
##
|
9
|
+
## Developer Certificate of Origin + License
|
10
10
|
|
11
|
-
By
|
12
|
-
|
11
|
+
By contributing to GitLab B.V., You accept and agree to the following terms and
|
12
|
+
conditions for Your present and future Contributions submitted to GitLab B.V.
|
13
|
+
Except for the license granted herein to GitLab B.V. and recipients of software
|
14
|
+
distributed by GitLab B.V., You reserve all right, title, and interest in and to
|
15
|
+
Your Contributions. All Contributions are subject to the following DCO + License
|
16
|
+
terms.
|
13
17
|
|
14
|
-
|
15
|
-
|
18
|
+
[DCO + License](https://gitlab.com/gitlab-org/dco/blob/master/README.md)
|
19
|
+
|
20
|
+
_This notice should stay as the first item in the CONTRIBUTING.md file._
|
16
21
|
|
17
22
|
## Code of conduct
|
18
23
|
|
data/HISTORY.md
CHANGED
data/gitlab-markup.gemspec
CHANGED
@@ -1,25 +1,30 @@
|
|
1
|
-
require File.expand_path(
|
1
|
+
require File.expand_path('../lib/github-markup', __FILE__)
|
2
2
|
|
3
3
|
Gem::Specification.new do |s|
|
4
|
-
s.name =
|
4
|
+
s.name = 'gitlab-markup'
|
5
5
|
s.version = GitHub::Markup::VERSION
|
6
|
-
s.summary =
|
7
|
-
s.description =
|
8
|
-
|
9
|
-
s.
|
10
|
-
s.
|
11
|
-
s.
|
12
|
-
s.license = "MIT"
|
6
|
+
s.summary = 'Fork from github-markup GitLab uses to render non markdown content'
|
7
|
+
s.description = 'This gem is used by GitLab to render any non Markdown markup'
|
8
|
+
s.authors = ['Chris Wanstrath']
|
9
|
+
s.email = 'chris@ozmm.org'
|
10
|
+
s.homepage = 'https://gitlab.com/gitlab-org/gitlab-markup'
|
11
|
+
s.license = 'MIT'
|
13
12
|
|
14
13
|
s.files = `git ls-files`.split($\)
|
15
14
|
s.executables = s.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
|
16
15
|
s.test_files = s.files.grep(%r{^(test|spec|features)/})
|
17
16
|
s.require_paths = %w[lib]
|
18
17
|
|
18
|
+
s.metadata = {
|
19
|
+
'bug_tracker_uri' => 'https://gitlab.com/gitlab-org/gitlab-markup/issues',
|
20
|
+
'changelog_uri' => 'https://gitlab.com/gitlab-org/gitlab-markup/blob/master/HISTORY.md',
|
21
|
+
'source_code_uri' => 'https://gitlab.com/gitlab-org/gitlab-markup'
|
22
|
+
}
|
23
|
+
|
19
24
|
s.add_development_dependency 'activesupport', '~> 4.0'
|
20
|
-
s.add_development_dependency 'minitest', '~> 5.4.3'
|
21
25
|
s.add_development_dependency 'html-pipeline', '~> 1.0'
|
22
|
-
s.add_development_dependency '
|
26
|
+
s.add_development_dependency 'minitest', '~> 5.4.3'
|
23
27
|
s.add_development_dependency 'nokogiri', '~> 1.6.1'
|
24
28
|
s.add_development_dependency 'nokogiri-diff', '~> 0.2.0'
|
29
|
+
s.add_development_dependency 'sanitize', '~> 2.1.0'
|
25
30
|
end
|
data/lib/github-markup.rb
CHANGED
@@ -133,10 +133,10 @@ class GitHubHTMLTranslator(HTMLTranslator, object):
|
|
133
133
|
language = classes[1]
|
134
134
|
del classes[:]
|
135
135
|
self.body.append(self.starttag(node, 'pre'))
|
136
|
-
self.body.append(self.starttag(node, 'code', lang=language))
|
136
|
+
self.body.append(self.starttag(node, 'code', suffix='', lang=language))
|
137
137
|
else:
|
138
138
|
self.body.append(self.starttag(node, 'pre'))
|
139
|
-
self.body.append(self.starttag(node, 'code'))
|
139
|
+
self.body.append(self.starttag(node, 'code', suffix=''))
|
140
140
|
|
141
141
|
def depart_literal_block(self, node):
|
142
142
|
self.body.append('</code>')
|
data/test/markup_test.rb
CHANGED
@@ -21,8 +21,9 @@ def assert_html_equal(expected, actual, msg = nil)
|
|
21
21
|
expected_doc = Nokogiri::HTML(expected) {|config| config.noblanks}
|
22
22
|
actual_doc = Nokogiri::HTML(actual) {|config| config.noblanks}
|
23
23
|
|
24
|
-
|
25
|
-
|
24
|
+
# Normalize content of text nodes, excluding preformatted nodes
|
25
|
+
expected_doc.search('//text()[not(ancestor::pre)]').each {|node| node.content = normalize_html node.content}
|
26
|
+
actual_doc.search('//text()[not(ancestor::pre)]').each {|node| node.content = normalize_html node.content}
|
26
27
|
|
27
28
|
ignore_changes = {"+" => Regexp.union(/^\s*id=".*"\s*$/), "-" => nil}
|
28
29
|
expected_doc.diff(actual_doc) do |change, node|
|
@@ -17,16 +17,13 @@
|
|
17
17
|
</ol>
|
18
18
|
<p>The UTF-8 quote character in this table used to cause python to go boom. Now docutils just silently ignores it.</p>
|
19
19
|
<pre>
|
20
|
-
<code>
|
21
|
-
A block of code</code>
|
20
|
+
<code>A block of code</code>
|
22
21
|
</pre>
|
23
22
|
<pre>
|
24
|
-
<code lang="python">
|
25
|
-
python.code('hooray')</code>
|
23
|
+
<code lang="python">python.code('hooray')</code>
|
26
24
|
</pre>
|
27
25
|
<pre>
|
28
|
-
<code lang="python"
|
29
|
-
>>> some_function()
|
26
|
+
<code lang="python">>>> some_function()
|
30
27
|
'result'</code>
|
31
28
|
</pre>
|
32
29
|
<table>
|
@@ -91,13 +88,11 @@ but no problem!</td>
|
|
91
88
|
|
92
89
|
<p>Press <kbd>Ctrl+C</kbd> to quit</p>
|
93
90
|
<pre>
|
94
|
-
<code lang="plantuml">
|
95
|
-
Bob -> Alice: hello
|
91
|
+
<code lang="plantuml">Bob -> Alice: hello
|
96
92
|
Alice -> Bob: Go Away</code>
|
97
93
|
</pre>
|
98
94
|
<p>Caption with <strong>bold</strong> and <em>italic</em></p>
|
99
95
|
<pre>
|
100
|
-
<code lang="plantuml">
|
101
|
-
Bob -> Alice: hello
|
96
|
+
<code lang="plantuml">Bob -> Alice: hello
|
102
97
|
Alice -> Bob: Go Away</code>
|
103
98
|
</pre>
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gitlab-markup
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.6.
|
4
|
+
version: 1.6.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Chris Wanstrath
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2018-06-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activesupport
|
@@ -25,77 +25,76 @@ dependencies:
|
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '4.0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
|
-
name:
|
28
|
+
name: html-pipeline
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
31
|
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version:
|
33
|
+
version: '1.0'
|
34
34
|
type: :development
|
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:
|
40
|
+
version: '1.0'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
|
-
name:
|
42
|
+
name: minitest
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
45
|
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version:
|
47
|
+
version: 5.4.3
|
48
48
|
type: :development
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
52
|
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version:
|
54
|
+
version: 5.4.3
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
|
-
name:
|
56
|
+
name: nokogiri
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
59
|
- - "~>"
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version:
|
61
|
+
version: 1.6.1
|
62
62
|
type: :development
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
66
|
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version:
|
68
|
+
version: 1.6.1
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
|
-
name: nokogiri
|
70
|
+
name: nokogiri-diff
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
72
72
|
requirements:
|
73
73
|
- - "~>"
|
74
74
|
- !ruby/object:Gem::Version
|
75
|
-
version:
|
75
|
+
version: 0.2.0
|
76
76
|
type: :development
|
77
77
|
prerelease: false
|
78
78
|
version_requirements: !ruby/object:Gem::Requirement
|
79
79
|
requirements:
|
80
80
|
- - "~>"
|
81
81
|
- !ruby/object:Gem::Version
|
82
|
-
version:
|
82
|
+
version: 0.2.0
|
83
83
|
- !ruby/object:Gem::Dependency
|
84
|
-
name:
|
84
|
+
name: sanitize
|
85
85
|
requirement: !ruby/object:Gem::Requirement
|
86
86
|
requirements:
|
87
87
|
- - "~>"
|
88
88
|
- !ruby/object:Gem::Version
|
89
|
-
version:
|
89
|
+
version: 2.1.0
|
90
90
|
type: :development
|
91
91
|
prerelease: false
|
92
92
|
version_requirements: !ruby/object:Gem::Requirement
|
93
93
|
requirements:
|
94
94
|
- - "~>"
|
95
95
|
- !ruby/object:Gem::Version
|
96
|
-
version:
|
97
|
-
description: This gem is used by
|
98
|
-
Textile, Org-Mode, etc. Fork it and add your own!
|
96
|
+
version: 2.1.0
|
97
|
+
description: This gem is used by GitLab to render any non Markdown markup
|
99
98
|
email: chris@ozmm.org
|
100
99
|
executables:
|
101
100
|
- github-markup
|
@@ -160,7 +159,10 @@ files:
|
|
160
159
|
homepage: https://gitlab.com/gitlab-org/gitlab-markup
|
161
160
|
licenses:
|
162
161
|
- MIT
|
163
|
-
metadata:
|
162
|
+
metadata:
|
163
|
+
bug_tracker_uri: https://gitlab.com/gitlab-org/gitlab-markup/issues
|
164
|
+
changelog_uri: https://gitlab.com/gitlab-org/gitlab-markup/blob/master/HISTORY.md
|
165
|
+
source_code_uri: https://gitlab.com/gitlab-org/gitlab-markup
|
164
166
|
post_install_message:
|
165
167
|
rdoc_options: []
|
166
168
|
require_paths:
|
@@ -177,10 +179,10 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
177
179
|
version: '0'
|
178
180
|
requirements: []
|
179
181
|
rubyforge_project:
|
180
|
-
rubygems_version: 2.
|
182
|
+
rubygems_version: 2.7.7
|
181
183
|
signing_key:
|
182
184
|
specification_version: 4
|
183
|
-
summary:
|
185
|
+
summary: Fork from github-markup GitLab uses to render non markdown content
|
184
186
|
test_files:
|
185
187
|
- test/fixtures/fail.sh
|
186
188
|
- test/markup_test.rb
|