README.md in timetrap-1.8.11 vs README.md in timetrap-1.8.12
- old
+ new
@@ -14,10 +14,12 @@
This will place a ``t`` executable in your path.
### Basic Usage
$ # get help
+ $ timetrap --help
+ $ # or
$ t --help
Timetrap maintains a list of *timesheets*.
$ # create the "coding" timesheet
@@ -197,29 +199,33 @@
`formatter_search_paths` option.
All timetrap formatters live under the namespace `Timetrap::Formatters` so
define your class like this:
- class Timetrap::Formatters::Notes
- end
+```ruby
+class Timetrap::Formatters::Notes
+end
+```
When `t display` is invoked, timetrap initializes a new instance of the
formatter passing it an Array of entries. It then calls `#output` which should
return a string to be printed to the screen.
This means we need to implement an `#initialize` method and an `#output`
method for the class. Something like this:
- class Timetrap::Formatters::Notes
- def initialize(entries)
- @entries = entries
- end
+```ruby
+class Timetrap::Formatters::Notes
+ def initialize(entries)
+ @entries = entries
+ end
- def output
- @entries.map{|entry| entry[:note]}.join("\n")
- end
- end
+ def output
+ @entries.map{|entry| entry[:note]}.join("\n")
+ end
+end
+```
Now when I invoke it:
$ t d -f notes
working on issue #123
@@ -299,11 +305,12 @@
usage: ``t now``
**out**
Stop the timer for the current timesheet. Must be called after in. Accepts an
optional --at flag. Accepts an optional TIMESHEET name to check out of a
- running, non-current sheet.
+ running, non-current sheet. Will check out of all running sheets if the
+ auto_checkout configuration option is enabled.
usage: ``t out [--at TIME] [TIMESHEET]``
**resume**
Start the timer for the current timesheet with the same notes as the last entry.
@@ -368,10 +375,13 @@
**default_formatter**: The format to use when display is invoked without a
`--format` option
**default_command**: The default command to invoke when you call `t`
- **auto_checkout**: Automatically check out of running entries when you check in
+ **auto_checkout**: Automatically check out of running entries when you check
+ in or out
+
+ **require_note**: Prompt for a note if one isn't provided when checking in
Autocomplete
------------
Timetrap has some basic support for autocomplete in bash and zsh.