Class: GitTimer::Timer
- Inherits:
-
Thor
- Object
- Thor
- GitTimer::Timer
- Defined in:
- lib/git_timer/cli.rb
Instance Method Summary collapse
Instance Method Details
#work(action) ⇒ Object
15 16 17 18 19 20 21 22 23 24 |
# File 'lib/git_timer/cli.rb', line 15 def work(action) case action when 'start', 'START', 'Start' GitTimer.register_activity({ ticket_id: 'Work', ticket_state: 'Start' }) when 'stop', 'STOP', 'Stop' GitTimer.register_activity({ ticket_id: 'Work', ticket_state: 'Stop' }) else puts 'Invalid action, please use `git_timer start` or `git_timer stop`. Type `git_timer help` for more information.' end end |