okapi 0.1.1 → 1.0.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 0b4ad705452ab3ced9e0ec9743e56c6fa24f1117
4
+ data.tar.gz: 345239939ca579b2497d394682dae3f8d53932dc
5
+ SHA512:
6
+ metadata.gz: a19a00888830698ff87639178e45620b5af594299e0af9d86470de3ca095954e004e93b3f4591038d62757d89b2e0718ebb73318129d93c1632a22e80493cfe9
7
+ data.tar.gz: 4a3f1df365e80aa17386e763d205584dc39cbd553a5c12df639658e6cba7e90c35f2a0dee3f30e7b2e17451aaf3f192505864f56ec5937f940d034eb501311c9
data/.gitignore CHANGED
@@ -1,6 +1,15 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /Gemfile.lock
4
+ /_yardoc/
5
+ /coverage/
6
+ /doc/
7
+ /pkg/
8
+ /spec/reports/
9
+ /tmp/
10
+ /spec/sandbox/**/*
1
11
 
2
- *.DS_Store
3
- *.gem
4
- /.idea
5
- /nbproject/
6
-
12
+ # rspec failure tracking
13
+ .rspec_status
14
+ /.ruby-version
15
+ /spec/sandbox
data/.rspec ADDED
@@ -0,0 +1,2 @@
1
+ --format documentation
2
+ --color
data/.travis.yml ADDED
@@ -0,0 +1,5 @@
1
+ sudo: false
2
+ language: ruby
3
+ rvm:
4
+ - 2.3.3
5
+ before_install: gem install bundler -v 1.15.4
data/Gemfile CHANGED
@@ -1,2 +1,6 @@
1
- source 'https://rubygems.org'
1
+ source "https://rubygems.org"
2
+
3
+ git_source(:github) {|repo_name| "https://github.com/#{repo_name}" }
4
+
5
+ # Specify your gem's dependencies in okapi.gemspec
2
6
  gemspec
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2017 Charles Lowell
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in
13
+ all copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
21
+ THE SOFTWARE.
data/README.md CHANGED
@@ -1,3 +1,41 @@
1
- # OKApi
1
+ # Okapi
2
2
 
