toodledo 1.0.0 → 1.0.1

Sign up to get free protection for your applications and to get access to all the features.
data/History.txt CHANGED
@@ -1,3 +1,7 @@
1
+ == 1.0.1 / 2008-02-11
2
+
3
+ * Fix bug in client where priority filter was not being applied.
4
+
1
5
  == 1.0.0 / 2008-02-10
2
6
 
3
7
  * First version released!
data/README.txt CHANGED
@@ -13,8 +13,8 @@ The client allows you to work with Toodledo from the command line. It will
13
13
  work in either interactive or command line mode.
14
14
 
15
15
  You can also use the client in your shell scripts, or use the API directly
16
- as part of a web application. Don't like Toodledo's interface? Write
17
- your own.
16
+ as part of a web application. Want an RSS feed? Want to have the Mac read
17
+ out your top priority? It can all happen.
18
18
 
19
19
  == FEATURES/PROBLEMS:
20
20
 
data/lib/toodledo.rb CHANGED
@@ -5,7 +5,7 @@
5
5
  module Toodledo
6
6
 
7
7
  # Required for gem
8
- VERSION = '1.0.0'
8
+ VERSION = '1.0.1'
9
9
 
10
10
  # Returns the configuration object.
11
11
  def self.get_config()
@@ -156,9 +156,33 @@ module Toodledo
156
156
  # will only show tasks that have this context.
157
157
  #
158
158
  def set_priority_filter(session, input)
159
- input = ask("Selected priority? > ") { |q| q.readline = true }
159
+ if (input == nil)
160
+ input = ask("Selected priority? > ") { |q| q.readline = true }
161
+ end
162
+
163
+ input.strip!
164
+
165
+ if (input =~ /^(\d+)$/)
166
+ input = input.to_i
167
+ else
168
+ input = input.downcase
169
+ case input
170
+ when 'negative'
171
+ input = Priority::NEGATIVE
172
+ when 'low'
173
+ input = Priority::LOW
174
+ when 'medium'
175
+ input = Priority::MEDIUM
176
+ when 'high'
177
+ input = Priority::HIGH
178
+ when 'top'
179
+ input = Priority::TOP
180
+ end
181
+ end
160
182
 
161
- # XXX Should look for 'high' / 'medium' / 'low' and convert
183
+ if (! Priority.valid?(input))
184
+ puts "Unknown priority \"#{input}\" -- (valid range is between -1..3)"
185
+ end
162
186
 
163
187
  @filters[:priority] = input
164
188
  end
metadata CHANGED
@@ -1,54 +1,33 @@
1
1
  --- !ruby/object:Gem::Specification
2
+ rubygems_version: 0.9.2
3
+ specification_version: 1
2
4
  name: toodledo
3
5
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
6
+ version: 1.0.1
7
+ date: 2008-02-11 00:00:00 -08:00
8
+ summary: A command line client and API to Toodledo
9
+ require_paths:
10
+ - lib
11
+ email: will@tersesystems.com
12
+ homepage: http://rubyforge.org/projects/toodledo
13
+ rubyforge_project: toodledo
14
+ description: "== DESCRIPTION: This is a Ruby API and client for http://toodledo.com, a task management website. It implements all of the calls from Toodledo's developer API, and provides a nice wrapper around the functionality. The client allows you to work with Toodledo from the command line. It will work in either interactive or command line mode. You can also use the client in your shell scripts, or use the API directly as part of a web application. Want an RSS feed? Want to have the Mac read out your top priority? It can all happen."
15
+ autorequire:
16
+ default_executable:
17
+ bindir: bin
18
+ has_rdoc: true
19
+ required_ruby_version: !ruby/object:Gem::Version::Requirement
20
+ requirements:
21
+ - - ">"
22
+ - !ruby/object:Gem::Version
23
+ version: 0.0.0
24
+ version:
5
25
  platform: ruby
26
+ signing_key:
27
+ cert_chain:
28
+ post_install_message:
6
29
  authors:
7
30
  - Will Sargent
