Skip to main content

Koleo CLI

Project description

Koleo CLI

PyPI - Version PyPI - Python Version

Installation

install via pip by running pip install koleo-cli

gif showcasing the functionality

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
  • add station aliases to query them more easily
  • check seat allocation statistics

coming soon™️:

  • TUI ticket purchase interface
  • ticket display
  • your previous tickets + stats
  • find empty compartments 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 koleo-cli.json config file
  • most api queries are cached for 24h
    • you can change it by adding disable_cache: true to your koleo-cli.json config file
  • stations/ls uses emojis by default
    • you can disable them by adding use_country_flags_emoji: false and use_country_flags_emoji: false to your koleo-cli.json config file pull requests are welcome!!
usage: koleo [-h] [-c CONFIG] [--nocolor]
             {departures,d,dep,odjazdy,o,arrivals,a,arr,przyjazdy,p,all,w,wszystkie,all_trains,pociagi,trainroute,r,tr,t,poc,pociąg,traincalendar,kursowanie,tc,k,traindetail,td,tid,id,idpoc,stations,s,find,f,stacje,ls,q,connections,do,z,szukaj,path,trainstats,ts,tp,miejsca,frekwencja,trainconnectionstats,tcs,aliases} ...

Koleo CLI

options:
  -h, --help            show this help message and exit
  -c, --config CONFIG   Custom config path.
  --nocolor             Disable color output and formatting

actions:
  {departures,d,dep,odjazdy,o,arrivals,a,arr,przyjazdy,p,all,w,wszystkie,all_trains,pociagi,trainroute,r,tr,t,poc,pociąg,traincalendar,kursowanie,tc,k,traindetail,td,tid,id,idpoc,stations,s,find,f,stacje,ls,q,connections,do,z,szukaj,path,trainstats,ts,tp,miejsca,frekwencja,trainconnectionstats,tcs,aliases}
    departures (d, dep, odjazdy, o)
                        Allows you to list station departures
    arrivals (a, arr, przyjazdy, p)
                        Allows you to list station departures
    all (w, wszystkie, all_trains, pociagi)
                        Allows you to list all station trains
    trainroute (r, tr, t, poc, pociąg)
                        Allows you to check the train's route
    traincalendar (kursowanie, tc, k)
                        Allows you to check what days the train runs on
    traindetail (td, tid, id, idpoc)
                        Allows you to show the train's route given it's koleo ID
    stations (s, find, f, stacje, ls, q)
                        Allows you to find stations by their name
    connections (do, z, szukaj, path)
                        Allows you to search for connections from a to b
    trainstats (ts, tp, miejsca, frekwencja)
                        Allows you to check seat allocation info for a train.
    trainconnectionstats (tcs)
                        Allows you to check the seat allocations on the train connection given it's koleo ID
    aliases             Save quick aliases for station names!

Project details


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.20.tar.gz (36.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

koleo_cli-0.2.137.20-py3-none-any.whl (39.4 kB view details)

Uploaded Python 3

File details

Details for the file koleo_cli-0.2.137.20.tar.gz.

File metadata

  • Download URL: koleo_cli-0.2.137.20.tar.gz
  • Upload date:
  • Size: 36.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.23

File hashes

Hashes for koleo_cli-0.2.137.20.tar.gz
Algorithm Hash digest
SHA256 00e2082f954272565244b95be83192056036ff1071e1a56338341a0d0ca4132d
MD5 4816fca5d406d03252782013f6861bbb
BLAKE2b-256 f0ac181a03a33b767d8d218f23ed03b8ff6bc0d8dd9b693a4d1d3fa55b53f3b0

See more details on using hashes here.

File details

Details for the file koleo_cli-0.2.137.20-py3-none-any.whl.

File metadata

  • Download URL: koleo_cli-0.2.137.20-py3-none-any.whl
  • Upload date:
  • Size: 39.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.23

File hashes

Hashes for koleo_cli-0.2.137.20-py3-none-any.whl
Algorithm Hash digest
SHA256 83b30ae3146d633ff9fa3ee385889564b0cd17a4cb22c559b1e8fbdb51f17bb7
MD5 5654eb71fe88c483871efad283b85860
BLAKE2b-256 ed0bffec230328301f2cc0f46bc1192ee0848965aae7724575ad426c0dd5d444

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page