Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- cat << EOF
- <?xml version="1.0" encoding="UTF-8"?>
- <gpx creator="mapy.cz" version="1.1" xmlns="http://www.topografix.com/GPX/1/1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.topografix.com/GPX/1/1 http://www.topografix.com/GPX/1/1/gpx.xsd">
- <trk>
- <name>tanvald-pruned</name>
- <number>1</number>
- <trkseg>
- EOF
- while read line; do
- lat=`echo "$line" | cut -d " " -f 3`
- lon=`echo "$line" | cut -d " " -f 4`
- echo "<trkpt lat=\"$lat\" lon=\"$lon\"></trkpt>"
- done
- cat << EOF
- </trkseg>
- </trk>
- </gpx>
- EOF
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement