A simple library to convert rtf to text
Project description
striprtf
Purpose
This is a simple library to convert rtf files to python strings. A lot of medical documents are written in rtf format which is not ideal for parsing and further processing. This library converts it to plain old text.
How to use
from striprtf.striprtf import rtf_to_text
rtf = "some rtf encoded string"
text = rtf_to_text(rtf)
print(text)
How to use online
If you don't want to install, there is also an online version available at https://striprtf.dev
History
Pyth was not working for the rtf files I had. The next best thing was this gist: https://gist.github.com/gilsondev/7c1d2d753ddb522e7bc22511cfb08676
Very few additions where made, e.g. better formatting of tables.
Pushing to PyPi
- pip install twine
Run commands
python setup.py sdist bdist_wheel
twine upload -r testpypi dist/*
twine upload -r pypi dist/*
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
striprtf-0.0.20.tar.gz
(5.8 kB
view hashes)
Built Distribution
Close
Hashes for striprtf-0.0.20-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 383907f47a9779966bce58d78d80e69121f850f4f90c9d65c55c3b505cf97b37 |
|
MD5 | 265b4adc19eeb6fb172e6bec0c88ddbf |
|
BLAKE2b-256 | 1d2490ed36db1ecb570ba8c734923b5ca3f01a21969f9b561d98d0bfae546bbc |