Koleo CLI
Project description
Koleo CLI
Installation
install via pip by running pip install koleo-cli
it currently allows you to:
- get departures/arrival list for a station
- get train info given its number and name(pull requests are welcome if you know how to get a train object by just the number)
- find a station or list all known stations
- find a connection from station a to b, with filtering by operators
- save a station as your favourite to quickly check it's departures
additionally you can also use the KoleoAPI wrapper directly in your own projects, all returns are fully typed using typing.TypedDict
MY(possibly controversial) design choices:
- platforms and track numbers are shown using arabic numerals instead of roman
- you can change it by adding
use_roman_numerals: true
to your config.json file
- you can change it by adding
- most api queries are cached for 24h
- you can change it by adding
disable_cache: true
to your config.json file
- you can change it by adding
- the cli.py code is really dirty but printing formatted data is hard :<
pull requests are welcome!!
usage: koleo [-h] [-c CONFIG] [--nocolor] {departures,d,dep,odjazdy,o,arrivals,a,arr,przyjazdy,p,trainroute,r,tr,t,poc,pociąg,stations,s,find,f,stacje,ls,connections,do,z,szukaj,path} ...
Koleo CLI
options:
-h, --help show this help message and exit
-c CONFIG, --config CONFIG
Custom config path.
--nocolor Disable color output and formatting
actions:
{departures,d,dep,odjazdy,o,arrivals,a,arr,przyjazdy,p,trainroute,r,tr,t,poc,pociąg,stations,s,find,f,stacje,ls,connections,do,z,szukaj,path}
departures (d, dep, odjazdy, o)
Allows you to list station departures
arrivals (a, arr, przyjazdy, p)
Allows you to list station departures
trainroute (r, tr, t, poc, pociąg)
Allows you to show the train's route
stations (s, find, f, stacje, ls)
Allows you to find stations by their name
connections (do, z, szukaj, path)
Allows you to search for connections from a to b
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
koleo_cli-0.2.137.8.tar.gz
(25.1 kB
view details)
Built Distribution
File details
Details for the file koleo_cli-0.2.137.8.tar.gz
.
File metadata
- Download URL: koleo_cli-0.2.137.8.tar.gz
- Upload date:
- Size: 25.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.9.20
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2a5ab0d1d112441ffb6449a98bd4053993ac1fcbac09f9a6543705d8c9322cea |
|
MD5 | 90c500d7b8248d5713d0f456a7f35870 |
|
BLAKE2b-256 | 383c1cc9207cca3ffecb5e2b0cf0ad92af623ed07745003d70ed2be793d9cd23 |
File details
Details for the file koleo_cli-0.2.137.8-py3-none-any.whl
.
File metadata
- Download URL: koleo_cli-0.2.137.8-py3-none-any.whl
- Upload date:
- Size: 24.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.9.20
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0f5077436c3144161765a31036aa70134e0604342ab6dbb8af22c02d10b81cb2 |
|
MD5 | addd81e253dfa2f0df9e9834789ceb72 |
|
BLAKE2b-256 | b51b48d4101e83e462ef9acba491dfd083450a450acc27bee4216ca79c3fa1c5 |