Skip to main content

A parser for the twee format

Project description

pylint workflow Status test workflow Status pypi workflow Status

PyPI - Version PyPI - Python Version PyPI - Status

Read the Docs (version)

Features

Use

# Install by pip
$ python -m pip install pytwee
# Run in console
$ python -m pytwee tests/t001.tw
$ pytwee tests/t001.tw
# Import as a module
import pytwee

story = pytwee.story.Story()

with open('my-story.tw', 'rt') as f:
    parser = pytwee.twee3.Parser(story)
    for line in iter(f.readline, ''):
        parser(line)
    del parser #<- very important

print('story:', story)

License

Static Badge

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

pytwee-0.3.2.tar.gz (8.1 kB view details)

Uploaded Source

Built Distribution

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

pytwee-0.3.2-py3-none-any.whl (8.2 kB view details)

Uploaded Python 3

File details

Details for the file pytwee-0.3.2.tar.gz.

File metadata

  • Download URL: pytwee-0.3.2.tar.gz
  • Upload date:
  • Size: 8.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for pytwee-0.3.2.tar.gz
Algorithm Hash digest
SHA256 ad123dbc1f59814d0d140d480bad08a5e892872772097aa70c2e51b523e34f9d
MD5 eb763e83475fef7c49cc5a416c651429
BLAKE2b-256 fc919c0c4681edfe5e55d51531f4ebcacb470e88cfcbb6267dd1f61095ccd19c

See more details on using hashes here.

Provenance

The following attestation bundles were made for pytwee-0.3.2.tar.gz:

Publisher: pypi.yml on jixingcn/pytwee

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pytwee-0.3.2-py3-none-any.whl.

File metadata

  • Download URL: pytwee-0.3.2-py3-none-any.whl
  • Upload date:
  • Size: 8.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for pytwee-0.3.2-py3-none-any.whl
Algorithm Hash digest
SHA256 a4db07d16c62d77c1b25b64f5f13fb41c077d9d0f06df43895ba8444a32d93f7
MD5 b90040d1788b2b6f5592cfc0647a5887
BLAKE2b-256 2f84345991890c070d4339026b685177de6a695cfe96c280dee809679f1a5321

See more details on using hashes here.

Provenance

The following attestation bundles were made for pytwee-0.3.2-py3-none-any.whl:

Publisher: pypi.yml on jixingcn/pytwee

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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