obnox/speedcalc.git
3 years agospeedcalc: v0.2 - support miles, yards. support pace. master
Michael Adam [Tue, 3 Nov 2015 10:24:02 +0000 (11:24 +0100)]
speedcalc: v0.2 - support miles, yards. support pace.

Signed-off-by: Michael Adam <obnox@samba.org>
3 years agospeedcalc: add README
Michael Adam [Tue, 3 Nov 2015 10:25:04 +0000 (11:25 +0100)]
speedcalc: add README

Signed-off-by: Michael Adam <obnox@samba.org>
3 years agospeedcalc: add COPYING (GPLv3)
Michael Adam [Tue, 3 Nov 2015 10:21:09 +0000 (11:21 +0100)]
speedcalc: add COPYING (GPLv3)

Signed-off-by: Michael Adam <obnox@samba.org>
3 years agospeedcalc: add support for pace.
Michael Adam [Tue, 3 Nov 2015 00:24:31 +0000 (01:24 +0100)]
speedcalc: add support for pace.

Pace is the reciprocal form of speed, i.e. time required for a distance unit
(minutes per kilometer) instead of distance coverd in a time unit (e.g. km/h).
Runners typically use minutes per kilometer or minutes per mile.

This adds new speed formats for input, in the form of
TIME/m, TIME/yd, TIME/km, TIME/mi, where TIME can be
a time formatted string like for the time input, e.g. "5m10s/km".

On the output side, the following formats are supported:

"s/m", "s/yd", "s/km", "s/mi", and "/m", "/yd", "/km", "/mi",
where the first set of formats print time as plain seconds, while the
second set pretty prints the time with hours, minutes, seconds, etc.

Signed-off-by: Michael Adam <obnox@samba.org>
3 years agospeedcalc: further systematize unit factor calculation
Michael Adam [Tue, 3 Nov 2015 10:14:28 +0000 (11:14 +0100)]
speedcalc: further systematize unit factor calculation

Signed-off-by: Michael Adam <obnox@samba.org>
3 years agospeedcalc: fix detection of three options given
Michael Adam [Tue, 3 Nov 2015 08:56:08 +0000 (09:56 +0100)]
speedcalc: fix detection of three options given

Signed-off-by: Michael Adam <obnox@samba.org>
3 years agospeedcalc: add .gitignore
Michael Adam [Tue, 3 Nov 2015 07:59:15 +0000 (08:59 +0100)]
speedcalc: add .gitignore

Signed-off-by: Michael Adam <obnox@samba.org>
3 years agospeedcalc: also calculate the km/h conversion factors from other factors
Michael Adam [Tue, 3 Nov 2015 00:03:23 +0000 (01:03 +0100)]
speedcalc: also calculate the km/h conversion factors from other factors

Signed-off-by: Michael Adam <obnox@samba.org>
3 years agospeedcalc: fix yd/sec factor
Michael Adam [Tue, 3 Nov 2015 00:01:44 +0000 (01:01 +0100)]
speedcalc: fix yd/sec factor

Signed-off-by: Michael Adam <obnox@samba.org>
3 years agospeedcalc: add miles/hour and yards/second as units for speed
Michael Adam [Mon, 2 Nov 2015 23:51:55 +0000 (00:51 +0100)]
speedcalc: add miles/hour and yards/second as units for speed

Signed-off-by: Michael Adam <obnox@samba.org>
3 years agospeedcalc: add miles and yards to distance units
Michael Adam [Mon, 2 Nov 2015 23:41:19 +0000 (00:41 +0100)]
speedcalc: add miles and yards to distance units

Signed-off-by: Michael Adam <obnox@samba.org>
3 years agospeedcalc: remove trailing spaces.
Michael Adam [Mon, 2 Nov 2015 22:41:22 +0000 (23:41 +0100)]
speedcalc: remove trailing spaces.

Signed-off-by: Michael Adam <obnox@samba.org>
3 years agospeedcalc: change email to samba.org
Michael Adam [Mon, 2 Nov 2015 22:40:53 +0000 (23:40 +0100)]
speedcalc: change email to samba.org

Signed-off-by: Michael Adam <obnox@samba.org>
3 years agospeedcalc: commit original code from 2005
Michael Adam [Mon, 2 Nov 2015 22:11:18 +0000 (23:11 +0100)]
speedcalc: commit original code from 2005

Signed-off-by: Michael Adam <obnox@samba.org>