Quran CLI is a command-line application designed to help users read the Quran, fuzzy search the entire Quran for keywords, access daily verses, and more.
quran-cli-demo.webm
The following options are available for installation:
-
Run the install script (only for Linux and Mac)
curl https://github.com/omeiirr/quran-cli/blob/main/install.sh | bash -
Download a pre-compiled binary for your operating system from the releases page
-
Install it using Go
go install github.com/omeiirr/quran-cli@latest
-
Install on Windows
-
Download quran.exe
-
Move quran.exe to a folder like C:\Program Files\quran
-
Add that folder to the system PATH:
- Open Start > “Environment Variables”
- Add the folder to Path
-
Open Command Prompt or PowerShell:
quran.exe
-
❯ quran --help
A command line app to read Quran, get daily verses, search across the Quran, and more.
Usage:
quran [flags]
quran [command]
Available Commands:
config Manage configuration settings
hadith Interact with hadiths
help Help about any command
list List all chapters/surahs from Quran
random Print a random verse from the Quran
read Print entire chapter or a verse, depending on input
search Search the Quran for verses containing a given query
version Print the current version of quran-cli
Flags:
-h, --help help for quran
Use "quran [command] --help" for more information about a command.
❯ quran hadith --help
Interact with hadiths from different books and collections
Usage:
quran hadith [flags]
quran hadith [command]
Available Commands:
read Read a specific hadith from a book. Available: 'bukhari'
search Search the Hadiths containing a given query
Flags:
-h, --help help for hadith
Use "quran hadith [command] --help" for more information about a command.
Once installed, you can use Quran CLI with the following commands:
-
quran helpLists all available commands. -
quran listLists all chapters/surahs from the Quran. Allows you to select a chapter to read. -
quran randomPrints a random verse from the Quran. -
quran read [surah] [ayat]Prints an entire chapter or a verse, depending on the input.Specify the chapter number (surah) and an optional verse number (ayat).
-
quran search: Search the Quran for verses containing a given query.If you want to search within a specific chapter, for instance the 3rd chapter,
you can use
quran search --chapter 3 <query>orquran search -c3 <query> -
quran version: Prints the version number of quran-cli.
Use quran [command] --help for more information about a command.
This project is licensed under the MIT License. See the LICENSE file for details.
Contributions are welcome! Please feel free to submit issues, bugs, feature requests, and pull requests.
Special thanks to the developers of bubbletea, cobra, fzf, and viper for providing the command-line framework used in this project.
Also extending my gratitutde to the developers of quran.json for providing the content used in this app.