Skip to main content

Apply XPath expressions to XML, like jq does for JSONPath and JSON.

Installation

Install with pip:

pip install xq

Or download the repo and install via setuptools:

python setup.py install

Usage

Extract download URLs from an RSS feed:

http get 'http://br-rss.jeffbr13.net/rss/channels/1/' | xq '//item/enclosure/@url'

Extract all links from an HTML page footer:

http get 'http://br-rss.jeffbr13.net/ | xq '//footer//a/@href'

Test

Run unittest in the root directory to autodetect and run tests:

python -m unittest

Build

Increment xq.VERSION and run the following two commands to create a source distribution, create a universal wheel, and upload to PyPI

python setup.py sdist
python setup.py bdist_wheel --universal
twine upload dist/*

See Also

Metadata

Release files for xq 0.0.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for xq 0.0.4
File Size Uploaded
xq-0.0.4.tar.gz 4.1 kB Details

Built distributions (wheels)

Table of built distributions (wheels) for xq 0.0.4
File Interpreter ABI Platform
xq-0.0.4-py3.6.egg Legacy Egg format - - Details
xq-0.0.4-py2.py3-none-any.whl Python 2, Python 3 none any Details

Total release size: 20.6 kB

Release files / xq-0.0.4.tar.gz

Download URL xq-0.0.4.tar.gz
Size 4.1 kB
Tags Source
SHA-256 checksum
How to use checksums
28574d5c614d4012a8ad0e08b1c53712f4d69c9f1d8a6c7aa3134262edd82977
BLAKE2b-256 checksum
How to use checksums
ca9d1b464621f4a18c997579e0cc3ad0ba701c0b917702529a67deeaedade4bf
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / xq-0.0.4-py3.6.egg

Download URL xq-0.0.4-py3.6.egg
Size 9.9 kB
Tags Egg
SHA-256 checksum
How to use checksums
0f553244cdc1e7de9c7af5e707c47cb05a943180a262c7bee0a843f6d54e5b8e
BLAKE2b-256 checksum
How to use checksums
1ae06989fc30f3524dfceb6092b470790223c477f06f1c69785921f0b7a0c775
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / xq-0.0.4-py2.py3-none-any.whl

Download URL xq-0.0.4-py2.py3-none-any.whl
Size 6.7 kB
Tags Python 2 Python 3
SHA-256 checksum
How to use checksums
f1fc71de12ca0608321458269bf007b24eff61efe74382a644ab7cb587a26fd6
BLAKE2b-256 checksum
How to use checksums
5cc8c039729a023207a973a0181f41debf07ee03ad3e167693b1900445ef4f05
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

0.0.4 This release

3 release files

0.0.3

3 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page