We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 438ce2e + d3b0d22 commit 9fb4a65Copy full SHA for 9fb4a65
scripts/dl-and-index.sh
@@ -54,11 +54,12 @@ rm -rf tpdc
54
# param2: import folder name
55
function import_gtfs {
56
unzip -o $1
57
-
58
- # extract feed id
59
- index=$(sed -n $'1s/,/\\\n/gp' feed_info.txt | grep -nx 'feed_id' | cut -d: -f1)
60
- prefix=$(cat feed_info.txt | sed -n 2p | cut -d "," -f $index)
61
- node $TOOLS/pelias-gtfs/import -d $DATA/$2 --prefix=$prefix
+ if [ -f stops.txt ]; then
+ # extract feed id
+ index=$(sed -n $'1s/,/\\\n/gp' feed_info.txt | grep -nx 'feed_id' | cut -d: -f1)
+ prefix=$(cat feed_info.txt | sed -n 2p | cut -d "," -f $index)
+ node $TOOLS/pelias-gtfs/import -d $DATA/$2 --prefix=$prefix
62
+ fi
63
# remove already parsed gtfs files
64
rm *.txt
65
}
0 commit comments