heroics 0.0.13 → 0.0.14
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/heroics/client_generator.rb +9 -7
- data/lib/heroics/version.rb +1 -1
- data/lib/heroics/views/client.erb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: aa499bd9600ebaf398364bede676a650e59b9069
|
4
|
+
data.tar.gz: 1d3cc821c826a4de74c668357bb992e0cb65312f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4e355d82e3f72aa0f753beda66de2571a0428436a7edc3ebe7553657572361bf6e1e6b49956a97c953ef86d163f1ebcc231cf5db2935bfe5212200c09e6a5d68
|
7
|
+
data.tar.gz: 1fd82c26f754a3a4934a907cfeb03816ef6919a387bdd7df5711ef12031c8dafff03b5ba0faecb9956fd3f1dfb896f04872ed893844faa2df9bb2fdb751ff52a
|
@@ -37,13 +37,15 @@ module Heroics
|
|
37
37
|
links)
|
38
38
|
end
|
39
39
|
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
40
|
+
{
|
41
|
+
module_name: module_name,
|
42
|
+
url: url,
|
43
|
+
default_headers: options.fetch(:default_headers, {}),
|
44
|
+
cache: options.fetch(:cache, {}),
|
45
|
+
description: schema.description,
|
46
|
+
schema: MultiJson.dump(schema.schema, pretty:true),
|
47
|
+
resources: resources
|
48
|
+
}
|
47
49
|
end
|
48
50
|
|
49
51
|
# A representation of a resource for use when generating source code in the
|
data/lib/heroics/version.rb
CHANGED
@@ -21,7 +21,7 @@ module <%= @module_name %>
|
|
21
21
|
def self.connect(api_key, options=nil)
|
22
22
|
options = custom_options(options)
|
23
23
|
uri = URI.parse(options[:url])
|
24
|
-
uri.user = options.fetch(:user, 'user')
|
24
|
+
uri.user = URI.encode_www_form_component options.fetch(:user, 'user')
|
25
25
|
uri.password = api_key
|
26
26
|
client = Heroics.client_from_schema(SCHEMA, uri.to_s, options)
|
27
27
|
Client.new(client)
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: heroics
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.14
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- geemus
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2015-
|
12
|
+
date: 2015-04-16 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: bundler
|