Bahn2GPX

For me, the best option to travel long distances within Germany is to take the train. I don’t have a car since July, but I have a BahnCard 50 for years, with which I get up to 50% discount on (unfortunately very expensive!) train tickets.

I also recently implemented the option to visualize GPX files in GoBlog.

Now combine both and I have a new use case: In my diary (for which I also use GoBlog) and on my blog I want to be able to display my train trips!

There is indeed the tool BRouter, where you can click on the stations on the map and the train route is then marked. This is a great tool! But for long distances this is too much work for me and actually it is enough for me if only the stations are marked and the distance between them is shown as a line.

That’s why I created a little tool (Bahn2GPX) that knows all stations in Germany. Via the command line, I can specify all stations and at the end the tool gives me a GPX file with the route.

Here is an example: This is the route I usually take to visit my family in the south of Germany.

Interactions & Comments