baby-bro 0.0.14 → 0.0.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.14
1
+ 0.0.15
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{baby-bro}
8
- s.version = "0.0.14"
8
+ s.version = "0.0.15"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Bill Doughty"]
12
- s.date = %q{2011-05-16}
12
+ s.date = %q{2011-05-18}
13
13
  s.default_executable = %q{bro}
14
14
  s.description = %q{Baby Bro monitors timestamp changes of files and and estimates time spent actively working in project directories.}
15
15
  s.email = %q{billdoughty@capitalthought.com}
@@ -54,6 +54,7 @@ module BabyBro
54
54
  cumulative_time = 0
55
55
  if sessions.any?
56
56
  sessions_by_date = sessions.group_by(&:start_date)
57
+ has_sessions_for_date = false
57
58
  sessions_by_date.keys.sort.each do |date|
58
59
  next if report_date && date != report_date
59
60
  sessions = sessions_by_date[date].sort
@@ -62,10 +63,11 @@ module BabyBro
62
63
  $stdout.puts " #{session.start_time.strftime("%I:%M %p")} - #{session.duration_in_english}" unless @config.brief
63
64
  cumulative_time += session.duration
64
65
  end
66
+ has_sessions_for_date = true
65
67
  $stdout.print " Total:" unless @config.brief && report_date
66
68
  $stdout.print " #{Session.duration_in_english(sessions.inject(0){|sum,n| sum = sum+n.duration})}"
67
69
  end
68
- $stdout.puts
70
+ $stdout.puts has_sessions_for_date ? "" : " no activity"
69
71
  $stdout.puts "Grand Total: #{Session.duration_in_english(cumulative_time)}" unless @config.brief
70
72
  else
71
73
  $stdout.puts " No sessions for this project."
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: baby-bro
3
3
  version: !ruby/object:Gem::Version
4
- hash: 3
4
+ hash: 1
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 0
9
- - 14
10
- version: 0.0.14
9
+ - 15
10
+ version: 0.0.15
11
11
  platform: ruby
12
12
  authors:
13
13
  - Bill Doughty
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2011-05-16 00:00:00 -05:00
18
+ date: 2011-05-18 00:00:00 -05:00
19
19
  default_executable: bro
20
20
  dependencies:
21
21
  - !ruby/object:Gem::Dependency