swaggerless 0.1.5 → 0.1.6

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: d8548560a65b15f31c57f4529df4e0b98f6aceec
4
- data.tar.gz: feb6bdc1b1bf5d0708c94451acc3c40ff0203e7e
3
+ metadata.gz: 1512b9d9d029261974bcaf339643955248d045ac
4
+ data.tar.gz: 5fbfa3e56463e5f30c4fa2ff56e247b2069b44f2
5
5
  SHA512:
6
- metadata.gz: 9ff5e011f8f121b9080bb17b1d3f2c8a5053ba94876da350e38d6cec3d40eeb0f2ce204f7b21ea51a93553728999cc0da963650a44b71f9381a76721469a42ba
7
- data.tar.gz: 77017ee7f6560138928f12e6e972f0e524c4a81cd7d72d07dac851b2001c366eae303c0475093994ec8d8664edfb8feeeb13d0db4950e12882f5d9273d6931ca
6
+ metadata.gz: bc62dd7eaa7fdc62ea7daacf11f2187364a5ba5a4b8c56ed0ad3f5459857c904f65e614f166a8c25ecafeee3bdf314154fa0552ccc6f492df8647cc24f057049
7
+ data.tar.gz: b19139e3cfa3e88e79e77aae15c59cf53eb0cccfb8da9d026a7371b3dc64a40563d1ca163a1967ff59c53412f5c4e437b3de87de9a4b7466fc03eb3900a5509a
@@ -116,6 +116,10 @@ module Swaggerless
116
116
  apis = @api_gateway_client.get_rest_apis(limit: 500).data
117
117
  api = apis.items.select { |a| a.name == swagger['info']['title'] }.first
118
118
 
119
+ if swagger['basePath']
120
+ swagger['paths'] = Hash[swagger['paths'].map {|k, v| [ swagger['basePath'] + k, v ] }]
121
+ end
122
+
119
123
  if api
120
124
  resp = @api_gateway_client.put_rest_api({rest_api_id: api.id, mode: "overwrite", fail_on_warnings: true, body: swagger.to_yaml})
121
125
  else
@@ -1,3 +1,3 @@
1
1
  module Swaggerless
2
- VERSION = "0.1.5"
2
+ VERSION = "0.1.6"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: swaggerless
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.5
4
+ version: 0.1.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Rafal Nowosielski