feat(prayer-times): add support to Mawaqit#3
Conversation
An error I would see with the install.sh script would be that the selected options from the script were not reflected in the script installed, after investigation it seems like the sed commands targeted single quotes, so by setting single-quotes everywhere it fixed it.
|
Hijri calendar of the current year also need to be fetched and added to the final JSON before saving to |
Adds a new method that allows for scraping the prayer times from the Mawaqit (https://mawaqit.net) service, which powers numerous Mosques around the world to communicate its prayer times. By selecting the 99th method you can specify during the install the ID of your Mosque to get the prayer times.
Mawaqit sends yearly calendars for the prayer times, so if the JSON is already present, there is no need to fetch it another time if the year in the JSON is still current.
|
Assalamu alaykum @0xzer0x this is a good suggestion, however Mawaqit is sending the prayer times calendar in gregorian format only I still added the yearly check though, you were right no need to fetch if the year hasn't changed |
|
Walaikum Assalam, We will need to send an additional request to Al Adhan API to get the hijri calendar for the current month and save it locally in order to be able to display it. This will also require adjusting the hijri function to use the correct file with the correct |
|
@0xzer0x Should be ready for review now 👍 |
Fetches the Aladhan API to make the current month's hijri calendar available in the JSON, making the new API support more feature complete.
Adds a new method that allows for scraping the prayer times from the
Mawaqit (https://mawaqit.net/) service, which powers numerous Mosques
around the world to communicate its prayer times.
By selecting the 99th method you can specify during the install the ID
of your Mosque to get the prayer times.
Also adds a small patch to fix the install script which didn't work correctly
for me.