Skip to main content

Pyformatting is a collection of useful formatting features.

Project description

pyformatting

Pyformatting is a collection of useful formatting features.

>>> from pyformatting import optional_format, defaultformatter
>>> optional_format('{:.3f}{other:.5f}{}', .12345)
'0.123{other:.5f}{}'
>>> optional_format('{0[0]}{1!a}{2}{0[1]!r}', 'cool')
"c{1!a}{2}'o'"
>>> default_format = defaultformatter(str)
>>> default_format('{nothing}{data}{quotes!r}', data={1: 2})
"{1: 2}''"

Installing Pyformatting

Pyformatting is available on PyPI:

python -m pip install -U pyformatting

Supported Versions

Pyformatting supports Python 3.1+.

Development Status

Alpha

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

pyformatting-0.3.3.tar.gz (6.1 kB view details)

Uploaded Source

Built Distribution

pyformatting-0.3.3-py3-none-any.whl (9.1 kB view details)

Uploaded Python 3

File details

Details for the file pyformatting-0.3.3.tar.gz.

File metadata

  • Download URL: pyformatting-0.3.3.tar.gz
  • Upload date:
  • Size: 6.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.3.1 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.1

File hashes

Hashes for pyformatting-0.3.3.tar.gz
Algorithm Hash digest
SHA256 f2011655384594bbc03aa519e2f6813017956e38b48f1688e5f84bbaa1c7ce8c
MD5 b9ef8d5e728609c4892326daa1f07a2f
BLAKE2b-256 c0f51eb320ec193155f742283c20051588524d2aee5c1b4e0d608d42fa11f7f2

See more details on using hashes here.

File details

Details for the file pyformatting-0.3.3-py3-none-any.whl.

File metadata

  • Download URL: pyformatting-0.3.3-py3-none-any.whl
  • Upload date:
  • Size: 9.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/49.3.1 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.1

File hashes

Hashes for pyformatting-0.3.3-py3-none-any.whl
Algorithm Hash digest
SHA256 8044950760ba3c5e922eaa2e066109c4e821a4417fe972998aa4745feb913018
MD5 4c32464e629b6446ae8ff631b0246aa0
BLAKE2b-256 43830130eb43419d274dc2282b81119064015c79ce143aabecb8263b7d761099

See more details on using hashes here.

Supported by

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