nokogiri 1.11.1 → 1.12.0.rc1
Sign up to get free protection for your applications and to get access to all the features.
Potentially problematic release.
This version of nokogiri might be problematic. Click here for more details.
- checksums.yaml +4 -4
- data/LICENSE-DEPENDENCIES.md +232 -11
- data/LICENSE.md +1 -1
- data/README.md +27 -21
- data/dependencies.yml +12 -12
- data/ext/nokogiri/depend +35 -474
- data/ext/nokogiri/extconf.rb +391 -243
- data/ext/nokogiri/gumbo.c +611 -0
- data/ext/nokogiri/{html_document.c → html4_document.c} +18 -23
- data/ext/nokogiri/html4_element_description.c +294 -0
- data/ext/nokogiri/html4_entity_lookup.c +37 -0
- data/ext/nokogiri/html4_sax_parser_context.c +119 -0
- data/ext/nokogiri/{html_sax_push_parser.c → html4_sax_push_parser.c} +29 -27
- data/ext/nokogiri/libxml2_backwards_compat.c +121 -0
- data/ext/nokogiri/nokogiri.c +206 -66
- data/ext/nokogiri/nokogiri.h +166 -76
- data/ext/nokogiri/test_global_handlers.c +3 -4
- data/ext/nokogiri/xml_attr.c +15 -15
- data/ext/nokogiri/xml_attribute_decl.c +18 -18
- data/ext/nokogiri/xml_cdata.c +13 -18
- data/ext/nokogiri/xml_comment.c +19 -26
- data/ext/nokogiri/xml_document.c +258 -200
- data/ext/nokogiri/xml_document_fragment.c +13 -15
- data/ext/nokogiri/xml_dtd.c +54 -48
- data/ext/nokogiri/xml_element_content.c +31 -26
- data/ext/nokogiri/xml_element_decl.c +22 -22
- data/ext/nokogiri/xml_encoding_handler.c +28 -17
- data/ext/nokogiri/xml_entity_decl.c +32 -30
- data/ext/nokogiri/xml_entity_reference.c +16 -18
- data/ext/nokogiri/xml_namespace.c +58 -49
- data/ext/nokogiri/xml_node.c +473 -414
- data/ext/nokogiri/xml_node_set.c +174 -162
- data/ext/nokogiri/xml_processing_instruction.c +17 -19
- data/ext/nokogiri/xml_reader.c +193 -157
- data/ext/nokogiri/xml_relax_ng.c +29 -23
- data/ext/nokogiri/xml_sax_parser.c +111 -106
- data/ext/nokogiri/xml_sax_parser_context.c +102 -85
- data/ext/nokogiri/xml_sax_push_parser.c +34 -27
- data/ext/nokogiri/xml_schema.c +49 -41
- data/ext/nokogiri/xml_syntax_error.c +21 -23
- data/ext/nokogiri/xml_text.c +13 -17
- data/ext/nokogiri/xml_xpath_context.c +86 -77
- data/ext/nokogiri/xslt_stylesheet.c +157 -156
- data/gumbo-parser/CHANGES.md +63 -0
- data/gumbo-parser/Makefile +101 -0
- data/gumbo-parser/THANKS +27 -0
- data/gumbo-parser/src/Makefile +17 -0
- data/gumbo-parser/src/README.md +41 -0
- data/gumbo-parser/src/ascii.c +75 -0
- data/gumbo-parser/src/ascii.h +115 -0
- data/gumbo-parser/src/attribute.c +42 -0
- data/gumbo-parser/src/attribute.h +17 -0
- data/gumbo-parser/src/char_ref.c +22225 -0
- data/gumbo-parser/src/char_ref.h +29 -0
- data/gumbo-parser/src/char_ref.rl +2154 -0
- data/gumbo-parser/src/error.c +626 -0
- data/gumbo-parser/src/error.h +148 -0
- data/gumbo-parser/src/foreign_attrs.c +104 -0
- data/gumbo-parser/src/foreign_attrs.gperf +27 -0
- data/gumbo-parser/src/gumbo.h +943 -0
- data/gumbo-parser/src/insertion_mode.h +33 -0
- data/gumbo-parser/src/macros.h +91 -0
- data/gumbo-parser/src/parser.c +4886 -0
- data/gumbo-parser/src/parser.h +41 -0
- data/gumbo-parser/src/replacement.h +33 -0
- data/gumbo-parser/src/string_buffer.c +103 -0
- data/gumbo-parser/src/string_buffer.h +68 -0
- data/gumbo-parser/src/string_piece.c +48 -0
- data/gumbo-parser/src/svg_attrs.c +174 -0
- data/gumbo-parser/src/svg_attrs.gperf +77 -0
- data/gumbo-parser/src/svg_tags.c +137 -0
- data/gumbo-parser/src/svg_tags.gperf +55 -0
- data/gumbo-parser/src/tag.c +222 -0
- data/gumbo-parser/src/tag_lookup.c +382 -0
- data/gumbo-parser/src/tag_lookup.gperf +169 -0
- data/gumbo-parser/src/tag_lookup.h +13 -0
- data/gumbo-parser/src/token_buffer.c +79 -0
- data/gumbo-parser/src/token_buffer.h +71 -0
- data/gumbo-parser/src/token_type.h +17 -0
- data/gumbo-parser/src/tokenizer.c +3463 -0
- data/gumbo-parser/src/tokenizer.h +112 -0
- data/gumbo-parser/src/tokenizer_states.h +339 -0
- data/gumbo-parser/src/utf8.c +245 -0
- data/gumbo-parser/src/utf8.h +164 -0
- data/gumbo-parser/src/util.c +68 -0
- data/gumbo-parser/src/util.h +30 -0
- data/gumbo-parser/src/vector.c +111 -0
- data/gumbo-parser/src/vector.h +45 -0
- data/lib/nokogiri.rb +31 -50
- data/lib/nokogiri/css.rb +14 -14
- data/lib/nokogiri/css/parser.rb +2 -2
- data/lib/nokogiri/css/parser.y +1 -1
- data/lib/nokogiri/css/syntax_error.rb +1 -1
- data/lib/nokogiri/extension.rb +26 -0
- data/lib/nokogiri/gumbo.rb +14 -0
- data/lib/nokogiri/html.rb +31 -27
- data/lib/nokogiri/html4.rb +40 -0
- data/lib/nokogiri/{html → html4}/builder.rb +2 -2
- data/lib/nokogiri/{html → html4}/document.rb +4 -4
- data/lib/nokogiri/{html → html4}/document_fragment.rb +17 -17
- data/lib/nokogiri/{html → html4}/element_description.rb +1 -1
- data/lib/nokogiri/{html → html4}/element_description_defaults.rb +1 -1
- data/lib/nokogiri/{html → html4}/entity_lookup.rb +1 -1
- data/lib/nokogiri/{html → html4}/sax/parser.rb +11 -14
- data/lib/nokogiri/html4/sax/parser_context.rb +19 -0
- data/lib/nokogiri/{html → html4}/sax/push_parser.rb +5 -5
- data/lib/nokogiri/html5.rb +473 -0
- data/lib/nokogiri/html5/document.rb +74 -0
- data/lib/nokogiri/html5/document_fragment.rb +80 -0
- data/lib/nokogiri/html5/node.rb +93 -0
- data/lib/nokogiri/version/constant.rb +1 -1
- data/lib/nokogiri/version/info.rb +42 -9
- data/lib/nokogiri/xml.rb +35 -36
- data/lib/nokogiri/xml/document.rb +74 -28
- data/lib/nokogiri/xml/node.rb +45 -47
- data/lib/nokogiri/xml/parse_options.rb +2 -0
- data/lib/nokogiri/xml/pp.rb +2 -2
- data/lib/nokogiri/xml/reader.rb +2 -9
- data/lib/nokogiri/xml/sax.rb +4 -4
- data/lib/nokogiri/xml/sax/document.rb +24 -30
- data/lib/nokogiri/xml/xpath.rb +3 -5
- data/lib/nokogiri/xml/xpath/syntax_error.rb +1 -1
- data/lib/nokogiri/xslt.rb +16 -16
- data/lib/nokogiri/xslt/stylesheet.rb +1 -1
- data/patches/libxml2/{0002-Remove-script-macro-support.patch → 0001-Remove-script-macro-support.patch} +0 -0
- data/patches/libxml2/{0003-Update-entities-to-remove-handling-of-ssi.patch → 0002-Update-entities-to-remove-handling-of-ssi.patch} +0 -0
- data/patches/libxml2/{0004-libxml2.la-is-in-top_builddir.patch → 0003-libxml2.la-is-in-top_builddir.patch} +1 -1
- data/patches/libxml2/{0008-use-glibc-strlen.patch → 0004-use-glibc-strlen.patch} +0 -0
- data/patches/libxml2/{0009-avoid-isnan-isinf.patch → 0005-avoid-isnan-isinf.patch} +4 -4
- data/patches/libxml2/0006-update-automake-files-for-arm64.patch +2511 -0
- data/patches/libxml2/0007-Fix-XPath-recursion-limit.patch +31 -0
- data/patches/libxslt/0001-update-automake-files-for-arm64.patch +2511 -0
- data/patches/libxslt/0002-Fix-xml2-config-check-in-configure-script.patch +19 -0
- data/ports/archives/libxml2-2.9.12.tar.gz +0 -0
- metadata +117 -109
- data/ext/nokogiri/html_document.h +0 -10
- data/ext/nokogiri/html_element_description.c +0 -279
- data/ext/nokogiri/html_element_description.h +0 -10
- data/ext/nokogiri/html_entity_lookup.c +0 -32
- data/ext/nokogiri/html_entity_lookup.h +0 -8
- data/ext/nokogiri/html_sax_parser_context.c +0 -118
- data/ext/nokogiri/html_sax_parser_context.h +0 -11
- data/ext/nokogiri/html_sax_push_parser.h +0 -9
- data/ext/nokogiri/xml_attr.h +0 -9
- data/ext/nokogiri/xml_attribute_decl.h +0 -9
- data/ext/nokogiri/xml_cdata.h +0 -9
- data/ext/nokogiri/xml_comment.h +0 -9
- data/ext/nokogiri/xml_document.h +0 -23
- data/ext/nokogiri/xml_document_fragment.h +0 -10
- data/ext/nokogiri/xml_dtd.h +0 -10
- data/ext/nokogiri/xml_element_content.h +0 -10
- data/ext/nokogiri/xml_element_decl.h +0 -9
- data/ext/nokogiri/xml_encoding_handler.h +0 -8
- data/ext/nokogiri/xml_entity_decl.h +0 -10
- data/ext/nokogiri/xml_entity_reference.h +0 -9
- data/ext/nokogiri/xml_io.c +0 -63
- data/ext/nokogiri/xml_io.h +0 -11
- data/ext/nokogiri/xml_libxml2_hacks.c +0 -112
- data/ext/nokogiri/xml_libxml2_hacks.h +0 -12
- data/ext/nokogiri/xml_namespace.h +0 -14
- data/ext/nokogiri/xml_node.h +0 -13
- data/ext/nokogiri/xml_node_set.h +0 -12
- data/ext/nokogiri/xml_processing_instruction.h +0 -9
- data/ext/nokogiri/xml_reader.h +0 -10
- data/ext/nokogiri/xml_relax_ng.h +0 -9
- data/ext/nokogiri/xml_sax_parser.h +0 -39
- data/ext/nokogiri/xml_sax_parser_context.h +0 -10
- data/ext/nokogiri/xml_sax_push_parser.h +0 -9
- data/ext/nokogiri/xml_schema.h +0 -9
- data/ext/nokogiri/xml_syntax_error.h +0 -25
- data/ext/nokogiri/xml_text.h +0 -9
- data/ext/nokogiri/xml_xpath_context.h +0 -10
- data/ext/nokogiri/xslt_stylesheet.h +0 -14
- data/lib/nokogiri/html/sax/parser_context.rb +0 -17
- data/patches/libxml2/0001-Revert-Do-not-URI-escape-in-server-side-includes.patch +0 -78
- data/patches/libxml2/0005-Fix-infinite-loop-in-xmlStringLenDecodeEntities.patch +0 -32
- data/patches/libxml2/0006-htmlParseComment-treat-as-if-it-closed-the-comment.patch +0 -73
- data/patches/libxml2/0007-use-new-htmlParseLookupCommentEnd-to-find-comment-en.patch +0 -103
- data/ports/archives/libxml2-2.9.10.tar.gz +0 -0
@@ -0,0 +1,19 @@
|
|
1
|
+
From: Nick Wellnhofer <wellnhofer@aevum.de>
|
2
|
+
Date: Fri, 15 Nov 2019 11:53:11 +0100
|
3
|
+
Subject: [PATCH] Fix xml2-config check in configure script
|
4
|
+
|
5
|
+
A 'print' option has never been supported. After a recent change to
|
6
|
+
libxml2, invalid options cause xml2-config to fail.
|
7
|
+
diff --git a/configure b/configure
|
8
|
+
index c63adc5..6061227 100755
|
9
|
+
--- a/configure
|
10
|
+
+++ b/configure
|
11
|
+
@@ -14860,7 +14860,7 @@ PKG_CONFIG=$_save_PKG_CONFIG
|
12
|
+
fi
|
13
|
+
|
14
|
+
|
15
|
+
-if test "x$LIBXML_LIBS" = "x" && ${XML_CONFIG} --libs print > /dev/null 2>&1
|
16
|
+
+if test "x$LIBXML_LIBS" = "x" && ${XML_CONFIG} --libs > /dev/null 2>&1
|
17
|
+
then
|
18
|
+
{ $as_echo "$as_me:${as_lineno-$LINENO}: checking for libxml libraries >= $LIBXML_REQUIRED_VERSION" >&5
|
19
|
+
$as_echo_n "checking for libxml libraries >= $LIBXML_REQUIRED_VERSION... " >&6; }
|
Binary file
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: nokogiri
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.12.0.rc1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Mike Dalessio
|
@@ -10,6 +10,9 @@ authors:
|
|
10
10
|
- Akinori MUSHA
|
11
11
|
- John Shahid
|
12
12
|
- Karol Bucek
|
13
|
+
- Sam Ruby
|
14
|
+
- Craig Barnes
|
15
|
+
- Stephen Checkoway
|
13
16
|
- Lars Kanis
|
14
17
|
- Sergio Arbeo
|
15
18
|
- Timothy Elliott
|
@@ -17,7 +20,7 @@ authors:
|
|
17
20
|
autorequire:
|
18
21
|
bindir: bin
|
19
22
|
cert_chain: []
|
20
|
-
date: 2021-
|
23
|
+
date: 2021-07-09 00:00:00.000000000 Z
|
21
24
|
dependencies:
|
22
25
|
- !ruby/object:Gem::Dependency
|
23
26
|
name: racc
|
@@ -39,14 +42,14 @@ dependencies:
|
|
39
42
|
requirements:
|
40
43
|
- - "~>"
|
41
44
|
- !ruby/object:Gem::Version
|
42
|
-
version: 2.
|
45
|
+
version: 2.6.1
|
43
46
|
type: :runtime
|
44
47
|
prerelease: false
|
45
48
|
version_requirements: !ruby/object:Gem::Requirement
|
46
49
|
requirements:
|
47
50
|
- - "~>"
|
48
51
|
- !ruby/object:Gem::Version
|
49
|
-
version: 2.
|
52
|
+
version: 2.6.1
|
50
53
|
- !ruby/object:Gem::Dependency
|
51
54
|
name: bundler
|
52
55
|
requirement: !ruby/object:Gem::Requirement
|
@@ -61,34 +64,20 @@ dependencies:
|
|
61
64
|
- - "~>"
|
62
65
|
- !ruby/object:Gem::Version
|
63
66
|
version: '2.2'
|
64
|
-
- !ruby/object:Gem::Dependency
|
65
|
-
name: concourse
|
66
|
-
requirement: !ruby/object:Gem::Requirement
|
67
|
-
requirements:
|
68
|
-
- - "~>"
|
69
|
-
- !ruby/object:Gem::Version
|
70
|
-
version: '0.41'
|
71
|
-
type: :development
|
72
|
-
prerelease: false
|
73
|
-
version_requirements: !ruby/object:Gem::Requirement
|
74
|
-
requirements:
|
75
|
-
- - "~>"
|
76
|
-
- !ruby/object:Gem::Version
|
77
|
-
version: '0.41'
|
78
67
|
- !ruby/object:Gem::Dependency
|
79
68
|
name: hoe-markdown
|
80
69
|
requirement: !ruby/object:Gem::Requirement
|
81
70
|
requirements:
|
82
71
|
- - "~>"
|
83
72
|
- !ruby/object:Gem::Version
|
84
|
-
version: '1.
|
73
|
+
version: '1.4'
|
85
74
|
type: :development
|
86
75
|
prerelease: false
|
87
76
|
version_requirements: !ruby/object:Gem::Requirement
|
88
77
|
requirements:
|
89
78
|
- - "~>"
|
90
79
|
- !ruby/object:Gem::Version
|
91
|
-
version: '1.
|
80
|
+
version: '1.4'
|
92
81
|
- !ruby/object:Gem::Dependency
|
93
82
|
name: minitest
|
94
83
|
requirement: !ruby/object:Gem::Requirement
|
@@ -225,41 +214,41 @@ executables:
|
|
225
214
|
extensions:
|
226
215
|
- ext/nokogiri/extconf.rb
|
227
216
|
extra_rdoc_files:
|
228
|
-
- ext/nokogiri/
|
229
|
-
- ext/nokogiri/
|
230
|
-
- ext/nokogiri/
|
231
|
-
- ext/nokogiri/
|
217
|
+
- ext/nokogiri/gumbo.c
|
218
|
+
- ext/nokogiri/html4_document.c
|
219
|
+
- ext/nokogiri/html4_element_description.c
|
220
|
+
- ext/nokogiri/html4_entity_lookup.c
|
221
|
+
- ext/nokogiri/html4_sax_parser_context.c
|
222
|
+
- ext/nokogiri/html4_sax_push_parser.c
|
223
|
+
- ext/nokogiri/libxml2_backwards_compat.c
|
232
224
|
- ext/nokogiri/nokogiri.c
|
233
|
-
- ext/nokogiri/
|
234
|
-
- ext/nokogiri/
|
235
|
-
- ext/nokogiri/
|
236
|
-
- ext/nokogiri/xml_libxml2_hacks.c
|
225
|
+
- ext/nokogiri/test_global_handlers.c
|
226
|
+
- ext/nokogiri/xml_attr.c
|
227
|
+
- ext/nokogiri/xml_attribute_decl.c
|
237
228
|
- ext/nokogiri/xml_cdata.c
|
238
|
-
- ext/nokogiri/
|
239
|
-
- ext/nokogiri/html_entity_lookup.c
|
240
|
-
- ext/nokogiri/xml_namespace.c
|
241
|
-
- ext/nokogiri/xml_io.c
|
229
|
+
- ext/nokogiri/xml_comment.c
|
242
230
|
- ext/nokogiri/xml_document.c
|
243
|
-
- ext/nokogiri/xml_element_decl.c
|
244
|
-
- ext/nokogiri/xml_schema.c
|
245
|
-
- ext/nokogiri/html_document.c
|
246
|
-
- ext/nokogiri/xml_processing_instruction.c
|
247
|
-
- ext/nokogiri/xml_text.c
|
248
|
-
- ext/nokogiri/xml_syntax_error.c
|
249
231
|
- ext/nokogiri/xml_document_fragment.c
|
250
|
-
- ext/nokogiri/
|
232
|
+
- ext/nokogiri/xml_dtd.c
|
233
|
+
- ext/nokogiri/xml_element_content.c
|
234
|
+
- ext/nokogiri/xml_element_decl.c
|
251
235
|
- ext/nokogiri/xml_encoding_handler.c
|
252
|
-
- ext/nokogiri/html_sax_push_parser.c
|
253
|
-
- ext/nokogiri/xml_relax_ng.c
|
254
236
|
- ext/nokogiri/xml_entity_decl.c
|
255
|
-
- ext/nokogiri/test_global_handlers.c
|
256
|
-
- ext/nokogiri/xml_node.c
|
257
237
|
- ext/nokogiri/xml_entity_reference.c
|
258
|
-
- ext/nokogiri/
|
259
|
-
- ext/nokogiri/
|
238
|
+
- ext/nokogiri/xml_namespace.c
|
239
|
+
- ext/nokogiri/xml_node.c
|
240
|
+
- ext/nokogiri/xml_node_set.c
|
241
|
+
- ext/nokogiri/xml_processing_instruction.c
|
242
|
+
- ext/nokogiri/xml_reader.c
|
243
|
+
- ext/nokogiri/xml_relax_ng.c
|
260
244
|
- ext/nokogiri/xml_sax_parser.c
|
261
|
-
- ext/nokogiri/
|
262
|
-
- ext/nokogiri/
|
245
|
+
- ext/nokogiri/xml_sax_parser_context.c
|
246
|
+
- ext/nokogiri/xml_sax_push_parser.c
|
247
|
+
- ext/nokogiri/xml_schema.c
|
248
|
+
- ext/nokogiri/xml_syntax_error.c
|
249
|
+
- ext/nokogiri/xml_text.c
|
250
|
+
- ext/nokogiri/xml_xpath_context.c
|
251
|
+
- ext/nokogiri/xslt_stylesheet.c
|
263
252
|
- README.md
|
264
253
|
files:
|
265
254
|
- Gemfile
|
@@ -270,75 +259,87 @@ files:
|
|
270
259
|
- dependencies.yml
|
271
260
|
- ext/nokogiri/depend
|
272
261
|
- ext/nokogiri/extconf.rb
|
273
|
-
- ext/nokogiri/
|
274
|
-
- ext/nokogiri/
|
275
|
-
- ext/nokogiri/
|
276
|
-
- ext/nokogiri/
|
277
|
-
- ext/nokogiri/
|
278
|
-
- ext/nokogiri/
|
279
|
-
- ext/nokogiri/
|
280
|
-
- ext/nokogiri/html_sax_parser_context.h
|
281
|
-
- ext/nokogiri/html_sax_push_parser.c
|
282
|
-
- ext/nokogiri/html_sax_push_parser.h
|
262
|
+
- ext/nokogiri/gumbo.c
|
263
|
+
- ext/nokogiri/html4_document.c
|
264
|
+
- ext/nokogiri/html4_element_description.c
|
265
|
+
- ext/nokogiri/html4_entity_lookup.c
|
266
|
+
- ext/nokogiri/html4_sax_parser_context.c
|
267
|
+
- ext/nokogiri/html4_sax_push_parser.c
|
268
|
+
- ext/nokogiri/libxml2_backwards_compat.c
|
283
269
|
- ext/nokogiri/nokogiri.c
|
284
270
|
- ext/nokogiri/nokogiri.h
|
285
271
|
- ext/nokogiri/test_global_handlers.c
|
286
272
|
- ext/nokogiri/xml_attr.c
|
287
|
-
- ext/nokogiri/xml_attr.h
|
288
273
|
- ext/nokogiri/xml_attribute_decl.c
|
289
|
-
- ext/nokogiri/xml_attribute_decl.h
|
290
274
|
- ext/nokogiri/xml_cdata.c
|
291
|
-
- ext/nokogiri/xml_cdata.h
|
292
275
|
- ext/nokogiri/xml_comment.c
|
293
|
-
- ext/nokogiri/xml_comment.h
|
294
276
|
- ext/nokogiri/xml_document.c
|
295
|
-
- ext/nokogiri/xml_document.h
|
296
277
|
- ext/nokogiri/xml_document_fragment.c
|
297
|
-
- ext/nokogiri/xml_document_fragment.h
|
298
278
|
- ext/nokogiri/xml_dtd.c
|
299
|
-
- ext/nokogiri/xml_dtd.h
|
300
279
|
- ext/nokogiri/xml_element_content.c
|
301
|
-
- ext/nokogiri/xml_element_content.h
|
302
280
|
- ext/nokogiri/xml_element_decl.c
|
303
|
-
- ext/nokogiri/xml_element_decl.h
|
304
281
|
- ext/nokogiri/xml_encoding_handler.c
|
305
|
-
- ext/nokogiri/xml_encoding_handler.h
|
306
282
|
- ext/nokogiri/xml_entity_decl.c
|
307
|
-
- ext/nokogiri/xml_entity_decl.h
|
308
283
|
- ext/nokogiri/xml_entity_reference.c
|
309
|
-
- ext/nokogiri/xml_entity_reference.h
|
310
|
-
- ext/nokogiri/xml_io.c
|
311
|
-
- ext/nokogiri/xml_io.h
|
312
|
-
- ext/nokogiri/xml_libxml2_hacks.c
|
313
|
-
- ext/nokogiri/xml_libxml2_hacks.h
|
314
284
|
- ext/nokogiri/xml_namespace.c
|
315
|
-
- ext/nokogiri/xml_namespace.h
|
316
285
|
- ext/nokogiri/xml_node.c
|
317
|
-
- ext/nokogiri/xml_node.h
|
318
286
|
- ext/nokogiri/xml_node_set.c
|
319
|
-
- ext/nokogiri/xml_node_set.h
|
320
287
|
- ext/nokogiri/xml_processing_instruction.c
|
321
|
-
- ext/nokogiri/xml_processing_instruction.h
|
322
288
|
- ext/nokogiri/xml_reader.c
|
323
|
-
- ext/nokogiri/xml_reader.h
|
324
289
|
- ext/nokogiri/xml_relax_ng.c
|
325
|
-
- ext/nokogiri/xml_relax_ng.h
|
326
290
|
- ext/nokogiri/xml_sax_parser.c
|
327
|
-
- ext/nokogiri/xml_sax_parser.h
|
328
291
|
- ext/nokogiri/xml_sax_parser_context.c
|
329
|
-
- ext/nokogiri/xml_sax_parser_context.h
|
330
292
|
- ext/nokogiri/xml_sax_push_parser.c
|
331
|
-
- ext/nokogiri/xml_sax_push_parser.h
|
332
293
|
- ext/nokogiri/xml_schema.c
|
333
|
-
- ext/nokogiri/xml_schema.h
|
334
294
|
- ext/nokogiri/xml_syntax_error.c
|
335
|
-
- ext/nokogiri/xml_syntax_error.h
|
336
295
|
- ext/nokogiri/xml_text.c
|
337
|
-
- ext/nokogiri/xml_text.h
|
338
296
|
- ext/nokogiri/xml_xpath_context.c
|
339
|
-
- ext/nokogiri/xml_xpath_context.h
|
340
297
|
- ext/nokogiri/xslt_stylesheet.c
|
341
|
-
-
|
298
|
+
- gumbo-parser/CHANGES.md
|
299
|
+
- gumbo-parser/Makefile
|
300
|
+
- gumbo-parser/THANKS
|
301
|
+
- gumbo-parser/src/Makefile
|
302
|
+
- gumbo-parser/src/README.md
|
303
|
+
- gumbo-parser/src/ascii.c
|
304
|
+
- gumbo-parser/src/ascii.h
|
305
|
+
- gumbo-parser/src/attribute.c
|
306
|
+
- gumbo-parser/src/attribute.h
|
307
|
+
- gumbo-parser/src/char_ref.c
|
308
|
+
- gumbo-parser/src/char_ref.h
|
309
|
+
- gumbo-parser/src/char_ref.rl
|
310
|
+
- gumbo-parser/src/error.c
|
311
|
+
- gumbo-parser/src/error.h
|
312
|
+
- gumbo-parser/src/foreign_attrs.c
|
313
|
+
- gumbo-parser/src/foreign_attrs.gperf
|
314
|
+
- gumbo-parser/src/gumbo.h
|
315
|
+
- gumbo-parser/src/insertion_mode.h
|
316
|
+
- gumbo-parser/src/macros.h
|
317
|
+
- gumbo-parser/src/parser.c
|
318
|
+
- gumbo-parser/src/parser.h
|
319
|
+
- gumbo-parser/src/replacement.h
|
320
|
+
- gumbo-parser/src/string_buffer.c
|
321
|
+
- gumbo-parser/src/string_buffer.h
|
322
|
+
- gumbo-parser/src/string_piece.c
|
323
|
+
- gumbo-parser/src/svg_attrs.c
|
324
|
+
- gumbo-parser/src/svg_attrs.gperf
|
325
|
+
- gumbo-parser/src/svg_tags.c
|
326
|
+
- gumbo-parser/src/svg_tags.gperf
|
327
|
+
- gumbo-parser/src/tag.c
|
328
|
+
- gumbo-parser/src/tag_lookup.c
|
329
|
+
- gumbo-parser/src/tag_lookup.gperf
|
330
|
+
- gumbo-parser/src/tag_lookup.h
|
331
|
+
- gumbo-parser/src/token_buffer.c
|
332
|
+
- gumbo-parser/src/token_buffer.h
|
333
|
+
- gumbo-parser/src/token_type.h
|
334
|
+
- gumbo-parser/src/tokenizer.c
|
335
|
+
- gumbo-parser/src/tokenizer.h
|
336
|
+
- gumbo-parser/src/tokenizer_states.h
|
337
|
+
- gumbo-parser/src/utf8.c
|
338
|
+
- gumbo-parser/src/utf8.h
|
339
|
+
- gumbo-parser/src/util.c
|
340
|
+
- gumbo-parser/src/util.h
|
341
|
+
- gumbo-parser/src/vector.c
|
342
|
+
- gumbo-parser/src/vector.h
|
342
343
|
- lib/nokogiri.rb
|
343
344
|
- lib/nokogiri/css.rb
|
344
345
|
- lib/nokogiri/css/node.rb
|
@@ -350,16 +351,23 @@ files:
|
|
350
351
|
- lib/nokogiri/css/tokenizer.rex
|
351
352
|
- lib/nokogiri/css/xpath_visitor.rb
|
352
353
|
- lib/nokogiri/decorators/slop.rb
|
354
|
+
- lib/nokogiri/extension.rb
|
355
|
+
- lib/nokogiri/gumbo.rb
|
353
356
|
- lib/nokogiri/html.rb
|
354
|
-
- lib/nokogiri/
|
355
|
-
- lib/nokogiri/
|
356
|
-
- lib/nokogiri/
|
357
|
-
- lib/nokogiri/
|
358
|
-
- lib/nokogiri/
|
359
|
-
- lib/nokogiri/
|
360
|
-
- lib/nokogiri/
|
361
|
-
- lib/nokogiri/
|
362
|
-
- lib/nokogiri/
|
357
|
+
- lib/nokogiri/html4.rb
|
358
|
+
- lib/nokogiri/html4/builder.rb
|
359
|
+
- lib/nokogiri/html4/document.rb
|
360
|
+
- lib/nokogiri/html4/document_fragment.rb
|
361
|
+
- lib/nokogiri/html4/element_description.rb
|
362
|
+
- lib/nokogiri/html4/element_description_defaults.rb
|
363
|
+
- lib/nokogiri/html4/entity_lookup.rb
|
364
|
+
- lib/nokogiri/html4/sax/parser.rb
|
365
|
+
- lib/nokogiri/html4/sax/parser_context.rb
|
366
|
+
- lib/nokogiri/html4/sax/push_parser.rb
|
367
|
+
- lib/nokogiri/html5.rb
|
368
|
+
- lib/nokogiri/html5/document.rb
|
369
|
+
- lib/nokogiri/html5/document_fragment.rb
|
370
|
+
- lib/nokogiri/html5/node.rb
|
363
371
|
- lib/nokogiri/jruby/dependencies.rb
|
364
372
|
- lib/nokogiri/syntax_error.rb
|
365
373
|
- lib/nokogiri/version.rb
|
@@ -405,16 +413,16 @@ files:
|
|
405
413
|
- lib/nokogiri/xslt.rb
|
406
414
|
- lib/nokogiri/xslt/stylesheet.rb
|
407
415
|
- lib/xsd/xmlparser/nokogiri.rb
|
408
|
-
- patches/libxml2/0001-
|
409
|
-
- patches/libxml2/0002-
|
410
|
-
- patches/libxml2/0003-
|
411
|
-
- patches/libxml2/0004-
|
412
|
-
- patches/libxml2/0005-
|
413
|
-
- patches/libxml2/0006-
|
414
|
-
- patches/libxml2/0007-
|
415
|
-
- patches/
|
416
|
-
- patches/
|
417
|
-
- ports/archives/libxml2-2.9.
|
416
|
+
- patches/libxml2/0001-Remove-script-macro-support.patch
|
417
|
+
- patches/libxml2/0002-Update-entities-to-remove-handling-of-ssi.patch
|
418
|
+
- patches/libxml2/0003-libxml2.la-is-in-top_builddir.patch
|
419
|
+
- patches/libxml2/0004-use-glibc-strlen.patch
|
420
|
+
- patches/libxml2/0005-avoid-isnan-isinf.patch
|
421
|
+
- patches/libxml2/0006-update-automake-files-for-arm64.patch
|
422
|
+
- patches/libxml2/0007-Fix-XPath-recursion-limit.patch
|
423
|
+
- patches/libxslt/0001-update-automake-files-for-arm64.patch
|
424
|
+
- patches/libxslt/0002-Fix-xml2-config-check-in-configure-script.patch
|
425
|
+
- ports/archives/libxml2-2.9.12.tar.gz
|
418
426
|
- ports/archives/libxslt-1.1.34.tar.gz
|
419
427
|
homepage: https://nokogiri.org
|
420
428
|
licenses:
|
@@ -438,11 +446,11 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
438
446
|
version: 2.5.0
|
439
447
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
440
448
|
requirements:
|
441
|
-
- - "
|
449
|
+
- - ">"
|
442
450
|
- !ruby/object:Gem::Version
|
443
|
-
version:
|
451
|
+
version: 1.3.1
|
444
452
|
requirements: []
|
445
|
-
rubygems_version: 3.
|
453
|
+
rubygems_version: 3.2.15
|
446
454
|
signing_key:
|
447
455
|
specification_version: 4
|
448
456
|
summary: Nokogiri (鋸) makes it easy and painless to work with XML and HTML from Ruby.
|
@@ -1,279 +0,0 @@
|
|
1
|
-
#include <html_element_description.h>
|
2
|
-
|
3
|
-
/*
|
4
|
-
* call-seq:
|
5
|
-
* required_attributes
|
6
|
-
*
|
7
|
-
* A list of required attributes for this element
|
8
|
-
*/
|
9
|
-
static VALUE required_attributes(VALUE self)
|
10
|
-
{
|
11
|
-
const htmlElemDesc * description;
|
12
|
-
VALUE list;
|
13
|
-
int i;
|
14
|
-
|
15
|
-
Data_Get_Struct(self, htmlElemDesc, description);
|
16
|
-
|
17
|
-
list = rb_ary_new();
|
18
|
-
|
19
|
-
if(NULL == description->attrs_req) return list;
|
20
|
-
|
21
|
-
for(i = 0; description->attrs_depr[i]; i++) {
|
22
|
-
rb_ary_push(list, NOKOGIRI_STR_NEW2(description->attrs_req[i]));
|
23
|
-
}
|
24
|
-
|
25
|
-
return list;
|
26
|
-
}
|
27
|
-
|
28
|
-
/*
|
29
|
-
* call-seq:
|
30
|
-
* deprecated_attributes
|
31
|
-
*
|
32
|
-
* A list of deprecated attributes for this element
|
33
|
-
*/
|
34
|
-
static VALUE deprecated_attributes(VALUE self)
|
35
|
-
{
|
36
|
-
const htmlElemDesc * description;
|
37
|
-
VALUE list;
|
38
|
-
int i;
|
39
|
-
|
40
|
-
Data_Get_Struct(self, htmlElemDesc, description);
|
41
|
-
|
42
|
-
list = rb_ary_new();
|
43
|
-
|
44
|
-
if(NULL == description->attrs_depr) return list;
|
45
|
-
|
46
|
-
for(i = 0; description->attrs_depr[i]; i++) {
|
47
|
-
rb_ary_push(list, NOKOGIRI_STR_NEW2(description->attrs_depr[i]));
|
48
|
-
}
|
49
|
-
|
50
|
-
return list;
|
51
|
-
}
|
52
|
-
|
53
|
-
/*
|
54
|
-
* call-seq:
|
55
|
-
* optional_attributes
|
56
|
-
*
|
57
|
-
* A list of optional attributes for this element
|
58
|
-
*/
|
59
|
-
static VALUE optional_attributes(VALUE self)
|
60
|
-
{
|
61
|
-
const htmlElemDesc * description;
|
62
|
-
VALUE list;
|
63
|
-
int i;
|
64
|
-
|
65
|
-
Data_Get_Struct(self, htmlElemDesc, description);
|
66
|
-
|
67
|
-
list = rb_ary_new();
|
68
|
-
|
69
|
-
if(NULL == description->attrs_opt) return list;
|
70
|
-
|
71
|
-
for(i = 0; description->attrs_opt[i]; i++) {
|
72
|
-
rb_ary_push(list, NOKOGIRI_STR_NEW2(description->attrs_opt[i]));
|
73
|
-
}
|
74
|
-
|
75
|
-
return list;
|
76
|
-
}
|
77
|
-
|
78
|
-
/*
|
79
|
-
* call-seq:
|
80
|
-
* default_sub_element
|
81
|
-
*
|
82
|
-
* The default sub element for this element
|
83
|
-
*/
|
84
|
-
static VALUE default_sub_element(VALUE self)
|
85
|
-
{
|
86
|
-
const htmlElemDesc * description;
|
87
|
-
Data_Get_Struct(self, htmlElemDesc, description);
|
88
|
-
|
89
|
-
if (description->defaultsubelt)
|
90
|
-
return NOKOGIRI_STR_NEW2(description->defaultsubelt);
|
91
|
-
|
92
|
-
return Qnil;
|
93
|
-
}
|
94
|
-
|
95
|
-
/*
|
96
|
-
* call-seq:
|
97
|
-
* sub_elements
|
98
|
-
*
|
99
|
-
* A list of allowed sub elements for this element.
|
100
|
-
*/
|
101
|
-
static VALUE sub_elements(VALUE self)
|
102
|
-
{
|
103
|
-
const htmlElemDesc * description;
|
104
|
-
VALUE list;
|
105
|
-
int i;
|
106
|
-
|
107
|
-
Data_Get_Struct(self, htmlElemDesc, description);
|
108
|
-
|
109
|
-
list = rb_ary_new();
|
110
|
-
|
111
|
-
if(NULL == description->subelts) return list;
|
112
|
-
|
113
|
-
for(i = 0; description->subelts[i]; i++) {
|
114
|
-
rb_ary_push(list, NOKOGIRI_STR_NEW2(description->subelts[i]));
|
115
|
-
}
|
116
|
-
|
117
|
-
return list;
|
118
|
-
}
|
119
|
-
|
120
|
-
/*
|
121
|
-
* call-seq:
|
122
|
-
* description
|
123
|
-
*
|
124
|
-
* The description for this element
|
125
|
-
*/
|
126
|
-
static VALUE description(VALUE self)
|
127
|
-
{
|
128
|
-
const htmlElemDesc * description;
|
129
|
-
Data_Get_Struct(self, htmlElemDesc, description);
|
130
|
-
|
131
|
-
return NOKOGIRI_STR_NEW2(description->desc);
|
132
|
-
}
|
133
|
-
|
134
|
-
/*
|
135
|
-
* call-seq:
|
136
|
-
* inline?
|
137
|
-
*
|
138
|
-
* Is this element an inline element?
|
139
|
-
*/
|
140
|
-
static VALUE inline_eh(VALUE self)
|
141
|
-
{
|
142
|
-
const htmlElemDesc * description;
|
143
|
-
Data_Get_Struct(self, htmlElemDesc, description);
|
144
|
-
|
145
|
-
if(description->isinline) return Qtrue;
|
146
|
-
return Qfalse;
|
147
|
-
}
|
148
|
-
|
149
|
-
/*
|
150
|
-
* call-seq:
|
151
|
-
* deprecated?
|
152
|
-
*
|
153
|
-
* Is this element deprecated?
|
154
|
-
*/
|
155
|
-
static VALUE deprecated_eh(VALUE self)
|
156
|
-
{
|
157
|
-
const htmlElemDesc * description;
|
158
|
-
Data_Get_Struct(self, htmlElemDesc, description);
|
159
|
-
|
160
|
-
if(description->depr) return Qtrue;
|
161
|
-
return Qfalse;
|
162
|
-
}
|
163
|
-
|
164
|
-
/*
|
165
|
-
* call-seq:
|
166
|
-
* empty?
|
167
|
-
*
|
168
|
-
* Is this an empty element?
|
169
|
-
*/
|
170
|
-
static VALUE empty_eh(VALUE self)
|
171
|
-
{
|
172
|
-
const htmlElemDesc * description;
|
173
|
-
Data_Get_Struct(self, htmlElemDesc, description);
|
174
|
-
|
175
|
-
if(description->empty) return Qtrue;
|
176
|
-
return Qfalse;
|
177
|
-
}
|
178
|
-
|
179
|
-
/*
|
180
|
-
* call-seq:
|
181
|
-
* save_end_tag?
|
182
|
-
*
|
183
|
-
* Should the end tag be saved?
|
184
|
-
*/
|
185
|
-
static VALUE save_end_tag_eh(VALUE self)
|
186
|
-
{
|
187
|
-
const htmlElemDesc * description;
|
188
|
-
Data_Get_Struct(self, htmlElemDesc, description);
|
189
|
-
|
190
|
-
if(description->saveEndTag) return Qtrue;
|
191
|
-
return Qfalse;
|
192
|
-
}
|
193
|
-
|
194
|
-
/*
|
195
|
-
* call-seq:
|
196
|
-
* implied_end_tag?
|
197
|
-
*
|
198
|
-
* Can the end tag be implied for this tag?
|
199
|
-
*/
|
200
|
-
static VALUE implied_end_tag_eh(VALUE self)
|
201
|
-
{
|
202
|
-
const htmlElemDesc * description;
|
203
|
-
Data_Get_Struct(self, htmlElemDesc, description);
|
204
|
-
|
205
|
-
if(description->endTag) return Qtrue;
|
206
|
-
return Qfalse;
|
207
|
-
}
|
208
|
-
|
209
|
-
/*
|
210
|
-
* call-seq:
|
211
|
-
* implied_start_tag?
|
212
|
-
*
|
213
|
-
* Can the start tag be implied for this tag?
|
214
|
-
*/
|
215
|
-
static VALUE implied_start_tag_eh(VALUE self)
|
216
|
-
{
|
217
|
-
const htmlElemDesc * description;
|
218
|
-
Data_Get_Struct(self, htmlElemDesc, description);
|
219
|
-
|
220
|
-
if(description->startTag) return Qtrue;
|
221
|
-
return Qfalse;
|
222
|
-
}
|
223
|
-
|
224
|
-
/*
|
225
|
-
* call-seq:
|
226
|
-
* name
|
227
|
-
*
|
228
|
-
* Get the tag name for this ElemementDescription
|
229
|
-
*/
|
230
|
-
static VALUE name(VALUE self)
|
231
|
-
{
|
232
|
-
const htmlElemDesc * description;
|
233
|
-
Data_Get_Struct(self, htmlElemDesc, description);
|
234
|
-
|
235
|
-
if(NULL == description->name) return Qnil;
|
236
|
-
return NOKOGIRI_STR_NEW2(description->name);
|
237
|
-
}
|
238
|
-
|
239
|
-
/*
|
240
|
-
* call-seq:
|
241
|
-
* [](tag_name)
|
242
|
-
*
|
243
|
-
* Get ElemementDescription for +tag_name+
|
244
|
-
*/
|
245
|
-
static VALUE get_description(VALUE klass, VALUE tag_name)
|
246
|
-
{
|
247
|
-
const htmlElemDesc * description = htmlTagLookup(
|
248
|
-
(const xmlChar *)StringValueCStr(tag_name)
|
249
|
-
);
|
250
|
-
|
251
|
-
if(NULL == description) return Qnil;
|
252
|
-
return Data_Wrap_Struct(klass, 0, 0, (void *)(uintptr_t)description);
|
253
|
-
}
|
254
|
-
|
255
|
-
VALUE cNokogiriHtmlElementDescription ;
|
256
|
-
void init_html_element_description()
|
257
|
-
{
|
258
|
-
VALUE nokogiri = rb_define_module("Nokogiri");
|
259
|
-
VALUE html = rb_define_module_under(nokogiri, "HTML");
|
260
|
-
VALUE klass = rb_define_class_under(html, "ElementDescription",rb_cObject);
|
261
|
-
|
262
|
-
cNokogiriHtmlElementDescription = klass;
|
263
|
-
|
264
|
-
rb_define_singleton_method(klass, "[]", get_description, 1);
|
265
|
-
|
266
|
-
rb_define_method(klass, "name", name, 0);
|
267
|
-
rb_define_method(klass, "implied_start_tag?", implied_start_tag_eh, 0);
|
268
|
-
rb_define_method(klass, "implied_end_tag?", implied_end_tag_eh, 0);
|
269
|
-
rb_define_method(klass, "save_end_tag?", save_end_tag_eh, 0);
|
270
|
-
rb_define_method(klass, "empty?", empty_eh, 0);
|
271
|
-
rb_define_method(klass, "deprecated?", deprecated_eh, 0);
|
272
|
-
rb_define_method(klass, "inline?", inline_eh, 0);
|
273
|
-
rb_define_method(klass, "description", description, 0);
|
274
|
-
rb_define_method(klass, "sub_elements", sub_elements, 0);
|
275
|
-
rb_define_method(klass, "default_sub_element", default_sub_element, 0);
|
276
|
-
rb_define_method(klass, "optional_attributes", optional_attributes, 0);
|
277
|
-
rb_define_method(klass, "deprecated_attributes", deprecated_attributes, 0);
|
278
|
-
rb_define_method(klass, "required_attributes", required_attributes, 0);
|
279
|
-
}
|