Code Monkey home page Code Monkey logo

lirr's Introduction

LIRR.py

Hate opening a browser to get long island railroad train times?

LIRR.py obtains the 4 most recent train times given a source and destination.

Installation

git clone https://github.com/Dannyzen/lirr.git
pip install -r requirements.txt

Usage

python lirr.py -s source -d destination -a [optional] additional hours

Example

run at 3:50pm: python lirr.py -s penn -d hicks -a 2

Source departure times    Destination arrival times      Trip duration in minutes
------------------------  ---------------------------  --------------------------
05:46 PM                  06:31 PM                                             45
05:51 PM                  06:13 PM                                             59
06:01 PM                  06:45 PM                                             44
06:08 PM                  06:59 PM                                             51

Fuzzy String Matching

(core-dev)[davidjarvis@ziz:lirr] 00:13:57 $ python lirr.py -s pens -d hicks

Couldn't autocomplete 'pens' - did you mean one of the following?
oceanside
hempstead gardens
country life press
speonk
glen street
queens village
penn station
kew gardens

lirr's People

Contributors

dannyzen avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

lirr's Issues

Change stations list from dict to csv

Running eval on a file is asking for trouble, even though using ast to parse it as a dict is clever. This is more a taste issue than a bug per say but I'd argue eval is generally not a best practice from a security perspective.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.