gtfs 4.18.0 → 4.18.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +5 -5
- package/dist/bin/gtfs-export.js +18 -0
- package/dist/bin/gtfs-export.js.map +1 -1
- package/dist/bin/gtfs-import.js +18 -0
- package/dist/bin/gtfs-import.js.map +1 -1
- package/dist/bin/gtfsrealtime-update.js.map +1 -1
- package/dist/index.d.ts +286 -283
- package/dist/index.js +19 -6
- package/dist/index.js.map +1 -1
- package/dist/models/models.d.ts +19 -0
- package/dist/models/models.js +18 -0
- package/dist/models/models.js.map +1 -1
- package/package.json +10 -10
package/README.md
CHANGED
|
@@ -158,7 +158,7 @@ Copy `config-sample.json` to `config.json` and then add your projects configurat
|
|
|
158
158
|
| [`gtfsRealtimeExpirationSeconds`](#gtfsrealtimeexpirationseconds) | integer | Amount of time in seconds to allow GTFS-Realtime data to be stored in database before allowing to be deleted. Optional, defaults to 0. |
|
|
159
159
|
| [`ignoreDuplicates`](#ignoreduplicates) | boolean | Whether or not to ignore unique constraints on ids when importing GTFS, such as `trip_id`, `calendar_id`. Optional, defaults to false. |
|
|
160
160
|
| [`ignoreErrors`](#ignoreerrors) | boolean | Whether or not to ignore errors during the import process. If true, failed files will be skipped while the rest are processed. Optional, defaults to false. |
|
|
161
|
-
| [`sqlitePath`](#sqlitepath) | string | A path to
|
|
161
|
+
| [`sqlitePath`](#sqlitepath) | string | A path to a SQLite database. Optional, defaults to using an in-memory database. |
|
|
162
162
|
| [`verbose`](#verbose) | boolean | Whether or not to print output to the console. Optional, defaults to true. |
|
|
163
163
|
|
|
164
164
|
### agencies
|
|
@@ -467,10 +467,10 @@ importGtfs({
|
|
|
467
467
|
|
|
468
468
|
### sqlitePath
|
|
469
469
|
|
|
470
|
-
{String} A path to
|
|
470
|
+
{String} A path to a SQLite database. Optional, defaults to using an in-memory database with a value of `:memory:`.
|
|
471
471
|
|
|
472
472
|
```json
|
|
473
|
-
"sqlitePath": "/
|
|
473
|
+
"sqlitePath": "/tmp/gtfs.sqlite"
|
|
474
474
|
```
|
|
475
475
|
|
|
476
476
|
### verbose
|
|
@@ -543,7 +543,7 @@ Configuration can be a JSON object in your code
|
|
|
543
543
|
import { importGtfs } from 'gtfs';
|
|
544
544
|
|
|
545
545
|
const config = {
|
|
546
|
-
sqlitePath: '/
|
|
546
|
+
sqlitePath: '/tmp/gtfs.sqlite',
|
|
547
547
|
agencies: [
|
|
548
548
|
{
|
|
549
549
|
url: 'https://www.bart.gov/dev/schedules/google_transit.zip',
|
|
@@ -623,7 +623,7 @@ Use `exportGtfs()` in your code to run an export of a GTFS file specified in a c
|
|
|
623
623
|
import { exportGtfs } from 'gtfs';
|
|
624
624
|
|
|
625
625
|
const config = {
|
|
626
|
-
sqlitePath: '/
|
|
626
|
+
sqlitePath: '/tmp/gtfs.sqlite',
|
|
627
627
|
agencies: [
|
|
628
628
|
{
|
|
629
629
|
url: 'https://www.bart.gov/dev/schedules/google_transit.zip',
|
package/dist/bin/gtfs-export.js
CHANGED
|
@@ -237,6 +237,12 @@ var agency = {
|
|
|
237
237
|
name: "agency_email",
|
|
238
238
|
type: "text",
|
|
239
239
|
nocase: true
|
|
240
|
+
},
|
|
241
|
+
{
|
|
242
|
+
name: "cemv_support",
|
|
243
|
+
type: "integer",
|
|
244
|
+
min: 0,
|
|
245
|
+
max: 2
|
|
240
246
|
}
|
|
241
247
|
]
|
|
242
248
|
};
|
|
@@ -1167,6 +1173,12 @@ var routes = {
|
|
|
1167
1173
|
name: "network_id",
|
|
1168
1174
|
type: "text",
|
|
1169
1175
|
prefix: true
|
|
1176
|
+
},
|
|
1177
|
+
{
|
|
1178
|
+
name: "cemv_support",
|
|
1179
|
+
type: "integer",
|
|
1180
|
+
min: 0,
|
|
1181
|
+
max: 2
|
|
1170
1182
|
}
|
|
1171
1183
|
]
|
|
1172
1184
|
};
|
|
@@ -1421,6 +1433,12 @@ var stops = {
|
|
|
1421
1433
|
{
|
|
1422
1434
|
name: "platform_code",
|
|
1423
1435
|
type: "text"
|
|
1436
|
+
},
|
|
1437
|
+
{
|
|
1438
|
+
name: "stop_access",
|
|
1439
|
+
type: "integer",
|
|
1440
|
+
min: 0,
|
|
1441
|
+
max: 1
|
|
1424
1442
|
}
|
|
1425
1443
|
]
|
|
1426
1444
|
};
|