Closed ronkot closed 7 years ago
Updated PR to use file $HOME/.routahe
and data structure
{
history: []
}
...which allows easy future expansions. If new properties are added to data structure, it's probably best to move the basic file handling functions to a separate file for common use.
Relates to #4.
This PR has the following functionality:
$HOME/.routahe_history
history.add(from, to)
: Add / update routehistory.get()
: Get whole historyhistory.latestRoute()
: Get latest routehistory.topRoute()
: Get most used routeRoutes are of type
This PR does not yet offer command line api to history data, as the api is going to change in near future.
Feel free to comment!