diff options
author | Markus Holtermann <info@markusholtermann.eu> | 2014-10-08 00:37:41 +0200 |
---|---|---|
committer | Markus Holtermann <info@markusholtermann.eu> | 2014-10-08 00:55:03 +0200 |
commit | 819ca3ea5848b605bf87221721297fb24131e408 (patch) | |
tree | 6018058e405e010e88270623c1d1cc547a170669 | |
parent | 164d370ebb8356fa9f397f599dd53702852edc47 (diff) | |
download | bvg-grabber-819ca3ea5848b605bf87221721297fb24131e408.tar.gz bvg-grabber-819ca3ea5848b605bf87221721297fb24131e408.tar.bz2 bvg-grabber-819ca3ea5848b605bf87221721297fb24131e408.zip |
Fixed #6 -- Added some installation and usage instructions
-rw-r--r-- | README.rst | 61 |
1 files changed, 61 insertions, 0 deletions
@@ -30,3 +30,64 @@ Pictures: .. image:: https://markusholtermann.eu/images/BVG-Grabber-LightningTalk-installation2tb.jpg :alt: Installation 2 + + +Installation +============ + +To use *bvg-grabber* go and install it as you do with every Python package:: + + $ pip install bvg-grabber + +or:: + + $ pip install --user bvg-grabber + + +Usage +===== + +*bvg-grabber* comes with a simple command line tool ``bvg-grabber.py``:: + + $ bvg-grabber.py --help + usage: bvg-grabber.py [-h] + [--vehicle [{S,U,TRAM,BUS,FERRY,RB,IC} [{S,U,TRAM,BUS,FERRY,RB,IC} ...]]] + [--limit LIMIT] + station file + + Query the BVG-website for departures + + positional arguments: + station The station to query + file Path to file. Use - for stdout + + optional arguments: + -h, --help show this help message and exit + --vehicle [{S,U,TRAM,BUS,FERRY,RB,IC} [{S,U,TRAM,BUS,FERRY,RB,IC} ...]] + Vehicles which shall be queried, if non given + actualdepartue (bus) will be used + --limit LIMIT Max departures to query + + +Example:: + + $ bvg-grabber.py "U Ernst-Reuter-Platz (Berlin)" - --vehicle U --limit 2 | json_pp + [ + [ + "U Ernst-Reuter-Platz (Berlin)", + [ + { + "line" : "U2", + "end" : "U Ruhleben (Berlin)", + "remaining" : 12180, + "start" : "U Ernst-Reuter-Platz (Berlin)" + }, + { + "line" : "U2", + "start" : "U Ernst-Reuter-Platz (Berlin)", + "remaining" : 12600, + "end" : "S+U Pankow (Berlin)" + } + ] + ] + ] |