liquidplanner 0.0.4 → 0.0.5

Sign up to get free protection for your applications and to get access to all the features.
data/Rakefile CHANGED
@@ -1,43 +1,7 @@
1
1
  require 'rake'
2
2
  require 'rake/testtask'
3
- require 'rake/rdoctask'
4
- require File.dirname(__FILE__) + "/lib/liquidplanner.rb"
5
-
6
- require 'rubygems'
7
-
8
- begin
9
- require 'jeweler'
10
- Jeweler::Tasks.new do |gemspec|
11
- gemspec.name = "liquidplanner"
12
- gemspec.summary = "LiquidPlanner API client"
13
- gemspec.version = LiquidPlanner::VERSION
14
- gemspec.description = "LiquidPlanner API client, using ActiveResource"
15
- gemspec.email = "api@liquidplanner.com"
16
- gemspec.homepage = "http://github.com/liquidplanner/liquidplanner"
17
- gemspec.authors = ["Brett Bender", "Adam Sanderson", "Mark Holton"]
18
-
19
- gemspec.files = FileList["[A-Z]*", "{examples,lib,test}/**/*"]
20
-
21
- gemspec.add_dependency 'activeresource', '~> 3.0.0', '>= 3.0.0' # Ensure that we do not use beta gems
22
- gemspec.add_dependency 'activesupport', '~> 3.0.0', '>= 3.0.0' # Ensure that we do not use beta gems
23
- gemspec.add_dependency 'multipart-post', '~> 1.0.1', '>= 1.0.1'
24
3
 
25
- # For the examples:
26
- gemspec.add_development_dependency 'highline', '>= 1.5'
27
-
28
- # For the tests:
29
- gemspec.test_files = FileList["test/**/*_test.rb"]
30
- gemspec.add_development_dependency 'mocha', '= 0.9.8'
31
- end
32
- rescue LoadError
33
- puts "Jeweler not available. Install it with: gem install jeweler"
34
- end
35
-
36
- Rake::RDocTask.new do |t|
37
- t.main = "README.rdoc"
38
- t.rdoc_files.include("README.rdoc")
39
- t.rdoc_files.include("lib/**/*.rb")
40
- end
4
+ require File.dirname(__FILE__) + "/lib/liquidplanner.rb"
41
5
 
42
6
  Rake::TestTask.new do |t|
43
7
  t.libs << 'lib'
@@ -1,10 +1,20 @@
1
1
  # Require the LiquidPlanner API.
2
- require File.dirname(__FILE__) + '/../lib/liquidplanner'
2
+ require File.expand_path("../lib/liquidplanner", File.dirname(__FILE__))
3
3
 
4
4
  # Require support libraries used by this example.
5
- require 'rubygems'
5
+ require 'rubygems'
6
6
  require 'highline/import'
7
- require File.dirname(__FILE__) + '/support/helper'
7
+ require File.expand_path("./support/helper", File.dirname(__FILE__))
8
+
9
+ # Create a new task in the workspace
10
+ #
11
+ # You will:
12
+ # * Access a workspace
13
+ # * Create and estimate a task
14
+ #
15
+ # This example will use the highline library to handle input and output.
16
+ # You can install it with:
17
+ # gem install highline
8
18
 
9
19
  # Get the user's credentials
10
20
  email, password, space_id = get_credentials!
@@ -13,10 +23,8 @@ email, password, space_id = get_credentials!
13
23
  lp = LiquidPlanner::Base.new(:email=>email, :password=>password)
14
24
  workspace = lp.workspaces(space_id)
15
25
 
16
- unless parent = workspace.packages(:first) || workspace.projects(:first)
17
- say "There are no packages or projects in this workspace; cannot add a task."
18
- exit
19
- end
26
+ # Pick the first container in the workspace to place the task in:
27
+ parent = workspace.packages(:first) || workspace.projects(:first)
20
28
 
21
29
  # Ask for a task's name and estimate
22
30
  say "Add a new task to '#{workspace.name}'"
@@ -1,17 +1,17 @@
1
1
  # Require the LiquidPlanner API.
2
- require File.dirname(__FILE__) + '/../lib/liquidplanner'
2
+ require File.expand_path("../lib/liquidplanner", File.dirname(__FILE__))
3
3
 
4
4
  # Require support libraries used by this example.
5
- require 'rubygems'
6
- require 'highline/import'
7
- require 'active_support/all'
8
- require File.dirname(__FILE__) + '/support/helper'
5
+ require 'rubygems'
6
+ require 'highline/import'
7
+ require File.expand_path("./support/helper", File.dirname(__FILE__))
8
+
9
9
 
10
10
  # List a set of custom fields and custom field values in a workspace.
11
11
  #
12
12
  # You will:
13
13
  # * Access a workspace
