ig3client 0.5.3 → 0.6.0
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/lib/ig3client/marshal_client.rb +1 -2
- data/lib/ig3client/yaml_client.rb +1 -2
- metadata +4 -4
@@ -55,18 +55,17 @@ module Ig3tool
|
|
55
55
|
|
56
56
|
if msg.ends_with? '!'
|
57
57
|
args = [Hash[*args]] if args.length % 2 == 0
|
58
|
-
uri += "//" + @token if @token
|
59
58
|
req = Net::HTTP::Post.new(uri)
|
60
59
|
req["Content-Type"] = "text/marshal"
|
61
60
|
req.body = Marshal.dump(args.first)
|
62
61
|
else
|
63
62
|
args = args[0].to_a.flatten if args[0].is_a? Hash
|
64
|
-
args.unshift(@token) if @token
|
65
63
|
extra = args.map{|a| a.class == String ? URI.encode(a) : a}.join('/')
|
66
64
|
extra = '//'+extra unless extra.empty?
|
67
65
|
req = Net::HTTP::Get.new(uri+extra)
|
68
66
|
end
|
69
67
|
req["Accept"] = "text/marshal"
|
68
|
+
req["Token"] = @token if @token
|
70
69
|
|
71
70
|
|
72
71
|
n = Net::HTTP.new(@host,@port)
|
@@ -47,18 +47,17 @@ module Ig3tool
|
|
47
47
|
|
48
48
|
if msg.ends_with? '!'
|
49
49
|
args = [Hash[*args]] if args.length % 2 == 0
|
50
|
-
uri += "//" + @token if @token
|
51
50
|
req = Net::HTTP::Post.new(uri)
|
52
51
|
req["Content-Type"] = "text/yaml"
|
53
52
|
req.body = args.first.to_yaml
|
54
53
|
else
|
55
54
|
args = args[0].to_a.flatten if args[0].is_a? Hash
|
56
|
-
args.unshift(@token) if @token
|
57
55
|
extra = args.join('/')
|
58
56
|
extra = '//'+extra unless extra.empty?
|
59
57
|
req = Net::HTTP::Get.new(uri+extra)
|
60
58
|
end
|
61
59
|
req["Accept"] = "text/yaml"
|
60
|
+
req["Token"] = @token if @token
|
62
61
|
|
63
62
|
|
64
63
|
n = Net::HTTP.new(@host,@port)
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ig3client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.6.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Kevin Pinte
|
@@ -9,7 +9,7 @@ autorequire:
|
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
11
|
|
12
|
-
date: 2009-
|
12
|
+
date: 2009-10-04 00:00:00 +02:00
|
13
13
|
default_executable:
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
@@ -32,9 +32,9 @@ extra_rdoc_files: []
|
|
32
32
|
|
33
33
|
files:
|
34
34
|
- lib/ig3client.rb
|
35
|
+
- lib/ig3client/marshal_client.rb
|
35
36
|
- lib/ig3client/yaml_client.rb
|
36
37
|
- lib/ig3client/generic_client.rb
|
37
|
-
- lib/ig3client/marshal_client.rb
|
38
38
|
- lib/lib/util.rb
|
39
39
|
- lib/lib/errors.rb
|
40
40
|
has_rdoc: false
|
@@ -61,7 +61,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
61
61
|
requirements: []
|
62
62
|
|
63
63
|
rubyforge_project: ig3tool
|
64
|
-
rubygems_version: 1.
|
64
|
+
rubygems_version: 1.2.0
|
65
65
|
signing_key:
|
66
66
|
specification_version: 2
|
67
67
|
summary: base client library of ig3tool
|