Medium posts as Markdown to Speech.
Project description
medium-to-speech
Medium posts to Speech.
A Python library for lazy people (like myself), who never finds time to read daily Medium posts and prefer to listen to them instead. It convert medium post to markdown using a Docker container/image then uses gTTs to interface with Google Translate's text-to-speech API which converts text to spoken MP3
files, thereafter plays the generated mp3
files with cvlc
assuming it is installed.
Apt Requirements
You will need to install a few dependencies before you continue:
sudo apt install -y docker-ce mpg123 python3.6 python3.6-dev vlc
Installation
To install run:
pip3 install -U --pre .
Usage
Available arguments:
play_medium_post.py -h
usage: play_medium_post.py [-h] [--play] [--cleanup] [--speed N_SPEED]
[--loglevel LOG_LEVEL] [--url-post MEDIUM_URL]
[--file MARKDOWN_FILE]
optional arguments:
-h, --help show this help message and exit
--play, -p Play generated MP3 files.
--cleanup, -c Cleanup generated MP3 files.
--speed N_SPEED, -s N_SPEED
Play every n'th frame only ie Play speed.
--loglevel LOG_LEVEL log level to use, default [INFO], options [INFO,
DEBUG, ERROR]
--url-post MEDIUM_URL, -u MEDIUM_URL
Medium post URL.
--file MARKDOWN_FILE Specify a Markdown file.
Listen to a Medium post:
play_medium_post.py -ps 1 -u https://medium.com/@mmphego/how-i-managed-to-harness-imposter-syndrome-391fdb754820
Listen to Markdown file:
play_medium_post.py -ps 1 --file README.md
Oh, Thanks!
By the way... thank you! And if you'd like to say thanks... :)
✨🍰✨
Feedback
Feel free to fork it or send me PR to improve it.
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
Built Distribution
File details
Details for the file medium-speech-0.1.1.tar.gz
.
File metadata
- Download URL: medium-speech-0.1.1.tar.gz
- Upload date:
- Size: 8.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.0.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | bc39bcdb6d37ba8e00a4647097c215e42f0e04bf47939b87c296ff73857f8c28 |
|
MD5 | d99e4e5110cc918510165d8984b4a450 |
|
BLAKE2b-256 | 29d3b8906adf9f6b57ed2e0df5d6780c257b5536869a52007fc0bd4f7ca77fcb |
File details
Details for the file medium_speech-0.1.1-py2.py3-none-any.whl
.
File metadata
- Download URL: medium_speech-0.1.1-py2.py3-none-any.whl
- Upload date:
- Size: 7.7 kB
- Tags: Python 2, Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/41.0.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.7
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6ff5e226b456fced26f3dea6f56e296697752960bb3c9d2cce29ee2025d2248d |
|
MD5 | 2e877b2125bb6f37404e5cc71673afa4 |
|
BLAKE2b-256 | 3cbea8bd9724c226d049674c982d16a7643c5771c9799f0892af583fd8687bab |