Skip to content
Command line utilities for extracting data from HTML/XML with XPath queries.
Python
Find file
Latest commit 13688b3 Feb 4, 2013 @vpetro minor update
Failed to load latest commit information.
.gitignore Added .gitignore; PEP8'd fx and xp. Sep 1, 2011
README changed readme. Feb 2, 2013
fx minor update Feb 4, 2013
xp uses docopt for option parsing. Jan 26, 2013

README

XPath-Tools

fx - Find XPath query
=====================
Generate short paths for accessing a specific string in a given page.

Show generated queries only.
cat doc.html | fx 'search string'

Show generated queries with percentage string match (length based, very simple)
cat doc.html | fx -p 'search string'

Show generated queries with percentage match and fetched content
cat doc.html | fx -p -c 'search string'

xp - Run XPath query
====================
Run Xpath query on a HTML/XML document and show the results.

xp doc.html '//text()'

Something went wrong with that request. Please try again.