neoneo 0.1.0 → 0.1.1
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.tar.gz.sig +0 -0
- data/History.txt +6 -0
- data/Manifest.txt +3 -1
- data/lib/hpricot_extensions.rb +13 -0
- data/lib/neoneo.rb +32 -15
- data/lib/utils.rb +11 -0
- metadata +5 -3
- metadata.gz.sig +0 -0
data.tar.gz.sig
CHANGED
Binary file
|
data/History.txt
CHANGED
data/Manifest.txt
CHANGED
data/lib/neoneo.rb
CHANGED
@@ -1,16 +1,33 @@
|
|
1
|
-
|
1
|
+
require 'rubygems'
|
2
|
+
require 'mechanize'
|
2
3
|
|
4
|
+
$: << File.dirname(__FILE__)
|
5
|
+
|
6
|
+
require 'hpricot_extensions'
|
7
|
+
require 'utils'
|
8
|
+
|
9
|
+
# Get access to No Kahuna (http://www.nokahuna.com/) from your Ruby code.
|
10
|
+
#
|
11
|
+
# Some usage examples:
|
12
|
+
#
|
13
|
+
# require 'rubygems'
|
14
|
+
# require 'neoneo'
|
15
|
+
#
|
16
|
+
# project = Neoneo::User.new('user name', 'password').projects.find('My Project')
|
17
|
+
# project.name = "Cool project"
|
18
|
+
# project.save
|
19
|
+
#
|
20
|
+
# p project.tasks.map {|t| t.name}
|
21
|
+
#
|
22
|
+
# project.categories.find('An existing Category').add_task("Cool new Task",
|
23
|
+
# :assign_to => 'Some Username')
|
24
|
+
#
|
25
|
+
# project.add_task("Another way to add a task and notify ANYONE ;)",
|
26
|
+
# :notify => project.members, :category => "Some Category")
|
3
27
|
module Neoneo
|
4
|
-
require 'rubygems'
|
5
|
-
require 'mechanize'
|
6
|
-
|
7
|
-
require 'hpricot_extensions'
|
8
|
-
require 'utils'
|
9
|
-
|
10
|
-
|
11
28
|
BASE_URL = 'http://nokahuna.com/'
|
12
29
|
PROJECT_URL = "#{BASE_URL}projects/"
|
13
|
-
VERSION = '0.1.
|
30
|
+
VERSION = '0.1.1'
|
14
31
|
|
15
32
|
# A Neoneo::AuthenticationError is thrown whenever No Kahuna reports, that
|
16
33
|
# you're not logged in properly.
|
@@ -231,8 +248,8 @@ module Neoneo
|
|
231
248
|
# - :assign_to => 'Some User Name' OR some_member_object
|
232
249
|
# - :notify => 'Some User Name' OR some_member_object OR an array of them
|
233
250
|
# An example:
|
234
|
-
#
|
235
|
-
#
|
251
|
+
# project = Neoneo::User.new('John Doe', 'god').projects.find('My Project')
|
252
|
+
# project.add_task("A shiny new task",
|
236
253
|
# :assign_to => 'Bob Dillan',
|
237
254
|
# :category => project.categories.first,
|
238
255
|
# :notify => ['John Doe', project.members.last])
|
@@ -273,10 +290,10 @@ module Neoneo
|
|
273
290
|
# Saves the project name and descriptions which you can set simply with
|
274
291
|
# name= and description=
|
275
292
|
# An example:
|
276
|
-
#
|
277
|
-
#
|
278
|
-
#
|
279
|
-
#
|
293
|
+
# project = Neoneo::User.new('John Doe', 'god').projects.find('My Project')
|
294
|
+
# project.name = 'BLA!'
|
295
|
+
# project.description = 'New description'
|
296
|
+
# project.save
|
280
297
|
def save
|
281
298
|
page = user.agent.get(url('edit'))
|
282
299
|
form = page.forms.last
|
data/lib/utils.rb
ADDED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: neoneo
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- "Thorben Schr\xC3\xB6der"
|
@@ -30,7 +30,7 @@ cert_chain:
|
|
30
30
|
kX4sVHCM
|
31
31
|
-----END CERTIFICATE-----
|
32
32
|
|
33
|
-
date: 2008-10-
|
33
|
+
date: 2008-10-24 00:00:00 +02:00
|
34
34
|
default_executable:
|
35
35
|
dependencies:
|
36
36
|
- !ruby/object:Gem::Dependency
|
@@ -68,9 +68,11 @@ files:
|
|
68
68
|
- Manifest.txt
|
69
69
|
- README.txt
|
70
70
|
- Rakefile
|
71
|
+
- lib/hpricot_extensions.rb
|
71
72
|
- lib/neoneo.rb
|
72
|
-
-
|
73
|
+
- lib/utils.rb
|
73
74
|
- spec/neoneo_spec.rb
|
75
|
+
- spec/spec_helper.rb
|
74
76
|
has_rdoc: true
|
75
77
|
homepage:
|
76
78
|
post_install_message:
|
metadata.gz.sig
CHANGED
Binary file
|