Skip to main content

Python Library for Tom's Obvious, Minimal Language

Project description

TOML
====

See also https://github.com/mojombo/toml

Python module which parses and emits TOML.

Released under the MIT license.

Passes https://github.com/BurntSushi/toml-test

See http://j.xqz.ca/toml-status for up to date test results.

Current Version of the Specification
------------------------------------

https://github.com/mojombo/toml/blob/b098bd2/README.md

TO DO
-----

- Make sure the library keeps up with the spec as it evolves.

QUICK GUIDE
-----------


```
pip install toml
```


toml.loads --- takes a string to be parsed as toml and returns the corresponding dictionary

toml.dumps --- takes a dictionary and returns a string which is the contents of the corresponding toml file.


There are other functions which I use to dump and load various fragments of toml but dumps and loads will cover most usage.

Example usage:

```
import toml

with open("conf.toml") as conffile:
config = toml.dumps(conffile.read())
# do stuff with config here
. . .
```

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

toml-0.7.0.tar.gz (4.1 kB view details)

Uploaded Source

File details

Details for the file toml-0.7.0.tar.gz.

File metadata

  • Download URL: toml-0.7.0.tar.gz
  • Upload date:
  • Size: 4.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for toml-0.7.0.tar.gz
Algorithm Hash digest
SHA256 58bf09e991d5474191420d206b72fa6f50ac5503269c5bd936123e4b545342f2
MD5 6ecae29b7ce43be158e8434a9aa7e5e3
BLAKE2b-256 9d79457a4f0212935884ac2b5632d88f69a0123825fae5a1da42119f6bc5649a

See more details on using hashes here.

Supported by

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