DEV Community

Cover image for Python command line tool to listen to your favourite book
Deepak Raj
Deepak Raj

Posted on • Edited on

2

Python command line tool to listen to your favourite book

There are already a few apps available on market for audiobooks for android and other platforms. For some time there are no library for audiobooks in python. So I decided to create one. I have created a library for audiobooks. It's very easy to use. You can use it for your project. It's under development. I will add more features in the future.

Listening to audiobooks is really helpful for person developement, learning. you can listen to audiobooks while doing other work like cooking, cleaning, driving, etc.

it saves your time and you can learn more. with the help of AudioBook you can also create your library of audiobook.

Features

we are using pyttsx3 engine to convert text to speech and different file reader libraries to read different file formats.

it's available on PyPI. You can install it using pip.

pip install audiobook
Enter fullscreen mode Exit fullscreen mode

Currently, it supports 6 document formats. You can listen to pdf, Docx, epub, txt, HTML, and Mobi files.
you can use it as a command line tool. It's very easy to use. also you can use it as a library in your project.
few basic features are implemented in the CLI tool. There will be more features in the future.

Command line tool

Check the AudioBook version

audiobook --version
Enter fullscreen mode Exit fullscreen mode

To listen your favorite book

audiobook -p <file_path> -r
Enter fullscreen mode Exit fullscreen mode

Save the audio file

audiobook -p <file_path> -s
Enter fullscreen mode Exit fullscreen mode

we will be implementing a few features soon in a short time, like speed control, pause, resume, voice selection, saving audio file page wise and many more.

Hit the star button if you like it. Expecting your feedback.

The source code is available on GitHub. you can contribute to it. you can also create issues if you find any bugs.

Here is the Github link.
Full documentation is available on ReadTheDocs

This project is developed by the Py-Contributors team. which is an open-source community.
we are working on many open-source projects. you can also contribute to our project.

Thanks for reading.

Hostinger image

Get n8n VPS hosting 3x cheaper than a cloud solution

Get fast, easy, secure n8n VPS hosting from $4.99/mo at Hostinger. Automate any workflow using a pre-installed n8n application and no-code customization.

Start now

Top comments (0)

Billboard image

The Next Generation Developer Platform

Coherence is the first Platform-as-a-Service you can control. Unlike "black-box" platforms that are opinionated about the infra you can deploy, Coherence is powered by CNC, the open-source IaC framework, which offers limitless customization.

Learn more

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay