author | Oleksandr Gavenko <gavenkoa@gmail.com> |
Mon, 23 Apr 2012 21:29:37 +0300 | |
changeset 1250 | 8a507683fbc6 |
parent 796 | 7c884c0647b7 |
permissions | -rw-r--r-- |
392 | 1 |
-*- mode: outline; coding: utf-8 -*- |
2 |
||
717 | 3 |
* About. |
4 |
||
5 |
http://xmlhack.ru |
|
796 | 6 |
http://microformats.org/wiki/namespaces-considered-harmful |
717 | 7 |
|
392 | 8 |
* relaxng. |
9 |
||
10 |
** relaxng-mode. |
|
11 |
||
12 |
http://www.pantor.com/download.html |
|
13 |
RNC Emacs Mode (home page) |
|
14 |
http://www.emacswiki.org/emacs/RELAX_NG |
|
15 |
http://www.relaxng.org/compact-tutorial-20030326.html |
|
16 |
relaxng compact syntax tutorial |
|
621
ddca4ce1832f
CLI utilities for processing xml.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
392
diff
changeset
|
17 |
|
ddca4ce1832f
CLI utilities for processing xml.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
392
diff
changeset
|
18 |
* CLI utilities for processing xml. |
ddca4ce1832f
CLI utilities for processing xml.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
392
diff
changeset
|
19 |
|
636 | 20 |
** xmlstar. |
21 |
||
22 |
XMLStarlet is a set of command line utilities (tools) which can be used to transform, |
|
23 |
query, validate, and edit XML documents and files using simple set of shell commands in |
|
24 |
similar way it is done for plain text files using UNIX grep, sed, awk, diff, patch, join, |
|
25 |
etc. |
|
26 |
||
27 |
http://xmlstar.sourceforge.net/overview.php |
|
28 |
home page |
|
29 |
||
621
ddca4ce1832f
CLI utilities for processing xml.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
392
diff
changeset
|
30 |
** Cygwin. |
ddca4ce1832f
CLI utilities for processing xml.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
392
diff
changeset
|
31 |
|
ddca4ce1832f
CLI utilities for processing xml.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
392
diff
changeset
|
32 |
cmd# setup.exe -p libxml2,libxslt |
ddca4ce1832f
CLI utilities for processing xml.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
392
diff
changeset
|
33 |
|
ddca4ce1832f
CLI utilities for processing xml.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
392
diff
changeset
|
34 |
'libxslt' provide 'xsltproc, 'libxml2' provide 'xmlcatalog' and 'xmllint' |
635
59382d9f4331
XPath query from CLI.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
621
diff
changeset
|
35 |
|
59382d9f4331
XPath query from CLI.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
621
diff
changeset
|
36 |
** XPath query from CLI. |
59382d9f4331
XPath query from CLI.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
621
diff
changeset
|
37 |
|
59382d9f4331
XPath query from CLI.
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
621
diff
changeset
|
38 |
$ xmllint --xpath $XPATH file.xml |
718 | 39 |
|
40 |
* Microformats. |
|
41 |
||
42 |
http://microformats.org/about |
|
750 | 43 |
|
44 |
* XML encoding. |
|
45 |
||
46 |
http://www.ietf.org/rfc/rfc3023.txt |
|
47 |
XML Media Types |
|
48 |
http://www.xml.com/pub/a/2004/07/21/dive.html |
|
49 |
XML on the Web Has Failed |
|
795
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
50 |
|
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
51 |
* Validation of xml files. |
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
52 |
|
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
53 |
http://infohost.nmt.edu/tcc/help/xml/lint.html |
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
54 |
xmllint: A validator for XML files |
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
55 |
|
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
56 |
** Validating using the DOCTYPE. |
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
57 |
|
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
58 |
$ xmllint --valid --noout file.xml |
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
59 |
|
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
60 |
** Validating against a specific DTD. |
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
61 |
|
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
62 |
$ xmllint --noout --dtdvalid URL file.xml |
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
63 |
|
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
64 |
** Validating against a Relax NG schema. |
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
65 |
|
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
66 |
$ xmllint --noout --relaxng schema.rng file.xml |
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
67 |
|
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
68 |
If your schema is in Compact Format, you can use the trang program to convert |
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
69 |
it to RNG format: |
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
70 |
|
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
71 |
$ trang file.rnc file.rng |
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
72 |
|
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
73 |
** Validating against XSchema. |
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
74 |
|
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
75 |
$ xmllint --noout --schema schema.xsd file.xml |
31505dc75ede
Validation of xml files
Oleksandr Gavenko <gavenkoa@gmail.com>
parents:
750
diff
changeset
|
76 |