14
- # * display the custom Project and custom Task fields in that workspace
14
+ # * Display the custom Project and custom Task fields in that workspace
15
15
  #
16
16
  # This example will use the highline library to handle input and output.
17
17
  # You can install it with:
@@ -1,11 +1,9 @@
1
1
  # Require the LiquidPlanner API.
2
- require File.dirname(__FILE__) + '/../lib/liquidplanner'
2
+ require File.expand_path("../lib/liquidplanner", File.dirname(__FILE__))
3
3
 
4
4
  # Require support libraries used by this example.
5
- require 'rubygems'
6
- require 'highline/import'
7
- require 'active_support/all'
8
- require File.dirname(__FILE__) + '/support/helper'
5
+ require 'highline/import'
6
+ require File.expand_path("./support/helper", File.dirname(__FILE__))
9
7
 
10
8
  # List a set of tasks in a workspace.
11
9
  #
@@ -57,6 +55,6 @@ tasks.each do |task|
57
55
  end
58
56
 
59
57
  # Print the description
60
- say task.description
58
+ say "#{task.description}\n"
61
59
  say "-" * 40
62
60
  end
@@ -1,10 +1,21 @@
1
1
  # Require the LiquidPlanner API.
2
- require File.dirname(__FILE__) + '/../lib/liquidplanner'
2
+ require File.expand_path("../lib/liquidplanner", File.dirname(__FILE__))
3
3
 
4
4
  # Require support libraries used by this example.
5
- require 'rubygems'
5
+ require 'rubygems'
6
6
  require 'highline/import'
7
- require File.dirname(__FILE__) + '/support/helper'
7
+ require File.expand_path("./support/helper", File.dirname(__FILE__))
8
+
9
+ # Track time against a task in a workspace.
10
+ #
11
+ # You will:
12
+ # * Access a workspace
13
+ # * Filter available tasks
14
+ # * Log time to an existing active task
15
+ #
16
+ # This example will use the highline library to handle input and output.
17
+ # You can install it with:
18
+ # gem install highline
8
19
 
9
20
  # Get the user's credentials
10
21
  email, password, space_id = get_credentials!
@@ -20,10 +31,10 @@ say workspace.name
20
31
  say "-" * 40
21
32
 
22
33
  # Get the user's tasks
23
- tasks = workspace.tasks(:all, :filter=>'owner_id = me', :include_associated=>'activities')
34
+ tasks = workspace.tasks(:all, :filter=>['owner_id = me', 'is_done is false'], :include_associated=>'activities')
24
35
 
25
36
  if tasks.empty?
26
- say "No tasks are assigned to you."
37
+ say "No active tasks are assigned to you."
27
38
  exit
28
39
  end
29
40
 
@@ -1,10 +1,11 @@
1
1
  # Require the LiquidPlanner API.
2
- require File.dirname(__FILE__) + '/../lib/liquidplanner'
2
+ require File.expand_path("../lib/liquidplanner", File.dirname(__FILE__))
3
3
 
4
4
  # Require support libraries used by this example.
5
- require 'rubygems'
5
+ require 'rubygems'
6
6
  require 'highline/import'
7
- require File.dirname(__FILE__) + '/support/helper'
7
+ require File.expand_path("./support/helper", File.dirname(__FILE__))
8
+
8
9
 
9
10
  require 'pp'
10
11
  # Get the user's credentials
@@ -1,15 +1,10 @@
1
- $:.unshift(File.dirname(__FILE__)) unless
2
- $:.include?(File.dirname(__FILE__)) || $:.include?(File.expand_path(File.dirname(__FILE__)))
1
+ $:.push File.expand_path(".", File.dirname(__FILE__))
3
2
 
4
3
  module LiquidPlanner
5
- VERSION = "0.0.4"
4
+ VERSION = "0.0.5"
6
5
  API_BASE_URL = "https://app.liquidplanner.com/api"
7
6
  end
8
7
 
9
- require "rubygems"
10
- gem "activeresource", '~> 3.0'
11
- gem "multipart-post"
12
-
13
8
  require "active_resource"
14
9
  require "net/http/post/multipart" # for uploading documents
15
10
 
@@ -30,6 +25,7 @@ require "liquidplanner/resources/treeitem"
30
25
  require "liquidplanner/resources/container"
31
26
  require "liquidplanner/resources/leaf"
32
27
  require "liquidplanner/resources/root"
28
+ require "liquidplanner/resources/inbox"
33
29
  require "liquidplanner/resources/task"
34
30
  require "liquidplanner/resources/event"
35
31
  require "liquidplanner/resources/milestone"
@@ -0,0 +1,6 @@
1
+ module LiquidPlanner
2
+ module Resources
3
+ class Inbox < Container
4
+ end
5
+ end
6
+ end
metadata CHANGED
@@ -1,103 +1,129 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: liquidplanner
3
- version: !ruby/object:Gem::Version
4
- version: 0.0.4
5
- prerelease:
3
+ version: !ruby/object:Gem::Version
4
+ prerelease: false
5
+ segments:
6
+ - 0
7
+ - 0
8
+ - 5
9
+ version: 0.0.5
6
10
  platform: ruby
7
- authors:
11
+ authors:
8
12
  - Brett Bender
9
13
  - Adam Sanderson
10
14
  - Mark Holton
11
15
  autorequire:
12
16
  bindir: bin
13
17
  cert_chain: []
14
- date: 2012-06-22 00:00:00.000000000 -07:00
18
+
19
+ date: 2012-10-08 00:00:00 -07:00
15
20
  default_executable:
16
- dependencies:
17
- - !ruby/object:Gem::Dependency
21
+ dependencies:
22
+ - !ruby/object:Gem::Dependency
18
23
  name: activeresource
19
- requirement: &2222498920 !ruby/object:Gem::Requirement
24
+ prerelease: false
25
+ requirement: &id001 !ruby/object:Gem::Requirement
20
26
  none: false
21
- requirements:
22
- - - ! '>='
23
- - !ruby/object:Gem::Version
24
- version: 3.0.0
27
+ requirements:
25
28
  - - ~>
26
- - !ruby/object:Gem::Version
29
+ - !ruby/object:Gem::Version
30
+ segments:
31
+ - 3
32
+ - 0
33
+ - 0
34
+ version: 3.0.0
35
+ - - ">="
36
+ - !ruby/object:Gem::Version
37
+ segments:
38
+ - 3
39
+ - 0
40
+ - 0
27
41
  version: 3.0.0
28
42
  type: :runtime
29
- prerelease: false
30
- version_requirements: *2222498920
31
- - !ruby/object:Gem::Dependency
43
+ version_requirements: *id001
44
+ - !ruby/object:Gem::Dependency
32
45
  name: activesupport
33
- requirement: &2222498160 !ruby/object:Gem::Requirement
46
+ prerelease: false
47
+ requirement: &id002 !ruby/object:Gem::Requirement
34
48
  none: false
35
- requirements:
36
- - - ! '>='
37
- - !ruby/object:Gem::Version
38
- version: 3.0.0
49
+ requirements:
39
50
  - - ~>
40
- - !ruby/object:Gem::Version
51
+ - !ruby/object:Gem::Version
52
+ segments:
53
+ - 3
54
+ - 0
55
+ - 0
56
+ version: 3.0.0
57
+ - - ">="
58
+ - !ruby/object:Gem::Version
59
+ segments:
60
+ - 3
61
+ - 0
62
+ - 0
41
63
  version: 3.0.0
42
64
  type: :runtime
43
- prerelease: false
44
- version_requirements: *2222498160
45
- - !ruby/object:Gem::Dependency
65
+ version_requirements: *id002
66
+ - !ruby/object:Gem::Dependency
46
67
  name: multipart-post
47
- requirement: &2222497400 !ruby/object:Gem::Requirement
68
+ prerelease: false
69
+ requirement: &id003 !ruby/object:Gem::Requirement
48
70
  none: false
49
- requirements:
50
- - - ! '>='
51
- - !ruby/object:Gem::Version
52
- version: 1.0.1
71
+ requirements:
53
72
  - - ~>
54
- - !ruby/object:Gem::Version
73
+ - !ruby/object:Gem::Version
74
+ segments:
75
+ - 1
76
+ - 0
77
+ - 1
78
+ version: 1.0.1
79
+ - - ">="
80
+ - !ruby/object:Gem::Version
81
+ segments:
82
+ - 1
83
+ - 0
84
+ - 1
55
85
  version: 1.0.1
56
86
  type: :runtime
57
- prerelease: false
58
- version_requirements: *2222497400
59
- - !ruby/object:Gem::Dependency
87
+ version_requirements: *id003
88
+ - !ruby/object:Gem::Dependency
60
89
  name: highline
61
- requirement: &2222496660 !ruby/object:Gem::Requirement
90
+ prerelease: false
91
+ requirement: &id004 !ruby/object:Gem::Requirement
62
92
  none: false
63
- requirements:
64
- - - ! '>='
65
- - !ruby/object:Gem::Version
66
- version: '1.5'
93
+ requirements:
94
+ - - ">="
95
+ - !ruby/object:Gem::Version
96
+ segments:
97
+ - 1
98
+ - 5
99
+ version: "1.5"
67
100
  type: :development
68
- prerelease: false
69
- version_requirements: *2222496660
70
- - !ruby/object:Gem::Dependency
101
+ version_requirements: *id004
102
+ - !ruby/object:Gem::Dependency
71
103
  name: mocha
72
- requirement: &2222496180 !ruby/object:Gem::Requirement
104
+ prerelease: false
105
+ requirement: &id005 !ruby/object:Gem::Requirement
73
106
  none: false
74
- requirements:
75
- - - =
76
- - !ruby/object:Gem::Version
107
+ requirements:
108
+ - - "="
109
+ - !ruby/object:Gem::Version
110
+ segments:
111
+ - 0
112
+ - 9
113
+ - 8
77
114
  version: 0.9.8
78
115
  type: :development
79
- prerelease: false
80
- version_requirements: *2222496180
81
- description: LiquidPlanner API client, using ActiveResource
82
- email: api@liquidplanner.com
116
+ version_requirements: *id005
117
+ description: LiquidPlanner API client
118
+ email:
119
+ - api@liquidplanner.com
83
120
  executables: []
121
+
84
122
  extensions: []
85
- extra_rdoc_files:
86
- - README.rdoc
87
- files:
88
- - HISTORY
89
- - README.rdoc
90
- - Rakefile
91
- - examples/README
92
- - examples/create_task.rb
93
- - examples/list_custom_fields.rb
94
- - examples/list_tasks.rb
95
- - examples/post-commit.rb
96
- - examples/support/helper.rb
97
- - examples/svn-post-commit.sh
98
- - examples/track_time.rb
99
- - examples/update_custom_field_value.rb
100
- - lib/liquidplanner.rb
123
+
124
+ extra_rdoc_files: []
125
+
126
+ files:
101
127
  - lib/liquidplanner/base.rb
102
128
  - lib/liquidplanner/debug.rb
103
129
  - lib/liquidplanner/ext/connection.rb
@@ -114,6 +140,7 @@ files:
114
140
  - lib/liquidplanner/resources/estimate.rb
115
141
  - lib/liquidplanner/resources/event.rb
116
142
  - lib/liquidplanner/resources/folder.rb
143
+ - lib/liquidplanner/resources/inbox.rb
117
144
  - lib/liquidplanner/resources/leaf.rb
118
145
  - lib/liquidplanner/resources/link.rb
119
146
  - lib/liquidplanner/resources/luggage.rb
@@ -131,33 +158,52 @@ files:
131
158
  - lib/liquidplanner/resources/treeitem.rb
132
159
  - lib/liquidplanner/resources/workspace.rb
133
160
  - lib/liquidplanner/resources/workspace_resource.rb
161
+ - lib/liquidplanner.rb
162
+ - examples/create_task.rb
163
+ - examples/list_custom_fields.rb
164
+ - examples/list_tasks.rb
165
+ - examples/post-commit.rb
166
+ - examples/README
167
+ - examples/support/helper.rb
168
+ - examples/svn-post-commit.sh
169
+ - examples/track_time.rb
170
+ - examples/update_custom_field_value.rb
171
+ - Rakefile
172
+ - README.rdoc
134
173
  - test/liquidplanner_resource_test.rb
135
174
  - test/workspace_test.rb
136
175
  has_rdoc: true
137
176
  homepage: http://github.com/liquidplanner/liquidplanner
138
177
  licenses: []
178
+
139
179
  post_install_message:
140
180
  rdoc_options: []
141
- require_paths:
181
+
182
+ require_paths:
142
183
  - lib
143
- required_ruby_version: !ruby/object:Gem::Requirement
184
+ required_ruby_version: !ruby/object:Gem::Requirement
144
185
  none: false
145
- requirements:
146
- - - ! '>='
147
- - !ruby/object:Gem::Version
148
- version: '0'
149
- required_rubygems_version: !ruby/object:Gem::Requirement
186
+ requirements:
187
+ - - ">="
188
+ - !ruby/object:Gem::Version
189
+ segments:
190
+ - 0
191
+ version: "0"
192
+ required_rubygems_version: !ruby/object:Gem::Requirement
150
193
  none: false
151
- requirements:
152
- - - ! '>='
153
- - !ruby/object:Gem::Version
154
- version: '0'
194
+ requirements:
195
+ - - ">="
196
+ - !ruby/object:Gem::Version
197
+ segments:
198
+ - 0
199
+ version: "0"
155
200
  requirements: []
201
+
156
202
  rubyforge_project:
157
- rubygems_version: 1.6.2
203
+ rubygems_version: 1.3.7
158
204
  signing_key:
159
205
  specification_version: 3
160
206
  summary: LiquidPlanner API client
161
- test_files:
207
+ test_files:
162
208
  - test/liquidplanner_resource_test.rb
163
209
  - test/workspace_test.rb
data/HISTORY DELETED
@@ -1,11 +0,0 @@
1
- 0.0.1
2
- -----
3
- * Initial release
4
-
5
- 0.0.2
6
- -----
7
- * Ensure non beta ActiveResource libraries are used
8
-
9
- 0.0.3
10
- -----
11
- * Updated for LiquidPlanner 3.0