8
- autorequire:
9
- bindir: bin
10
- cert_chain: []
11
-
12
- date: 2008-02-10 00:00:00 -08:00
13
- default_executable:
14
- dependencies:
15
- - !ruby/object:Gem::Dependency
16
- name: cmdparse
17
- version_requirement:
18
- version_requirements: !ruby/object:Gem::Requirement
19
- requirements:
20
- - - ">="
21
- - !ruby/object:Gem::Version
22
- version: "0"
23
- version:
24
- - !ruby/object:Gem::Dependency
25
- name: highline
26
- version_requirement:
27
- version_requirements: !ruby/object:Gem::Requirement
28
- requirements:
29
- - - ">="
30
- - !ruby/object:Gem::Version
31
- version: "0"
32
- version:
33
- - !ruby/object:Gem::Dependency
34
- name: hoe
35
- version_requirement:
36
- version_requirements: !ruby/object:Gem::Requirement
37
- requirements:
38
- - - ">="
39
- - !ruby/object:Gem::Version
40
- version: 1.5.0
41
- version:
42
- description: "== DESCRIPTION: This is a Ruby API and client for http://toodledo.com, a task management website. It implements all of the calls from Toodledo's developer API, and provides a nice wrapper around the functionality. The client allows you to work with Toodledo from the command line. It will work in either interactive or command line mode. You can also use the client in your shell scripts, or use the API directly as part of a web application. Don't like Toodledo's interface? Write your own."
43
- email: will@tersesystems.com
44
- executables:
45
- - toodledo
46
- extensions: []
47
-
48
- extra_rdoc_files:
49
- - History.txt
50
- - Manifest.txt
51
- - README.txt
52
31
  files:
53
32
  - CHANGELOG
54
33
  - History.txt
@@ -80,32 +59,46 @@ files:
80
59
  - test/parser_helper_test.rb
81
60
  - test/session_test.rb
82
61
  - test/toodledo_functional_test.rb
83
- has_rdoc: true
84
- homepage: http://rubyforge.org/projects/toodledo
85
- post_install_message:
62
+ test_files: []
63
+
86
64
  rdoc_options:
87
65
  - --main
88
66
  - README.txt
89
- require_paths:
90
- - lib
91
- required_ruby_version: !ruby/object:Gem::Requirement
92
- requirements:
93
- - - ">="
94
- - !ruby/object:Gem::Version
95
- version: "0"
96
- version:
97
- required_rubygems_version: !ruby/object:Gem::Requirement
98
- requirements:
99
- - - ">="
100
- - !ruby/object:Gem::Version
101
- version: "0"
102
- version:
103
- requirements: []
67
+ extra_rdoc_files:
68
+ - History.txt
69
+ - Manifest.txt
70
+ - README.txt
71
+ executables:
72
+ - toodledo
73
+ extensions: []
104
74
 
105
- rubyforge_project: toodledo
106
- rubygems_version: 1.0.1
107
- signing_key:
108
- specification_version: 2
109
- summary: A command line client and API to Toodledo
110
- test_files: []
75
+ requirements: []
111
76
 
77
+ dependencies:
78
+ - !ruby/object:Gem::Dependency
79
+ name: cmdparse
80
+ version_requirement:
81
+ version_requirements: !ruby/object:Gem::Version::Requirement
82
+ requirements:
83
+ - - ">"
84
+ - !ruby/object:Gem::Version
85
+ version: 0.0.0
86
+ version:
87
+ - !ruby/object:Gem::Dependency
88
+ name: highline
89
+ version_requirement:
90
+ version_requirements: !ruby/object:Gem::Version::Requirement
91
+ requirements:
92
+ - - ">"
93
+ - !ruby/object:Gem::Version
94
+ version: 0.0.0
95
+ version:
96
+ - !ruby/object:Gem::Dependency
97
+ name: hoe
98
+ version_requirement:
99
+ version_requirements: !ruby/object:Gem::Version::Requirement
100
+ requirements:
101
+ - - ">="
102
+ - !ruby/object:Gem::Version
103
+ version: 1.5.0
104
+ version: