By running
ruby gpx2geojson.rb test.gpx
test.csv
will be created. Then use mapbox/csv2geojson to make .geojson
file.
npm install -g csv2geojson
csv2geojson test.csv > test.geojson
test.csv
is like this:
lat, lon
35.721219, 139.766585
35.721155, 139.766634
35.721209, 139.766607
35.721176, 139.766655
35.721225, 139.766655
35.721268, 139.766623
35.72131, 139.76658
GeoJSON file like this will be created.