rubdo 0.1.8 → 0.1.9

Sign up to get free protection for your applications and to get access to all the features.
data/.rake_tasks ADDED
@@ -0,0 +1,3 @@
1
+ build
2
+ install
3
+ release
data/lib/rubdo/cli.rb CHANGED
@@ -23,11 +23,8 @@ module Rubdo
23
23
  end
24
24
 
25
25
  def done
26
- @list.done @id
27
- end
28
-
29
- def remove
30
- @list.remove @id
26
+ task = @list.list @id
27
+ @list.done task
31
28
  end
32
29
 
33
30
  def save
@@ -40,11 +37,12 @@ module Rubdo
40
37
  end
41
38
 
42
39
  def info
40
+ task = @list.list @id
43
41
  puts @list.info @id
44
42
  end
45
43
 
46
- def completed
47
- @list.completed.each { |item| puts "#{item.description}, completed at: #{item.completed_at.strftime('%m.%d.%y - %H:%M')}" }
44
+ def remove
45
+ @list.items.delete_at @id
48
46
  end
49
47
 
50
48
  def edit
@@ -56,8 +54,8 @@ module Rubdo
56
54
  tmp_file.delete
57
55
  end
58
56
 
59
- def remove
60
- @list.items.delete_at @id
57
+ def completed
58
+ @list.completed.each { |item| puts "#{item.description}, completed at: #{item.completed_at.strftime('%m.%d.%y - %H:%M')}" }
61
59
  end
62
60
 
63
61
  def help
data/lib/rubdo/list.rb CHANGED
@@ -30,10 +30,10 @@ module Rubdo
30
30
  end
31
31
 
32
32
  def done(id)
33
- abort("that id doesn't exists") if @items[id].nil?
34
- @items[id].done = true
35
- @items[id].completed_at = Time.new
36
- @completed << @items[id]
33
+ abort("that id doesn't exists") if task.nil?
34
+ task.done = true
35
+ task.completed_at = Time.new
36
+ @completed << task
37
37
  end
38
38
 
39
39
  def info(id)
data/lib/rubdo/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Rubdo
2
- VERSION = "0.1.8"
2
+ VERSION = "0.1.9"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rubdo
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.8
4
+ version: 0.1.9
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2012-09-22 00:00:00.000000000 Z
12
+ date: 2012-10-03 00:00:00.000000000 Z
13
13
  dependencies: []
14
14
  description: A quick and dirty todo application
15
15
  email:
@@ -20,6 +20,7 @@ extensions: []
20
20
  extra_rdoc_files: []
21
21
  files:
22
22
  - .gitignore
23
+ - .rake_tasks
23
24
  - Gemfile
24
25
  - LICENSE
25
26
  - README.md