From OpenStreetMap Wiki
Jump to navigation Jump to search

I do not know if it is useful to someone, but here's my mapedit2gpx convertor. It eats same input cgpsmapper does, and produces gpx output.

cat << EOF
<?xml version="1.0" encoding="ISO-8859-2"?>
<gpx xmlns="" xmlns:xsi=""
xsi:schemaLocation="" version="1.1"
creator="Pavel's crazy script">

cat /tmp/ | grep Data0 | sed 's/),(/_/g' | tr '_' '\n' | sed 's/Data0=//' | tr -d '()' | tr ',' ' ' | while true ; do
        read A B || exit
        echo "<wpt lat=\"$A\" lon=\"$B\"><name>Foo</name></wpt>"
echo "</gpx>"