0x1eef
3f1ed58432
I came across the pattern in this diff while browsing the [rake](https://github.com/ruby/rake/) source code, and I thought it was worth repeating in quran-json. |
||
---|---|---|
bin | ||
lib/quran-json/quran | ||
libexec/quran-json | ||
share/quran-json | ||
.gitignore | ||
.rubocop.yml | ||
.ruby-version | ||
.sqliterc | ||
Gemfile | ||
Gemfile.lock | ||
LICENSE | ||
README.md | ||
VERSION |
About
quran-json is a dual purpose project where on the one hand it provides a utility for downloading the content of The Quran in multiple languages, and on the other hand it provides a copy of the content that can be downloaded. The content is provided in the JSON format.
share/
- share/quran-json/TheQuran/ar/ contains The Quran in its original Arabic.
- share/quran-json/TheQuran/en/ contains an English translation of The Quran.
- share/quran-json/TheQuran/fa/ contains a Farsi translation of The Quran.
- share/quran-json/TheQuran/pt/ contains a Portuguese translation of The Quran.
- share/quran-json/TheQuran/nl/ contains a Dutch translation of The Quran.
- share/quran-json/TheQuran/fr/ contains a French translation of The Quran.
- share/quran-json/TheQuran/it/ contains an Italian translation of The Quran.
The
share/quran-json/TheQuran
directory contains multiple sub-directories, where each sub-directory represents
a locale (eg en
for English, ar
for Arabic, and so on). Within each sub-directory,
there is a JSON file for each surah (also known as a chapter).
The structure of each JSON file can be described as an array where the first element is an object that contains information about a surah, and the rest of the array contains the content of the surah. The content is composed of two-element arrays - where the first element is the ayah number (also known as a verse number), and the second element is the content of the ayah.
See Surah Al-Fatihah (English) for an example.
bin/
The bin/quran-json executable is a utility for downloading the content of The Quran in multiple languages.
Usage
Usage: quran-json pull [OPTIONS]
-l, --locale LOCALE ar, en, pt, fa, nl, fr, or it (default: en)
-r, --replace Replace existing JSON files (default: no)
-u, --update Replace surah metadata with an updated copy (implies -r, default: no)
Thanks
First and foremost, Alhamdulillah.
Thanks to the following websites for providing the downloadable content:
- https://searchtruth.com for the original Arabic, and the Italian translation.
- https://quran.com for the English, Farsi, Portuguese, Dutch, and French translations.
And sincere thanks to the translators of the content:
- Dr. Mustafa Khattab for the English translation.
- Hussein Taji Kal Dari for the Farsi translation.
- Sofian S. Siregar for the Dutch translation.
- Muhammad Hamidullah for the French translation.
- Hamza Roberto Piccardo for the Italian translation.
License
The "source code" is released under the GPL license.
The content is copyrighted to the translators (listed above).