3
- OKApi has been merged into Apiary.io CLI [https://github.com/apiaryio/apiary-client]
3
+ [![Build Status](https://travis-ci.org/thefrontside/okapi.rb.svg?branch=master)](https://travis-ci.org/thefrontside/okapi.rb)
4
+
5
+ ``` ruby
6
+
7
+ okapi = Okapi::Client.new('https://okapi.frontside.io')
8
+ puts okapi.modules.first #=> { "id": "folio-mod-configuration", "name": "Configuration" }
9
+ ```
10
+
11
+
12
+ ## Installation
13
+
14
+ Add this line to your application's Gemfile:
15
+
16
+ ```ruby
17
+ gem 'okapi'
18
+ ```
19
+
20
+ And then execute:
21
+
22
+ $ bundle
23
+
24
+ Or install it yourself as:
25
+
26
+ $ gem install okapi
27
+
28
+
29
+ ## Development
30
+
31
+ After checking out the repo, run `bin/setup` to install dependencies. Then, run `bin/rspec spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
32
+
33
+ To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version, push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
34
+
35
+ ## Contributing
36
+
37
+ Bug reports and pull requests are welcome on GitHub at https://github.com/thefrontside/okapi.rb
38
+
39
+ ## License
40
+
41
+ The gem is available as open source under the terms of the [MIT License](http://opensource.org/licenses/MIT).
data/Rakefile ADDED
@@ -0,0 +1,6 @@
1
+ require "bundler/gem_tasks"
2
+ require "rspec/core/rake_task"
3
+
4
+ RSpec::Core::RakeTask.new(:spec)
5
+
6
+ task :default => :spec
data/bin/console ADDED
@@ -0,0 +1,14 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require "bundler/setup"
4
+ require "okapi"
5
+
6
+ # You can add fixtures and/or initialization code here to make experimenting
7
+ # with your gem easier. You can also use a different console, if you like.
8
+
9
+ # (If you use this, don't forget to add pry to your Gemfile!)
10
+ # require "pry"
11
+ # Pry.start
12
+
13
+ require "irb"
14
+ IRB.start(__FILE__)
data/bin/okapi ADDED
@@ -0,0 +1,5 @@
1
+ #!/usr/bin/env ruby
2
+ require 'bundler/setup'
3
+ require 'okapi/cli'
4
+
5
+ puts Okapi::CLI.run
data/bin/setup ADDED
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+ set -vx
5
+
6
+ bundle install
7
+
8
+ # Do any other automated setup that you need to do here
@@ -0,0 +1,88 @@
1
+ module Okapi
2
+ class ImplicitConfig
3
+ def write!(&block)
4
+ File.open(filename, "w", &block)
5
+ end
6
+
7
+ def read!(*_)
8
+ File.exists?(filename) ? File.read(filename) : ""
9
+ end
10
+
11
+ def filename
12
+ File.join(Dir.home, ".okapi")
13
+ end
14
+
15
+ def inspect
16
+ filename
17
+ end
18
+ end
19
+
20
+ class ExplicitConfig
21
+ attr_reader :filename
22
+
23
+ def initialize(filename)
24
+ @filename = filename
25
+ end
26
+ def write!(&block)
27
+ File.open(@filename, "w", &block)
28
+ end
29
+
30
+ def read!(force: false)
31
+ checkfile!(force) do |exists|
32
+ exists ? File.read(@filename) : ""
33
+ end
34
+ end
35
+
36
+ def checkfile!(force)
37
+ if !File.exists?(@filename)
38
+ if force
39
+ yield false
40
+ else
41
+ raise Okapi::ConfigurationError, "Unable to find configuration file '#{@filename}`"
42
+ end
43
+ else
44
+ yield true
45
+ end
46
+ end
47
+ end
48
+
49
+ class PersistentVariables
50
+ def initialize(config)
51
+ @config = config
52
+ @variables = {}
53
+ end
54
+
55
+ def filename
56
+ @config.filename
57
+ end
58
+
59
+ def read!(force: false)
60
+ lines = @config.read!(force: force).split(/\n+/).map(&:strip).reject(&:empty?)
61
+ @variables = lines.map { |l| l.split("=") }.to_h
62
+ end
63
+
64
+ def write!
65
+ @config.write! do |file|
66
+ file.write(@variables.entries.map { |entry| "#{entry.first}=#{entry.last}"}.join("\n"))
67
+ file.write("\n")
68
+ end
69
+ end
70
+
71
+ def load!
72
+ read!
73
+ @variables.each_pair do |k,v|
74
+ ENV[k] = v
75
+ end
76
+ end
77
+
78
+ def merge(lines)
79
+ @variables = @variables.merge lines.map { |l| l.split("=") }.to_h
80
+ end
81
+
82
+ def delete_all!(list)
83
+ original = @variables
84
+ @variables = @variables.reject { |k| list.include? k }
85
+ original.length - @variables.length
86
+ end
87
+ end
88
+ end
data/lib/okapi/cli.rb ADDED
@@ -0,0 +1,141 @@
1
+ require "okapi"
2
+ require "okapi/cli/config"
3
+ require "clamp"
4
+ require "highline"
5
+
6
+ module Okapi
7
+ class CLI < Clamp::Command
8
+ option "--config", "CONFIG_FILE", "use persistent configuration from this file", default: ImplicitConfig.new do |config|
9
+ ExplicitConfig.new(config)
10
+ end
11
+ option "--url", "URL", "use okapi cluster at URL"
12
+ option "--tenant", "TENANT", "connect using this tenant"
13
+ option "--token", "TOKEN", "authenticate requests with TOKEN"
14
+ option "--no-tenant", :flag, "perform the request without a tenant or user token"
15
+ option "--no-user", :flag, "perform the request without the user token"
16
+
17
+ subcommand "config", "show all configured variables" do
18
+ def model
19
+ variables.read!
20
+ end
21
+ end
22
+
23
+ subcommand "config:set", "set the CLI configuration variable {OKAPI_URL, OKAPI_TENANT, OKAPI_TOKEN}" do
24
+ parameter "ENV_VARS ...", "persist all ENV_VAR values for future use"
25
+
26
+ def model
27
+ variables.read! force: true
28
+ variables.merge env_vars_list
29
+ variables.write!
30
+ "configuration written to #{variables.filename}"
31
+ end
32
+ end
33
+
34
+ subcommand "config:delete", "delete configuration variables" do
35
+ parameter "VARS ...", "delete configuration variables"
36
+
37
+ def model
38
+ variables.read! force: true
39
+ deletions = variables.delete_all! vars_list
40
+ variables.write!
41
+ "deleted #{deletions} variables from #{variables.filename}"
42
+ end
43
+ end
44
+
45
+ subcommand "login", "authenticate to okapi and store credentials" do
46
+ def model
47
+ username = console.ask("username: ")
48
+ password = console.ask("password: ") { |q| q.echo = "*" }
49
+ client.tenant.post("/authn/login", username: username, password: password) do |json, response|
50
+ token = response['x-okapi-token']
51
+ variables.read! force: true
52
+ variables.merge ["OKAPI_TOKEN=#{token}"]
53
+ variables.write!
54
+ "Login successful. Token saved to #{variables.filename}"
55
+ end
56
+ end
57
+ end
58
+
59
+ subcommand "logout", "destroy existing credentials" do
60
+ def execute
61
+ variables.read!
62
+ deletions = variables.delete_all! ["OKAPI_TOKEN"]
63
+ if deletions > 0
64
+ variables.write!
65
+ "Logged out. Updated #{variables.filename}"
66
+ else
67
+ "Configuration at #{variables.filename} is not currently logged in. Doing nothing."
68
+ end
69
+ end
70
+ end
71
+
72
+ subcommand "show", "issue a GET request to the spcified PATH" do
73
+ parameter "PATH", "PATH of the resource to get"
74
+
75
+ def model
76
+ client.get path
77
+ end
78
+ end
79
+
80
+ subcommand "create", "POST the contents of STDIN to PATH" do
81
+ parameter "PATH", "PATH of the resource collection in which the create will happen"
82
+
83
+ def model
84
+ client.post path, JSON.parse($stdin.read)
85
+ end
86
+ end
87
+
88
+ subcommand "destroy", "issue a DELETE request to the specified PATH" do
89
+ parameter "PATH", "PATH of the resource to delete"
90
+
91
+ def model
92
+ client.delete path
93
+ "Successfully deleted #{path}"
94
+ end
95
+ end
96
+
97
+ subcommand "modules:index", "show a listing of all installed modules" do
98
+ def model
99
+ client.modules
100
+ end
101
+ end
102
+
103
+ def client
104
+ variables.load!
105
+ anonymous = Okapi::Client.new(url, tenant, token)
106
+
107
+ if no_tenant?
108
+ anonymous
109
+ elsif no_user?
110
+ anonymous.tenant
111
+ else
112
+ anonymous.user
113
+ end
114
+ end
115
+
116
+ def execute
117
+ result = model
118
+ if result.is_a?(String)
119
+ result
120
+ else
121
+ JSON.pretty_generate result
122
+ end
123
+ end
124
+
125
+ def variables
126
+ @variables ||= PersistentVariables.new(config)
127
+ end
128
+
129
+ def console
130
+ HighLine.new
131
+ end
132
+
133
+ def self.run(*args, &block)
134
+ super(*args, &block)
135
+ rescue Okapi::ConfigurationError => e
136
+ e.message
137
+ rescue Okapi::RequestError => e
138
+ e.message
139
+ end
140
+ end
141
+ end
@@ -0,0 +1,53 @@
1
+ module Okapi
2
+ class Settings
3
+ def initialize(url, tenant, token)
4
+ @url = url
5
+ @tenant = tenant
6
+ @token = token
7
+ end
8
+ def url
9
+ get_var!(:url, <<~EOM) do |url|
10
+ this operation requires the url of your Okapi gateway, but it couldn't be found.
11
+
12
+ You can fix this by setting either the `OKAPI_URL` environment variable, or
13
+ using the `--url` option if you're using the command line.
14
+ EOM
15
+ URI(url)
16
+ end
17
+ end
18
+
19
+ def tenant
20
+ get_var!(:tenant, <<~EOM)
21
+ this operation requires a tenant id, but it couldn't be found.
22
+
23
+ You can fix this by setting either the `OKAPI_TENANT` environment variable, or
24
+ using the `--tenant` option if you're using the command line.
25
+ EOM
26
+ end
27
+
28
+ def token
29
+ get_var!(:token, <<~EOM)
30
+ this operation requires you to be logged in, and already authenticated with
31
+ your Okapi cluster.
32
+
33
+ You can fix this by obtaining an authenication token, and then using it by
34
+ either setting the `OKAPI_TOKEN` environment variable or using the
35
+ `--token` option from the command line.
36
+ EOM
37
+ end
38
+
39
+ def get_var!(symbol, error_msg)
40
+ env_var_name = "OKAPI_#{symbol.to_s.upcase}"
41
+ env_value = ENV[env_var_name]
42
+ instance_value = instance_variable_get("@#{symbol}")
43
+ if instance_value && !instance_value.strip.empty?
44
+ block_given? ? yield(instance_value) : instance_value
45
+ elsif !env_value.nil? && !env_value.strip.empty?
46
+ block_given? ? yield(env_value) : env_value
47
+ else
48
+ raise ConfigurationError, error_msg
49
+ end
50
+ end
51
+ end
52
+
53
+ end
@@ -0,0 +1,3 @@
1
+ module Okapi
2
+ VERSION = "1.0.0"
3
+ end
data/lib/okapi.rb ADDED
@@ -0,0 +1,119 @@
1
+ require "okapi/version"
2
+ require "okapi/settings"
3
+ require 'net/https'
4
+ require 'open-uri'
5
+ require 'json'
6
+
7
+ module Okapi
8
+ class ConfigurationError < StandardError; end
9
+
10
+ class Client
11
+ def initialize(url = nil, tenant = nil, token = nil)
12
+ @url, @tenant, @token = url, tenant, token
13
+ end
14
+
15
+ def settings
16
+ Settings.new(@url, @tenant, @token)
17
+ end
18
+
19
+ def modules
20
+ endpoint = "#{settings.url}/_/proxy/modules"
21
+ open(endpoint) do |response|
22
+ JSON.parse(response.read)
23
+ end
24
+ end
25
+
26
+ def has_interface?(interface_name)
27
+ get("/_/proxy/tenants/#{settings.tenant}/interfaces/#{interface_name}") do |json|
28
+ json.length > 0
29
+ end
30
+ end
31
+
32
+ def url
33
+ settings.url
34
+ end
35
+
36
+ def get(path)
37
+ request(:get, path) do |response|
38
+ json = JSON.parse(response.body)
39
+ if block_given?
40
+ yield json, response
41
+ else
42
+ json
43
+ end
44
+ end
45
+ end
46
+
47
+ def post(path, body)
48
+ request(:post, path, JSON.generate(body)) do |response|
49
+ json = JSON.parse(response.body)
50
+ if block_given?
51
+ yield json, response
52
+ else
53
+ json
54
+ end
55
+ end
56
+ end
57
+
58
+ def delete(path)
59
+ request(:delete, path, nil, 'Accept' => 'text/plain')
60
+ end
61
+
62
+ def request(verb, path, body = nil, header_overrides = {})
63
+ http = Net::HTTP.new(url.host, url.port)
64
+ if url.scheme == "https"
65
+ http.use_ssl = true
66
+ end
67
+ http.start do
68
+ args = [body].compact
69
+ response = http.send(verb, path, *args, headers.merge(header_overrides))
70
+ RequestError.maybe_fail! response
71
+ if block_given?
72
+ yield response
73
+ else
74
+ response
75
+ end
76
+ end
77
+ end
78
+
79
+ def headers
80
+ {'Content-Type' => 'application/json', 'Accept' => 'application/json'}
81
+ end
82
+
83
+ def tenant
84
+ Tenant.new(@url, @tenant, @token)
85
+ end
86
+
87
+ def user
88
+ User.new(@url, @tenant, @token)
89
+ end
90
+
91
+ class Tenant < self
92
+ def headers
93
+ super.merge "X-Okapi-Tenant" => settings.tenant
94
+ end
95
+ end
96
+
97
+ class User < Tenant
98
+ def headers
99
+ super.merge "X-Okapi-Token" => settings.token
100
+ end
101
+ end
102
+
103
+ end
104
+
105
+ class RequestError < StandardError
106
+ attr_reader :response
107
+
108
+ def initialize(response)
109
+ super("#{response.class.to_s}: #{response.body}")
110
+ end
111
+
112
+ def self.maybe_fail!(response)
113
+ fail new(response) unless response.code.to_i >= 200 && response.code.to_i < 300
114
+ end
115
+ end
116
+
117
+ end
118
+
119
+ # okapi configuration:get
data/okapi.gemspec CHANGED
@@ -1,18 +1,33 @@
1
1
  # coding: utf-8
2
-
2
+ lib = File.expand_path("../lib", __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require "okapi/version"
3
5
 
4
6
  Gem::Specification.new do |spec|
5
7
  spec.name = "okapi"
6
- spec.version = "0.1.1"
7
- spec.authors = ["Tu1ly"]
8
- spec.email = ["tully@apiary.io"]
9
- spec.description = %q{OKApi has been merged into Apiary.io CLI [https://rubygems.org/gems/apiaryio]}
10
- spec.summary = %q{OKApi has been merged into Apiary.io CLI [https://rubygems.org/gems/apiaryio]}
11
- spec.homepage = "http://apiary.io"
12
- spec.license = "MIT"
8
+ spec.version = Okapi::VERSION
9
+ spec.authors = ["Charles Lowell"]
10
+ spec.email = ["cowboyd@frontside.io"]
11
+
12
+ spec.summary = %q{Ruby utilities for interacting with an okapi cluster}
13
+ spec.description = %q{Interaact with an OKAPI gateway from ruby}
14
+ spec.homepage = "https://github.com/thefrontside/okapi.rb"
15
+ spec.license = "Apache 2.0"
16
+
17
+ spec.files = `git ls-files -z`.split("\x0").reject do |f|
18
+ f.match(%r{^(test|spec|features)/})
19
+ end
20
+ spec.bindir = "exe"
21
+ spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
22
+ spec.require_paths = ["lib"]
13
23
 
14
- spec.files = `git ls-files`.split($/)
24
+ spec.add_dependency "clamp", "~> 1.1"
25
+ spec.add_dependency "highline", "~> 1.7"
15
26
 
16
- spec.add_dependency "json"
17
- spec.add_dependency "rest-client"
27
+ spec.add_development_dependency "bundler", "~> 1.15"
28
+ spec.add_development_dependency "rake", "~> 10.0"
29
+ spec.add_development_dependency "rspec", "~> 3.0"
30
+ spec.add_development_dependency "vcr", "~> 3.0"
31
+ spec.add_development_dependency "webmock", "~> 3.0"
32
+ spec.add_development_dependency "pry-byebug", "~> 3.5"
18
33
  end
metadata CHANGED
@@ -1,98 +1,172 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: okapi
3
- version: !ruby/object:Gem::Version
4
- hash: 25
5
- prerelease: false
6
- segments:
7
- - 0
8
- - 1
9
- - 1
10
- version: 0.1.1
3
+ version: !ruby/object:Gem::Version
4
+ version: 1.0.0
11
5
  platform: ruby
12
- authors:
13
- - Tu1ly
6
+ authors:
7
+ - Charles Lowell
14
8
  autorequire:
15
- bindir: bin
9
+ bindir: exe
16
10
  cert_chain: []
17
-
18
- date: 2013-05-09 00:00:00 +02:00
19
- default_executable:
20
- dependencies:
21
- - !ruby/object:Gem::Dependency
22
- name: json
23
- prerelease: false
24
- requirement: &id001 !ruby/object:Gem::Requirement
25
- none: false
26
- requirements:
27
- - - ">="
28
- - !ruby/object:Gem::Version
29
- hash: 3
30
- segments:
31
- - 0
32
- version: "0"
11
+ date: 2017-10-27 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: clamp
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - "~>"
18
+ - !ruby/object:Gem::Version
19
+ version: '1.1'
33
20
  type: :runtime
34
- version_requirements: *id001
35
- - !ruby/object:Gem::Dependency
36
- name: rest-client
37
21
  prerelease: false
38
- requirement: &id002 !ruby/object:Gem::Requirement
39
- none: false
40
- requirements:
41
- - - ">="
42
- - !ruby/object:Gem::Version
43
- hash: 3
44
- segments:
45
- - 0
46
- version: "0"
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - "~>"
25
+ - !ruby/object:Gem::Version
26
+ version: '1.1'
27
+ - !ruby/object:Gem::Dependency
28
+ name: highline
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - "~>"
32
+ - !ruby/object:Gem::Version
33
+ version: '1.7'
47
34
  type: :runtime
48
- version_requirements: *id002
49
- description: OKApi has been merged into Apiary.io CLI [https://rubygems.org/gems/apiaryio]
50
- email:
51
- - tully@apiary.io
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "~>"
39
+ - !ruby/object:Gem::Version
40
+ version: '1.7'
41
+ - !ruby/object:Gem::Dependency
42
+ name: bundler
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '1.15'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '1.15'
55
+ - !ruby/object:Gem::Dependency
56
+ name: rake
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - "~>"
60
+ - !ruby/object:Gem::Version
61
+ version: '10.0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - "~>"
67
+ - !ruby/object:Gem::Version
68
+ version: '10.0'
69
+ - !ruby/object:Gem::Dependency
70
+ name: rspec
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - "~>"
74
+ - !ruby/object:Gem::Version
75
+ version: '3.0'
76
+ type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - "~>"
81
+ - !ruby/object:Gem::Version
82
+ version: '3.0'
83
+ - !ruby/object:Gem::Dependency
84
+ name: vcr
85
+ requirement: !ruby/object:Gem::Requirement
86
+ requirements:
87
+ - - "~>"
88
+ - !ruby/object:Gem::Version
89
+ version: '3.0'
90
+ type: :development
91
+ prerelease: false
92
+ version_requirements: !ruby/object:Gem::Requirement
93
+ requirements:
94
+ - - "~>"
95
+ - !ruby/object:Gem::Version
96
+ version: '3.0'
97
+ - !ruby/object:Gem::Dependency
98
+ name: webmock
99
+ requirement: !ruby/object:Gem::Requirement
100
+ requirements:
101
+ - - "~>"
102
+ - !ruby/object:Gem::Version
103
+ version: '3.0'
104
+ type: :development
105
+ prerelease: false
106
+ version_requirements: !ruby/object:Gem::Requirement
107
+ requirements:
108
+ - - "~>"
109
+ - !ruby/object:Gem::Version
110
+ version: '3.0'
111
+ - !ruby/object:Gem::Dependency
112
+ name: pry-byebug
113
+ requirement: !ruby/object:Gem::Requirement
114
+ requirements:
115
+ - - "~>"
116
+ - !ruby/object:Gem::Version
117
+ version: '3.5'
118
+ type: :development
119
+ prerelease: false
120
+ version_requirements: !ruby/object:Gem::Requirement
121
+ requirements:
122
+ - - "~>"
123
+ - !ruby/object:Gem::Version
124
+ version: '3.5'
125
+ description: Interaact with an OKAPI gateway from ruby
126
+ email:
127
+ - cowboyd@frontside.io
52
128
  executables: []
53
-
54
129
  extensions: []
55
-
56
130
  extra_rdoc_files: []
57
-
58
- files:
59
- - .gitignore
131
+ files:
132
+ - ".gitignore"
133
+ - ".rspec"
134
+ - ".travis.yml"
60
135
  - Gemfile
136
+ - LICENSE.txt
61
137
  - README.md
138
+ - Rakefile
139
+ - bin/console
140
+ - bin/okapi
141
+ - bin/setup
142
+ - lib/okapi.rb
143
+ - lib/okapi/cli.rb
144
+ - lib/okapi/cli/config.rb
145
+ - lib/okapi/settings.rb
146
+ - lib/okapi/version.rb
62
147
  - okapi.gemspec
63
- has_rdoc: true
64
- homepage: http://apiary.io
65
- licenses:
66
- - MIT
148
+ homepage: https://github.com/thefrontside/okapi.rb
149
+ licenses:
150
+ - Apache 2.0
151
+ metadata: {}
67
152
  post_install_message:
68
153
  rdoc_options: []
69
-
70
- require_paths:
154
+ require_paths:
71
155
  - lib
72
- required_ruby_version: !ruby/object:Gem::Requirement
73
- none: false
74
- requirements:
156
+ required_ruby_version: !ruby/object:Gem::Requirement
157
+ requirements:
75
158
  - - ">="
76
- - !ruby/object:Gem::Version
77
- hash: 3
78
- segments:
79
- - 0
80
- version: "0"
81
- required_rubygems_version: !ruby/object:Gem::Requirement
82
- none: false
83
- requirements:
159
+ - !ruby/object:Gem::Version
160
+ version: '0'
161
+ required_rubygems_version: !ruby/object:Gem::Requirement
162
+ requirements:
84
163
  - - ">="
85
- - !ruby/object:Gem::Version
86
- hash: 3
87
- segments:
88
- - 0
89
- version: "0"
164
+ - !ruby/object:Gem::Version
165
+ version: '0'
90
166
  requirements: []
91
-
92
167
  rubyforge_project:
93
- rubygems_version: 1.3.7
168
+ rubygems_version: 2.5.2
94
169
  signing_key:
95
- specification_version: 3
96
- summary: OKApi has been merged into Apiary.io CLI [https://rubygems.org/gems/apiaryio]
170
+ specification_version: 4
171
+ summary: Ruby utilities for interacting with an okapi cluster
97
172
  test_files: []
98
-