Fix TSIB feeds

This commit is contained in:
Lucidiot 2021-02-23 19:23:58 +01:00
parent 194fac6d7a
commit 677be1997b
Signed by: lucidiot
GPG Key ID: 3358C1CA6906FB8D
2 changed files with 3 additions and 2 deletions

View File

@ -621,7 +621,7 @@
<curl>
<url>https://www.mot.gov.sg/about-mot/transport-safety-investigation-bureau/msib/investigation-report/</url>
</curl>
<pup>.container-twelve .eight > .row:last-child tbody > tr</pup>
<pup>.safety-investigation-report table tbody tr</pup>
<jq path="tsib.jq">
<arg name="type">Marine</arg>
<arg name="link">https://www.mot.gov.sg/about-mot/transport-safety-investigation-bureau/msib/investigation-report/</arg>
@ -633,7 +633,7 @@
<curl>
<url>https://www.mot.gov.sg/about-mot/transport-safety-investigation-bureau/aaib/investigation-report/</url>
</curl>
<pup>.container-twelve .eight > .row:last-child tbody > tr</pup>
<pup>.safety-investigation-report table tbody tr</pup>
<jq path="tsib.jq">
<arg name="type">Aviation</arg>
<arg name="link">https://www.mot.gov.sg/about-mot/transport-safety-investigation-bureau/aaib/investigation-report/</arg>

View File

@ -21,6 +21,7 @@ import "./helpers" as helpers;
"item": [.[] | {
"title": ((.children[3].children[0].text | .[:index(" (PDF")]) + " - " + .children[2].text),
"link": (.children[3].children[0].href | helpers::urlresolve($link)),
"guid": (.children[3].children[0].href | helpers::urlresolve($link)),
"pubDate": (.children[0].text | strptime("%d %b %Y") | mktime | strftime("%a, %d %b %Y %T %z"))
}]
}