1
0
Fork 0
mirror of https://github.com/tldr-pages/tldr.git synced 2025-07-09 17:45:23 +02:00
tldr/pages/common/nokogiri.md
2025-05-04 20:03:26 +03:00

569 B

nokogiri

An HTML, XML, SAX and Reader parser. More information: https://manned.org/nokogiri.

  • Parse the contents of a URL or file:

nokogiri {{url|path/to/file}}

  • Parse as a specific type:

nokogiri {{url|path/to/file}} --type {{xml|html}}

  • Load a specific initialization file before parsing:

nokogiri {{url|path/to/file}} -C {{path/to/config_file}}

  • Parse using a specific encoding:

nokogiri {{url|path/to/file}} {{[-E|--encoding]}} {{encoding}}

  • Validate using a RELAX NG file:

nokogiri {{url|path/to/file}} --rng {{url|path/to/file}}