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.
Metadata
Release files for trailcli 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| trailcli-0.1.0.tar.gz | 10.3 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| trailcli-0.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 23.9 kB
Release files / trailcli-0.1.0.tar.gz
| Download URL | trailcli-0.1.0.tar.gz |
|---|---|
| Size | 10.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
31c7837c0bb64fcf2cf747a43ee8d1e7c4d6f98225acaca93f98e73ac5e482e0
|
|
BLAKE2b-256 checksum How to use checksums |
a45e852d92d9f57f28d470578645120fa04d2135970cf0a6be216856bad020e4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is 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}
|
Release files / trailcli-0.1.0-py3-none-any.whl
| Download URL | trailcli-0.1.0-py3-none-any.whl |
|---|---|
| Size | 13.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
5829d8332d4132fa6fd3b394f1c281d956504037ab50f6129880a24441eac99a
|
|
BLAKE2b-256 checksum How to use checksums |
1b8ad8152ff561d6e90c7f244ff9dfdf7e41cc0cba3a15ab48f1338a2fc200c8
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is 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}
|