Skip to content

Commit a34074a

Browse files
committed
Real modified date/time
1 parent 1634ae9 commit a34074a

File tree

4 files changed

+23
-7
lines changed

4 files changed

+23
-7
lines changed

fdp.template

+2-2
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,9 @@
1919
dct:accessRights <https://fdp.wikipathways.org/#accessRights> ;
2020
dct:language <http://id.loc.gov/vocabulary/iso639-1/en>;
2121
fdpo:metadataIssued "2023-03-10T07:42:08.000Z"^^xsd:dateTime;
22-
fdpo:metadataModified "%%DATE2%%T13:06:00.000Z"^^xsd:dateTime;
22+
fdpo:metadataModified "%%ISOTIME%%"^^xsd:dateTime;
2323
dct:issued "2023-03-10T07:42:08.000Z"^^xsd:dateTime;
24-
dct:modified "%%DATE2%%T13:06:00.000Z"^^xsd:dateTime;
24+
dct:modified "%%ISOTIME%%"^^xsd:dateTime;
2525
dcat:contactPoint <https://fdp.wikipathways.org/contact/>;
2626
fdpo:metadataCatalog
2727
<https://fdp.wikipathways.org/catalog/index.ttl> .

index.html

+2-2
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@
2828
dct:accessRights <https://fdp.wikipathways.org/#accessRights> ;
2929
dct:language <http://id.loc.gov/vocabulary/iso639-1/en>;
3030
fdpo:metadataIssued "2023-03-10T07:42:08.000Z"^^xsd:dateTime;
31-
fdpo:metadataModified "2024-07-10T13:06:00.000Z"^^xsd:dateTime;
31+
fdpo:metadataModified "2024-08-02T08:05:08.326986185Z"^^xsd:dateTime;
3232
dct:issued "2023-03-10T07:42:08.000Z"^^xsd:dateTime;
33-
dct:modified "2024-07-10T13:06:00.000Z"^^xsd:dateTime;
33+
dct:modified "2024-08-02T08:05:08.326986185Z"^^xsd:dateTime;
3434
dcat:contactPoint <https://fdp.wikipathways.org/contact/>;
3535
fdpo:metadataCatalog
3636
<https://fdp.wikipathways.org/catalog/index.ttl> .

index.ttl

+2-2
Original file line numberDiff line numberDiff line change
@@ -28,9 +28,9 @@
2828
dct:accessRights <https://fdp.wikipathways.org/#accessRights> ;
2929
dct:language <http://id.loc.gov/vocabulary/iso639-1/en>;
3030
fdpo:metadataIssued "2023-03-10T07:42:08.000Z"^^xsd:dateTime;
31-
fdpo:metadataModified "2024-07-10T13:06:00.000Z"^^xsd:dateTime;
31+
fdpo:metadataModified "2024-08-02T08:05:08.326986185Z"^^xsd:dateTime;
3232
dct:issued "2023-03-10T07:42:08.000Z"^^xsd:dateTime;
33-
dct:modified "2024-07-10T13:06:00.000Z"^^xsd:dateTime;
33+
dct:modified "2024-08-02T08:05:08.326986185Z"^^xsd:dateTime;
3434
dcat:contactPoint <https://fdp.wikipathways.org/contact/>;
3535
fdpo:metadataCatalog
3636
<https://fdp.wikipathways.org/catalog/index.ttl> .

update.groovy

+17-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,20 @@
1-
date2 = "2024-07-10"
1+
import java.time.LocalDateTime
2+
import java.time.ZoneId
3+
import java.time.format.DateTimeFormatter
4+
import java.util.Calendar
5+
6+
calendar = Calendar.getInstance();
7+
year = calendar.get(Calendar.YEAR)
8+
month = calendar.get(Calendar.MONTH) + 1 // January = 0
9+
day = calendar.get(Calendar.MONTH)
10+
if (day < 10) month += -1
11+
if (month < 10) month = "0" + month
12+
date2 = "${year}-${month}-10"
213
date = date2.replaceAll("-", "")
14+
localTime = LocalDateTime.now()
15+
isotime = localTime.atZone(ZoneId.systemDefault()).format(
16+
DateTimeFormatter.ISO_INSTANT
17+
)
318

419
prefixTemplate = new File("prefixes.template").text
520
rdfTemplate = new File("rdf.template").text
@@ -14,6 +29,7 @@ catalogTemplate = new File("catalog.template").text
1429
.replaceAll("%%DATE%%", date).replaceAll("%%DATE2%%", date2)
1530
fdpTemplate = new File("fdp.template").text
1631
.replaceAll("%%DATE%%", date).replaceAll("%%DATE2%%", date2)
32+
.replaceAll("%%ISOTIME%%", isotime)
1733

1834
datasetFolder = new File("dataset/${date}")
1935
if (!datasetFolder.exists()) datasetFolder.mkdir()

0 commit comments

Comments
 (0)