jugyo-rubytter 0.3.2 → 0.3.3
Sign up to get free protection for your applications and to get access to all the features.
- data/README.rdoc +27 -14
- data/examples/update_status.rb +3 -3
- data/lib/rubytter.rb +20 -8
- metadata +3 -2
data/README.rdoc
CHANGED
@@ -10,25 +10,38 @@ Rubytter is simple twitter library.
|
|
10
10
|
|
11
11
|
implemented methods:
|
12
12
|
|
13
|
-
- /
|
14
|
-
- /direct_messages/destroy/id
|
15
|
-
- /direct_messages/new
|
16
|
-
- /direct_messages/sent
|
17
|
-
- /followers/ids/id
|
18
|
-
- /friends/ids/id
|
19
|
-
- /friendships/create/id
|
20
|
-
- /friendships/destroy/id
|
21
|
-
- /friendships/exists
|
13
|
+
- /statuses/update
|
22
14
|
- /statuses/destroy/id
|
23
|
-
- /statuses/followers/id
|
24
|
-
- /statuses/friends/id
|
25
|
-
- /statuses/friends_timeline
|
26
15
|
- /statuses/public_timeline
|
16
|
+
- /statuses/friends_timeline
|
27
17
|
- /statuses/replies
|
28
|
-
- /statuses/show/id
|
29
|
-
- /statuses/update
|
30
18
|
- /statuses/user_timeline/id
|
19
|
+
- /statuses/show/id
|
20
|
+
- /statuses/friends/id
|
21
|
+
- /statuses/followers/id
|
31
22
|
- /users/show/id
|
23
|
+
- /direct_messages
|
24
|
+
- /direct_messages/sent
|
25
|
+
- /direct_messages/new
|
26
|
+
- /direct_messages/destroy/id
|
27
|
+
- /friendships/create/id
|
28
|
+
- /friendships/destroy/id
|
29
|
+
- /friendships/exists
|
30
|
+
- /followers/ids/id
|
31
|
+
- /friends/ids/id
|
32
|
+
- /favorites
|
33
|
+
- /favorites/create/id
|
34
|
+
- /favorites/destroy/id
|
35
|
+
- /account/verify_credentials
|
36
|
+
- /account/end_session
|
37
|
+
- /account/update_delivery_device
|
38
|
+
- /account/update_profile_colors
|
39
|
+
- /account/rate_limit_status
|
40
|
+
- /account/update_profile
|
41
|
+
- /notifications/follow/id
|
42
|
+
- /notifications/leave/id
|
43
|
+
- /blocks/create/id
|
44
|
+
- /blocks/destroy/id
|
32
45
|
|
33
46
|
== SYNOPSIS:
|
34
47
|
|
data/examples/update_status.rb
CHANGED
@@ -3,10 +3,10 @@
|
|
3
3
|
require 'rubygems'
|
4
4
|
require 'rubytter'
|
5
5
|
|
6
|
-
if ARGV.size <
|
7
|
-
puts "Usage: ruby #{File.basename(__FILE__)} user_id password"
|
6
|
+
if ARGV.size < 3
|
7
|
+
puts "Usage: ruby #{File.basename(__FILE__)} user_id password text"
|
8
8
|
exit
|
9
9
|
end
|
10
10
|
|
11
11
|
client = Rubytter.new(ARGV[0], ARGV[1])
|
12
|
-
client.update(ARGV[2]
|
12
|
+
client.update(ARGV[2])
|
data/lib/rubytter.rb
CHANGED
@@ -4,7 +4,6 @@ require 'net/https'
|
|
4
4
|
require 'cgi'
|
5
5
|
|
6
6
|
require 'rubytter/connection'
|
7
|
-
require 'rubytter/hash_extension'
|
8
7
|
|
9
8
|
class Rubytter
|
10
9
|
APP_NAME = 'Rubytter'
|
@@ -18,10 +17,10 @@ class Rubytter
|
|
18
17
|
end
|
19
18
|
|
20
19
|
def self.api_settings
|
21
|
-
# method name path for API
|
20
|
+
# method name path for API http method
|
22
21
|
"
|
23
|
-
status_update /statuses/update
|
24
|
-
destroy /statuses/destroy/%s
|
22
|
+
status_update /statuses/update post
|
23
|
+
destroy /statuses/destroy/%s delete
|
25
24
|
public_timeline /statuses/public_timeline
|
26
25
|
friends_timeline /statuses/friends_timeline
|
27
26
|
replies /statuses/replies
|
@@ -32,13 +31,26 @@ class Rubytter
|
|
32
31
|
user /users/show/%s
|
33
32
|
direct_messages /direct_messages
|
34
33
|
sent_direct_messages /direct_messages/sent
|
35
|
-
send_direct_message /direct_messages/new
|
36
|
-
destroy_direct_message /direct_messages/destroy/%s
|
37
|
-
create_friendship /friendships/create/%s
|
38
|
-
destroy_friendship /friendships/destroy/%s
|
34
|
+
send_direct_message /direct_messages/new post
|
35
|
+
destroy_direct_message /direct_messages/destroy/%s delete
|
36
|
+
create_friendship /friendships/create/%s post
|
37
|
+
destroy_friendship /friendships/destroy/%s delete
|
39
38
|
friendship_exists /friendships/exists
|
40
39
|
followers_ids /followers/ids/%s
|
41
40
|
friends_ids /friends/ids/%s
|
41
|
+
favorites /favorites
|
42
|
+
favorite /favorites/create/%s post
|
43
|
+
unfavorite /favorites/destroy/%s delete
|
44
|
+
verify_credentials /account/verify_credentials get
|
45
|
+
end_session /account/end_session post
|
46
|
+
update_delivery_device /account/update_delivery_device post
|
47
|
+
update_profile_colors /account/update_profile_colors post
|
48
|
+
rate_limit_status /account/rate_limit_status
|
49
|
+
update_profile /account/update_profile post
|
50
|
+
enable_notification /notifications/follow/%s post
|
51
|
+
disable_notification /notifications/leave/%s post
|
52
|
+
block /blocks/create/%s post
|
53
|
+
unblock /blocks/destroy/%s delete
|
42
54
|
".strip.split("\n").map{|line| line.strip.split(/\s+/)}
|
43
55
|
end
|
44
56
|
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: jugyo-rubytter
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.3.
|
4
|
+
version: 0.3.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- jugyo
|
@@ -9,11 +9,12 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2009-02-
|
12
|
+
date: 2009-02-13 00:00:00 -08:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: json_pure
|
17
|
+
type: :runtime
|
17
18
|
version_requirement:
|
18
19
|
version_requirements: !ruby/object:Gem::Requirement
|
19
20
|
requirements:
|