Skip to main content

A functional string utility library for Python

Project description

A functional string utility library for Python 2 and 3. Closely inspired by implementations in Haskell and PHP.

For more documentation, please see http://stringutils.readthedocs.io.

Features

The main design goal of this library is to provide helpful string functions which complement what can already be done with str, str.format and textwrap. As such, it includes:

  • A selective set of additional string helper functions.

  • Extended versions of existing str methods as functions where useful.

Installation

Install the latest release from PyPI:

pip install stringutils

Usage

All functions are available directly off the stringutils package. You may choose to import individual functions by name, or import all.

from stringutils import reverse, unwords, words

def reverse_words(string):
    return unwords(map(reverse, words(string)))

Contribute

License

The project is licensed under the MIT license.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

stringutils-0.3.0.tar.gz (3.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

stringutils-0.3.0-py2.py3-none-any.whl (5.5 kB view details)

Uploaded Python 2Python 3

File details

Details for the file stringutils-0.3.0.tar.gz.

File metadata

  • Download URL: stringutils-0.3.0.tar.gz
  • Upload date:
  • Size: 3.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for stringutils-0.3.0.tar.gz
Algorithm Hash digest
SHA256 12c2036b4909715b5fd9c1f962a648eb4fe710aadf6d2e0bdf11cd72bbae3189
MD5 29b92e7e123b69bc06ac268cb519c2b6
BLAKE2b-256 4d3bfb300d8cefb5b5c313c18c8ed636216983767b13336f278b3caddf655579

See more details on using hashes here.

File details

Details for the file stringutils-0.3.0-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for stringutils-0.3.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 ba89138db9f63cc24d82e6c57f47236c699a6ce8e56f42969949f0a0f2c91a5b
MD5 5f257ecd17de2bd784df095a7b90dd7c
BLAKE2b-256 293f9b18b4613165df9c392a91e7b324b8676fd33cd6f90e62050eb81d82cdaf

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page