A CLI tool for planning hiking, biking, and walking routes using OpenStreetMap data
Project description
trailcli
A CLI tool for planning hiking, biking, and walking routes using OpenStreetMap data.
Usage
uvx trailcli --help
# Geocode a place name
trailcli geocode "Koblenz Hauptbahnhof" --country de
# Reverse geocode coordinates
trailcli reverse 50.3569 7.5890
# Route between two points
trailcli route 50.27 7.72 50.23 7.71 --costing pedestrian --output hike.gpx
# Stitch GPX files together
trailcli stitch approach.gpx trail.gpx exit.gpx --output dayhike.gpx
# Generate an HTML map
trailcli map dayhike.gpx --output dayhike.html --title "Rhine Day Hike"
Run trailcli --help for full documentation of all commands and options.
API Services
This tool relies on free, community-run OpenStreetMap services. Please use them responsibly and respect their rate limits (1 request/second). If you find them useful, consider donating to keep them running.
- Nominatim — Geocoding and reverse geocoding. Donate to OpenStreetMap
- Valhalla (FOSSGIS) — Routing engine for hiking, biking, and driving. Donate to FOSSGIS
Developing Setup
Install uv and git and run the following commands to download the code and setup everything.
git clone https://github.com/piebro/trailcli.git
cd trailcli
uv sync
uv run pre-commit install
Publishing
Update the version in pyproject.toml, commit, and then tag and push:
git tag v0.2.0
git push origin v0.2.0
A GitHub Action will automatically build and publish the new version to PyPI.
Contributing
Contributions are welcome. Open an issue if you want to report a bug or have a feature request.
License
All code in this project is licensed under the MIT License.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file trailcli-0.1.0.tar.gz.
File metadata
- Download URL: trailcli-0.1.0.tar.gz
- Upload date:
- Size: 10.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: uv/0.10.4 {"installer":{"name":"uv","version":"0.10.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
31c7837c0bb64fcf2cf747a43ee8d1e7c4d6f98225acaca93f98e73ac5e482e0
|
|
| MD5 |
aed0b2d717c745ccd6ce08e02f336329
|
|
| BLAKE2b-256 |
a45e852d92d9f57f28d470578645120fa04d2135970cf0a6be216856bad020e4
|
File details
Details for the file trailcli-0.1.0-py3-none-any.whl.
File metadata
- Download URL: trailcli-0.1.0-py3-none-any.whl
- Upload date:
- Size: 13.6 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: uv/0.10.4 {"installer":{"name":"uv","version":"0.10.4","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5829d8332d4132fa6fd3b394f1c281d956504037ab50f6129880a24441eac99a
|
|
| MD5 |
09c1f2c630a1a8b46751a0abdc7a5c0f
|
|
| BLAKE2b-256 |
1b8ad8152ff561d6e90c7f244ff9dfdf7e41cc0cba3a15ab48f1338a2fc200c8
|