rtt 0.0.0.9 → 0.0.0.10
Sign up to get free protection for your applications and to get access to all the features.
- data/Rakefile +1 -1
- data/db/rtt.sqlite3 +0 -0
- data/lib/rtt.rb +0 -2
- data/lib/rtt/cmd_line_parser.rb +2 -1
- data/lib/rtt/interactive_configurator.rb +3 -5
- data/lib/rtt/report_generator.rb +1 -1
- data/rtt.gemspec +1 -1
- metadata +3 -3
data/Rakefile
CHANGED
@@ -3,7 +3,7 @@ require 'echoe'
|
|
3
3
|
|
4
4
|
# PACKAGING ============================================================
|
5
5
|
|
6
|
-
Echoe.new('rtt', '0.0.0.
|
6
|
+
Echoe.new('rtt', '0.0.0.10') do |p|
|
7
7
|
p.description = 'RTT is a tool for tracking time'
|
8
8
|
p.url = 'http://github.com/marklazz/rtt'
|
9
9
|
p.author = 'Marcelo Giorgi'
|
data/db/rtt.sqlite3
CHANGED
Binary file
|
data/lib/rtt.rb
CHANGED
data/lib/rtt/cmd_line_parser.rb
CHANGED
@@ -134,7 +134,8 @@ module Rtt
|
|
134
134
|
when SetUserCommand
|
135
135
|
set_user(cmd.name)
|
136
136
|
when DeleteCommand
|
137
|
-
|
137
|
+
options = env_filters.merge!(:name => cmd.next_optional)
|
138
|
+
delete(options)
|
138
139
|
when ConfigureCommand
|
139
140
|
case cmd.name.downcase
|
140
141
|
when 'task'
|
@@ -103,11 +103,9 @@ module Rtt
|
|
103
103
|
task.rate = rate.to_f
|
104
104
|
task.name = name
|
105
105
|
date= ask_or_default('Date', "Date [Format: DD-MM-YYYY]:", (task.date.strftime("%d-%m-%Y") if task.present? && task.date.present?), /^\d{2,2}-\d{2,2}-\d{4,4}$/)
|
106
|
-
if date.present? && task.date != date
|
107
|
-
|
108
|
-
|
109
|
-
task.end_at = date
|
110
|
-
end
|
106
|
+
task.date = Date.parse(date) if date.present? && task.date != date
|
107
|
+
task.start_at = date
|
108
|
+
task.end_at = date
|
111
109
|
duration = ask_or_default('duration', "Duration:", (task.duration if task.present?), /^(\d{1,2})[hH]{1,2}(\d{1,2})[mM]{1,2}$/)
|
112
110
|
task.duration=(duration) if duration.present?
|
113
111
|
project_name = ask_or_default('project', 'Project name:', (task.project.name if task.present? && task.project.present?), /^\w+$/)
|
data/lib/rtt/report_generator.rb
CHANGED
@@ -12,7 +12,7 @@ module Rtt
|
|
12
12
|
'Client' => Proc.new { |task| (task.client.name) if task.client.present? },
|
13
13
|
'Project' => Proc.new { |task| (task.project.name) if task.project.present? },
|
14
14
|
'Name' => Proc.new { |task| task.name },
|
15
|
-
'Date' => Proc.new { |task| task.date.strftime('%m-%d-%y') },
|
15
|
+
'Date' => Proc.new { |task| task.date.strftime('%m-%d-%y') if task.date.present? },
|
16
16
|
'Rate' => Proc.new { |task| task.rate },
|
17
17
|
'Duration' => Proc.new { |task| task.duration }
|
18
18
|
}
|
data/rtt.gemspec
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rtt
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 91
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 0
|
9
9
|
- 0
|
10
|
-
-
|
11
|
-
version: 0.0.0.
|
10
|
+
- 10
|
11
|
+
version: 0.0.0.10
|
12
12
|
platform: ruby
|
13
13
|
authors:
|
14
14
|
- Marcelo Giorgi
|