Skip to content

Commit

Permalink
readme
Browse files Browse the repository at this point in the history
  • Loading branch information
drgrib committed Mar 19, 2017
1 parent 857db70 commit 2572111
Showing 1 changed file with 37 additions and 0 deletions.
37 changes: 37 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# Terminal Timer

`ttimer` is a simple timer that counts down time left in a terminal window. It will send silent system notifications (on mac, windows, or desktop linux) at 90% and 100% completion of the timer.

## Duration Timing

Lets say you want a timer for 3 minutes. Simply enter

```
ttimer -t 3
```

and you will start a timer count down like so

```
== 3m Timer ==
2m55s
```

## Parsing Rules

* All integers less than `100` will be interpretted as minutes
* Any strings fitting a call to `time.ParseDuration` will be interpretted as that duration
* Any strings ending in `a`, `p`, `am`, or `pm` will be interpretted as times
* Any integers greater than `100` will be interpretted as times. E.g. `242` will be interpretted as the next occurence of `2:42` and set to `am` or `pm`, whichever is soonest.

## Timezone Setting

The default timezone for time-based timers is `America/Los_Angeles`. It can be changed using the `-z` option

```
ttimer -t 9a -z UTC
```

Once set, `ttimer` will save the last `-z` option and use it as the default timezone in subsequent runs.

For reference, the list of official `tz` database timezones can be found [here](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List).

0 comments on commit 2572111

Please sign in to comment.