From 6e13f1bff029b3ba40493a458f980b1f991bed7b Mon Sep 17 00:00:00 2001 From: "Dominik M. Kwiatek" Date: Mon, 6 Jan 2020 19:58:34 +0000 Subject: [PATCH] =?UTF-8?q?=C3=96BB=20post-review=20changes?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ambient.d/trains/AT_OEBB.fish | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/ambient.d/trains/AT_OEBB.fish b/ambient.d/trains/AT_OEBB.fish index 984f80f..817709b 100644 --- a/ambient.d/trains/AT_OEBB.fish +++ b/ambient.d/trains/AT_OEBB.fish @@ -1,25 +1,23 @@ ambient_is_ssid "OEBB"; or exit curl -s https://railnet.oebb.at/assets/modules/fis/combined.json | jq -r '" -AMBIENT_AT_OEBB_SPEED=\(.operationalMessagesInfo.speed) AMBIENT_AT_OEBB_SITUATION=\(.operationalMessagesInfo.situation) AMBIENT_AT_OEBB_DELAY=\(.operationalMessagesInfo.delay) +AMBIENT_AT_OEBB_SPEED=\(.operationalMessagesInfo.speed) AMBIENT_AT_OEBB_SPEED_UNIT=km/h AMBIENT_AT_OEBB_LATITUDE=\(.mapInfo.latitude) AMBIENT_AT_OEBB_LONGITUDE=\(.mapInfo.longitude) AMBIENT_AT_OEBB_ORIENTATION=\(.mapInfo.orientation) AMBIENT_AT_OEBB_SERVER_TIME=\(.operationalMessagesInfo.time | strptime("%s") | todate) AMBIENT_AT_OEBB_TRAIN_TYPE=\(.currentJourney.trainType) -AMBIENT_AT_OEBB_VZN=\(.currentJourney.tripNumber) +AMBIENT_AT_OEBB_TRIP_NUMBER=\(.currentJourney.tripNumber) +AMBIENT_AT_OEBB_LINE_NUMBER=\(.currentJourney.linepNumber) AMBIENT_AT_OEBB_ACTUAL_DISTANCE_FROM_LAST_STOP=\(.operationalMessagesInfo.distance) AMBIENT_AT_OEBB_STOP_FIRST=\(.currentJourney.start.all) AMBIENT_AT_OEBB_STOP_FIRST_DEPART_SCHEDULED=\((.forecastTimes | first).departureSchedule) AMBIENT_AT_OEBB_STOP_LAST=\(.currentJourney.destination.all) AMBIENT_AT_OEBB_STOP_LAST_ARRIVE_SCHEDULED=\((.forecastTimes | last).arrivalSchedule) AMBIENT_AT_OEBB_STOP_LAST_ARRIVE_ACTUAL=\((.forecastTimes | last).arrivalForecast) -"' - -curl -s https://railnet.oebb.at/assets/modules/fis/combined.json | jq -r '" AMBIENT_AT_OEBB_STOP_NEXT=\({stationList: .stationList[], station_id: .operationalMessagesInfo.situationStation} | select(.stationList.id == .station_id).stationList.name.all) AMBIENT_AT_OEBB_STOP_NEXT_DEPART_SCHEDULED=\({forecastTimes: .forecastTimes[], station_id: .operationalMessagesInfo.situationStation} | select(.forecastTimes.station_id == .station_id) | .forecastTimes.departureSchedule) AMBIENT_AT_OEBB_STOP_NEXT_DEPART_ACTUAL=\({forecastTimes: .forecastTimes[], station_id: .operationalMessagesInfo.situationStation} | select(.forecastTimes.station_id == .station_id) | .forecastTimes.departureForecast)