Immutable, Pythonic, correct URLs. (LADI project)
Go to file
Mahmoud Hashemi 1c96d0dcb4 bumping docs version 2017-05-06 17:22:55 -07:00
docs bumping docs version 2017-05-06 17:22:55 -07:00
hyperlink better compliance with empty-path behavior recommended in RFC 3986 6.2.3 (and Twisted test suite) 2017-05-06 17:20:00 -07:00
.gitignore initial import from Twisted, with gitignore, license, code, tests, and setup.py 2017-02-14 11:37:11 -08:00
.tox-coveragerc coverage run's "source" can be a path or a module. 2017-04-22 12:55:19 -07:00
.travis.yml Call coverage xml manually before codecov 2017-04-22 13:15:30 -07:00
CHANGELOG.md few more questions, todo updates, and changelog clarifications 2017-04-15 13:49:35 -07:00
LICENSE MIT 2017-04-15 15:23:48 -07:00
README.md docs and version links/badges in README 2017-04-22 01:12:58 -07:00
TODO.md better compliance with empty-path behavior recommended in RFC 3986 6.2.3 (and Twisted test suite) 2017-05-06 17:20:00 -07:00
appveyor.yml Call coverage xml manually before codecov 2017-04-22 13:15:30 -07:00
pytest.ini add pytest.ini to enable doctest ALLOW_UNICODE (to get rid of errors on u'') 2017-03-13 23:09:25 -07:00
requirements-test.txt WIP: trying to get tox toxing 2017-03-13 20:19:49 -07:00
setup.cfg add setup.cfg for universal wheels 2017-05-06 17:21:52 -07:00
setup.py bumping version for 17.1.1 release 2017-05-06 17:20:38 -07:00
tox.ini just run coverage on every tox env in an attempt to make codecov actually display some results 2017-04-20 23:19:20 -07:00

README.md

Hyperlink

Cool URLs that don't change.

Hyperlink provides a pure-Python implementation of immutable URLs. Based on RFC 3986 and 3987, the Hyperlink URL makes working with both URIs and IRIs easy.

Hyperlink is tested against Python 2.7, 3.4, 3.5, and PyPy.

Full documentation is available on Read the Docs.

Installation

Hyperlink is a pure-Python package and requires nothing but Python. The easiest way to install is with pip:

   pip install hyperlink

Then, hyperlink away!


    from hyperlink import URL

    url = URL.from_text('http://github.com/mahmoud/hyperlink?utm_souce=README')
    utm_source = url.get('utm_source')
    better_url = url.replace(scheme='https')
    user_url = better_url.click('..')

See the full API docs here.

More information

Hyperlink would not have been possible without the help of Glyph Lefkowitz and many other community members, especially considering that it started as an extract from the Twisted networking library. Thanks to them, Hyperlink's URL has been production-grade for well over a decade.

Still, should you encounter any issues, do file an issue, or submit a pull request.