contentful 2.15.4 → 2.16.3
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 +4 -4
- data/CHANGELOG.md +17 -0
- data/README.md +20 -11
- data/lib/contentful/array_like.rb +9 -0
- data/lib/contentful/base_resource.rb +12 -1
- data/lib/contentful/fields_resource.rb +1 -0
- data/lib/contentful/version.rb +1 -1
- metadata +3 -373
- data/.gitignore +0 -7
- data/.rspec +0 -1
- data/.rubocop.yml +0 -31
- data/.rubocop_todo.yml +0 -35
- data/.ruby-version +0 -1
- data/.travis.yml +0 -15
- data/.yardopts +0 -4
- data/Gemfile +0 -9
- data/Gemfile.lock +0 -170
- data/Guardfile +0 -24
- data/RELEASE.md +0 -8
- data/Rakefile +0 -33
- data/contentful.gemspec +0 -44
- data/contentful.rb.sublime-project +0 -9
- data/contentful.rb.sublime-workspace +0 -2154
- data/coverage/.last_run.json +0 -5
- data/coverage/.resultset.json +0 -2421
- data/coverage/.resultset.json.lock +0 -0
- data/coverage/assets/0.12.2/DataTables-1.10.20/images/sort_asc.png +0 -0
- data/coverage/assets/0.12.2/DataTables-1.10.20/images/sort_asc_disabled.png +0 -0
- data/coverage/assets/0.12.2/DataTables-1.10.20/images/sort_both.png +0 -0
- data/coverage/assets/0.12.2/DataTables-1.10.20/images/sort_desc.png +0 -0
- data/coverage/assets/0.12.2/DataTables-1.10.20/images/sort_desc_disabled.png +0 -0
- data/coverage/assets/0.12.2/application.css +0 -1
- data/coverage/assets/0.12.2/application.js +0 -7
- data/coverage/assets/0.12.2/colorbox/border.png +0 -0
- data/coverage/assets/0.12.2/colorbox/controls.png +0 -0
- data/coverage/assets/0.12.2/colorbox/loading.gif +0 -0
- data/coverage/assets/0.12.2/colorbox/loading_background.png +0 -0
- data/coverage/assets/0.12.2/favicon_green.png +0 -0
- data/coverage/assets/0.12.2/favicon_red.png +0 -0
- data/coverage/assets/0.12.2/favicon_yellow.png +0 -0
- data/coverage/assets/0.12.2/images/ui-bg_flat_0_aaaaaa_40x100.png +0 -0
- data/coverage/assets/0.12.2/images/ui-bg_flat_75_ffffff_40x100.png +0 -0
- data/coverage/assets/0.12.2/images/ui-bg_glass_55_fbf9ee_1x400.png +0 -0
- data/coverage/assets/0.12.2/images/ui-bg_glass_65_ffffff_1x400.png +0 -0
- data/coverage/assets/0.12.2/images/ui-bg_glass_75_dadada_1x400.png +0 -0
- data/coverage/assets/0.12.2/images/ui-bg_glass_75_e6e6e6_1x400.png +0 -0
- data/coverage/assets/0.12.2/images/ui-bg_glass_95_fef1ec_1x400.png +0 -0
- data/coverage/assets/0.12.2/images/ui-bg_highlight-soft_75_cccccc_1x100.png +0 -0
- data/coverage/assets/0.12.2/images/ui-icons_222222_256x240.png +0 -0
- data/coverage/assets/0.12.2/images/ui-icons_2e83ff_256x240.png +0 -0
- data/coverage/assets/0.12.2/images/ui-icons_454545_256x240.png +0 -0
- data/coverage/assets/0.12.2/images/ui-icons_888888_256x240.png +0 -0
- data/coverage/assets/0.12.2/images/ui-icons_cd0a0a_256x240.png +0 -0
- data/coverage/assets/0.12.2/loading.gif +0 -0
- data/coverage/assets/0.12.2/magnify.png +0 -0
- data/coverage/index.html +0 -26587
- data/doc/Contentful/AccessDenied.html +0 -159
- data/doc/Contentful/Array.html +0 -844
- data/doc/Contentful/ArrayCoercion.html +0 -242
- data/doc/Contentful/ArrayLike.html +0 -624
- data/doc/Contentful/Asset.html +0 -486
- data/doc/Contentful/BadGateway.html +0 -159
- data/doc/Contentful/BadRequest.html +0 -159
- data/doc/Contentful/BaseCoercion.html +0 -445
- data/doc/Contentful/BaseResource.html +0 -598
- data/doc/Contentful/BooleanCoercion.html +0 -242
- data/doc/Contentful/Client.html +0 -1738
- data/doc/Contentful/ContentType.html +0 -617
- data/doc/Contentful/ContentTypeCache.html +0 -428
- data/doc/Contentful/DateCoercion.html +0 -244
- data/doc/Contentful/DeletedAsset.html +0 -156
- data/doc/Contentful/DeletedEntry.html +0 -156
- data/doc/Contentful/EmptyFieldError.html +0 -217
- data/doc/Contentful/Entry.html +0 -334
- data/doc/Contentful/Error.html +0 -407
- data/doc/Contentful/Field.html +0 -935
- data/doc/Contentful/FieldsResource.html +0 -583
- data/doc/Contentful/File.html +0 -218
- data/doc/Contentful/FloatCoercion.html +0 -238
- data/doc/Contentful/IntegerCoercion.html +0 -238
- data/doc/Contentful/Link.html +0 -246
- data/doc/Contentful/LinkCoercion.html +0 -156
- data/doc/Contentful/Locale.html +0 -536
- data/doc/Contentful/Location.html +0 -382
- data/doc/Contentful/LocationCoercion.html +0 -238
- data/doc/Contentful/NotFound.html +0 -159
- data/doc/Contentful/ObjectCoercion.html +0 -238
- data/doc/Contentful/RateLimitExceeded.html +0 -346
- data/doc/Contentful/Request.html +0 -895
- data/doc/Contentful/ResourceBuilder.html +0 -1067
- data/doc/Contentful/ResourceReferences.html +0 -254
- data/doc/Contentful/Response.html +0 -708
- data/doc/Contentful/RichTextCoercion.html +0 -238
- data/doc/Contentful/ServerError.html +0 -159
- data/doc/Contentful/ServiceUnavailable.html +0 -159
- data/doc/Contentful/Space.html +0 -392
- data/doc/Contentful/StringCoercion.html +0 -242
- data/doc/Contentful/Support.html +0 -788
- data/doc/Contentful/SymbolCoercion.html +0 -169
- data/doc/Contentful/Sync.html +0 -653
- data/doc/Contentful/SyncPage.html +0 -807
- data/doc/Contentful/TextCoercion.html +0 -169
- data/doc/Contentful/Unauthorized.html +0 -159
- data/doc/Contentful/UnparsableJson.html +0 -159
- data/doc/Contentful/UnparsableResource.html +0 -135
- data/doc/Contentful.html +0 -157
- data/doc/_index.html +0 -563
- data/doc/class_list.html +0 -51
- data/doc/css/common.css +0 -1
- data/doc/css/full_list.css +0 -58
- data/doc/css/style.css +0 -496
- data/doc/file.CHANGELOG.html +0 -715
- data/doc/file.LICENSE.html +0 -70
- data/doc/file.README.html +0 -758
- data/doc/file_list.html +0 -66
- data/doc/frames.html +0 -17
- data/doc/index.html +0 -758
- data/doc/js/app.js +0 -314
- data/doc/js/full_list.js +0 -216
- data/doc/js/jquery.js +0 -4
- data/doc/method_list.html +0 -1187
- data/doc/top-level-namespace.html +0 -110
- data/examples/custom_classes.rb +0 -39
- data/examples/example_queries.rb +0 -26
- data/examples/raise_errors.rb +0 -20
- data/examples/raw_mode.rb +0 -14
- data/spec/array_spec.rb +0 -177
- data/spec/asset_spec.rb +0 -192
- data/spec/auto_includes_spec.rb +0 -12
- data/spec/client_class_spec.rb +0 -86
- data/spec/client_configuration_spec.rb +0 -394
- data/spec/content_type_spec.rb +0 -49
- data/spec/deleted_asset_spec.rb +0 -38
- data/spec/deleted_entry_spec.rb +0 -38
- data/spec/entry_spec.rb +0 -787
- data/spec/error_class_spec.rb +0 -327
- data/spec/error_requests_spec.rb +0 -87
- data/spec/field_spec.rb +0 -95
- data/spec/file_spec.rb +0 -33
- data/spec/fixtures/json_responses/400_details_errors_object.json +0 -14
- data/spec/fixtures/json_responses/400_details_errors_string.json +0 -12
- data/spec/fixtures/json_responses/400_details_string.json +0 -8
- data/spec/fixtures/json_responses/403_reasons.json +0 -13
- data/spec/fixtures/json_responses/404_details_string.json +0 -8
- data/spec/fixtures/json_responses/404_id.json +0 -11
- data/spec/fixtures/json_responses/404_sys_type.json +0 -12
- data/spec/fixtures/json_responses/404_type.json +0 -10
- data/spec/fixtures/json_responses/content_type.json +0 -83
- data/spec/fixtures/json_responses/default_400.json +0 -7
- data/spec/fixtures/json_responses/default_401.json +0 -7
- data/spec/fixtures/json_responses/default_403.json +0 -7
- data/spec/fixtures/json_responses/default_404.json +0 -7
- data/spec/fixtures/json_responses/default_429.json +0 -7
- data/spec/fixtures/json_responses/default_500.json +0 -7
- data/spec/fixtures/json_responses/default_502.json +0 -7
- data/spec/fixtures/json_responses/default_503.json +0 -7
- data/spec/fixtures/json_responses/includes.json +0 -111
- data/spec/fixtures/json_responses/link_array.json +0 -43
- data/spec/fixtures/json_responses/not_found.json +0 -13
- data/spec/fixtures/json_responses/nyancat.json +0 -48
- data/spec/fixtures/json_responses/other_error.json +0 -9
- data/spec/fixtures/json_responses/other_error_no_details.json +0 -8
- data/spec/fixtures/json_responses/other_error_no_message.json +0 -8
- data/spec/fixtures/json_responses/other_error_no_request_id.json +0 -8
- data/spec/fixtures/json_responses/other_error_nothing.json +0 -6
- data/spec/fixtures/json_responses/self_link.json +0 -82
- data/spec/fixtures/json_responses/unparsable.json +0 -13
- data/spec/fixtures/vcr_cassettes/array/marshal_custom_classes.yml +0 -159
- data/spec/fixtures/vcr_cassettes/array/marshal_unpublished.yml +0 -315
- data/spec/fixtures/vcr_cassettes/array/nested_resources.yml +0 -159
- data/spec/fixtures/vcr_cassettes/array.yml +0 -288
- data/spec/fixtures/vcr_cassettes/arrayField.yml +0 -87
- data/spec/fixtures/vcr_cassettes/array_page_1.yml +0 -106
- data/spec/fixtures/vcr_cassettes/array_page_2.yml +0 -73
- data/spec/fixtures/vcr_cassettes/asset/select_empty_array.yml +0 -104
- data/spec/fixtures/vcr_cassettes/asset/select_no_sys.yml +0 -119
- data/spec/fixtures/vcr_cassettes/asset/select_one_field.yml +0 -97
- data/spec/fixtures/vcr_cassettes/asset/select_only_sys.yml +0 -88
- data/spec/fixtures/vcr_cassettes/asset.yml +0 -96
- data/spec/fixtures/vcr_cassettes/assets/issues_129.yml +0 -90
- data/spec/fixtures/vcr_cassettes/assets/issues_jekyll_46.yml +0 -115
- data/spec/fixtures/vcr_cassettes/bad_request.yml +0 -76
- data/spec/fixtures/vcr_cassettes/content_type.yml +0 -147
- data/spec/fixtures/vcr_cassettes/entries/empty_fields.yml +0 -246
- data/spec/fixtures/vcr_cassettes/entries/issue_117.yml +0 -201
- data/spec/fixtures/vcr_cassettes/entries/issue_125.yml +0 -198
- data/spec/fixtures/vcr_cassettes/entries/rich_text.yml +0 -1707
- data/spec/fixtures/vcr_cassettes/entries/rich_text_hydration_issue.yml +0 -460
- data/spec/fixtures/vcr_cassettes/entries/rich_text_nested_fields.yml +0 -653
- data/spec/fixtures/vcr_cassettes/entries/rich_text_unresolved_relationships.yml +0 -983
- data/spec/fixtures/vcr_cassettes/entries/unresolvable_assets.yml +0 -89
- data/spec/fixtures/vcr_cassettes/entries/unresolvable_filter.yml +0 -159
- data/spec/fixtures/vcr_cassettes/entries/unresolvable_filter_deeply_nested.yml +0 -167
- data/spec/fixtures/vcr_cassettes/entries.yml +0 -561
- data/spec/fixtures/vcr_cassettes/entry/custom_resource.yml +0 -168
- data/spec/fixtures/vcr_cassettes/entry/include_resolution.yml +0 -101
- data/spec/fixtures/vcr_cassettes/entry/include_resolution_uniques.yml +0 -81
- data/spec/fixtures/vcr_cassettes/entry/json_objects.yml +0 -88
- data/spec/fixtures/vcr_cassettes/entry/json_objects_client.yml +0 -86
- data/spec/fixtures/vcr_cassettes/entry/marshal_138.yml +0 -159
- data/spec/fixtures/vcr_cassettes/entry/marshal_unpublished.yml +0 -303
- data/spec/fixtures/vcr_cassettes/entry/marshall.yml +0 -293
- data/spec/fixtures/vcr_cassettes/entry/raw.yml +0 -201
- data/spec/fixtures/vcr_cassettes/entry/search_link_to_asset.yml +0 -81
- data/spec/fixtures/vcr_cassettes/entry/search_link_to_entry.yml +0 -81
- data/spec/fixtures/vcr_cassettes/entry/search_link_to_entry_with_custom_query.yml +0 -115
- data/spec/fixtures/vcr_cassettes/entry/select_empty_array.yml +0 -111
- data/spec/fixtures/vcr_cassettes/entry/select_no_sys.yml +0 -102
- data/spec/fixtures/vcr_cassettes/entry/select_one_field.yml +0 -76
- data/spec/fixtures/vcr_cassettes/entry/select_one_field_proper.yml +0 -114
- data/spec/fixtures/vcr_cassettes/entry/select_only_sys.yml +0 -111
- data/spec/fixtures/vcr_cassettes/entry.yml +0 -102
- data/spec/fixtures/vcr_cassettes/entry_cache.yml +0 -288
- data/spec/fixtures/vcr_cassettes/entry_locales.yml +0 -104
- data/spec/fixtures/vcr_cassettes/field.yml +0 -147
- data/spec/fixtures/vcr_cassettes/human.yml +0 -118
- data/spec/fixtures/vcr_cassettes/linkField.yml +0 -83
- data/spec/fixtures/vcr_cassettes/locale.yml +0 -83
- data/spec/fixtures/vcr_cassettes/locale_from_environment.yml +0 -121
- data/spec/fixtures/vcr_cassettes/location.yml +0 -193
- data/spec/fixtures/vcr_cassettes/multi_locale_array_reference.yml +0 -196
- data/spec/fixtures/vcr_cassettes/multi_locale_reference.yml +0 -214
- data/spec/fixtures/vcr_cassettes/not_found.yml +0 -76
- data/spec/fixtures/vcr_cassettes/nyancat.yml +0 -102
- data/spec/fixtures/vcr_cassettes/query_array_1.yml +0 -89
- data/spec/fixtures/vcr_cassettes/query_array_2.yml +0 -89
- data/spec/fixtures/vcr_cassettes/ratelimit.yml +0 -64
- data/spec/fixtures/vcr_cassettes/ratelimit_retry.yml +0 -294
- data/spec/fixtures/vcr_cassettes/reloaded_entry.yml +0 -102
- data/spec/fixtures/vcr_cassettes/space.yml +0 -83
- data/spec/fixtures/vcr_cassettes/sync_deleted_asset.yml +0 -174
- data/spec/fixtures/vcr_cassettes/sync_deleted_entry.yml +0 -89
- data/spec/fixtures/vcr_cassettes/sync_deletion.yml +0 -191
- data/spec/fixtures/vcr_cassettes/sync_environment.yml +0 -81
- data/spec/fixtures/vcr_cassettes/sync_page.yml +0 -637
- data/spec/fixtures/vcr_cassettes/sync_page_2.yml +0 -71
- data/spec/fixtures/vcr_cassettes/sync_page_short.yml +0 -106
- data/spec/fixtures/vcr_cassettes/unauthorized.yml +0 -64
- data/spec/fixtures/vcr_cassettes/unavailable.yml +0 -76
- data/spec/link_spec.rb +0 -50
- data/spec/locale_spec.rb +0 -37
- data/spec/location_spec.rb +0 -25
- data/spec/request_spec.rb +0 -57
- data/spec/resource_building_spec.rb +0 -31
- data/spec/response_spec.rb +0 -62
- data/spec/space_spec.rb +0 -31
- data/spec/spec_helper.rb +0 -14
- data/spec/support/client.rb +0 -6
- data/spec/support/json_responses.rb +0 -18
- data/spec/support/vcr.rb +0 -16
- data/spec/sync_page_spec.rb +0 -103
- data/spec/sync_spec.rb +0 -180
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4624711e7107b359d434d25cd80d630befeea1e102644a77e661d39a75bb11ab
|
4
|
+
data.tar.gz: 2c98524d5540abdf4631d919285b7fe0d892893d98cde8e53fbb2231639336f8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f173fb7196031ab788394a0cc657342cbbb07210a2ffd7dd6faf3f330ab52fe497d718686e04d868acbe88f4425459ae2a4858dcd66df5544bc8c33b766679ba
|
7
|
+
data.tar.gz: 527960b745300f48f8b5ceffd668bd086b01c266fbe5dccaeff4b91f5a6d973535ce2bc2160c1ce247fa1d2936c029514a8ccb39cff67916230a6bc00e85230b
|
data/CHANGELOG.md
CHANGED
@@ -2,6 +2,23 @@
|
|
2
2
|
|
3
3
|
## Unreleased
|
4
4
|
|
5
|
+
## 2.16.3
|
6
|
+
### Fixed
|
7
|
+
* Fixed an issue where `raw['metadata']` was unexpectedly overwritten by `BaseResource#hydrate_metadata` method.
|
8
|
+
|
9
|
+
## 2.16.2
|
10
|
+
### Fixed
|
11
|
+
* Fixed an issue where entry's `raw['fields']` was unexpectedly overwritten by `FieldsResource#raw_with_links` method.
|
12
|
+
|
13
|
+
## 2.16.1
|
14
|
+
* Removed unncessary files from gem release package.
|
15
|
+
|
16
|
+
## 2.16.0
|
17
|
+
|
18
|
+
### Added
|
19
|
+
* Added `Contentful::ArrayLike#to_ary`. [#200](https://github.com/contentful/contentful.rb/issues/200)
|
20
|
+
* Added `_metadata[:tags]` to read metadata tags on `entry` and `asset`.
|
21
|
+
|
5
22
|
## 2.15.4
|
6
23
|
|
7
24
|
### Fixed
|
data/README.md
CHANGED
@@ -10,10 +10,10 @@
|
|
10
10
|
</a>
|
11
11
|
</p>
|
12
12
|
|
13
|
-
# contentful.rb - Contentful Ruby Delivery
|
13
|
+
# contentful.rb - Contentful Ruby Delivery Library
|
14
14
|
[](http://badge.fury.io/rb/contentful)
|
15
15
|
|
16
|
-
> Ruby
|
16
|
+
> Ruby library for the Contentful [Content Delivery API](https://www.contentful.com/developers/docs/references/content-delivery-api/) and [Content Preview API](https://www.contentful.com/developers/docs/references/content-preview-api/). It helps you to easily access your Content stored in Contentful with your Ruby applications.
|
17
17
|
|
18
18
|
<p align="center">
|
19
19
|
<img src="https://img.shields.io/badge/Status-Maintained-green.svg" alt="This repository is actively maintained" />
|
@@ -45,12 +45,12 @@
|
|
45
45
|
|
46
46
|
<!-- TOC -->
|
47
47
|
|
48
|
-
- [contentful.rb - Contentful Ruby Delivery
|
48
|
+
- [contentful.rb - Contentful Ruby Delivery library](#contentfulrb---contentful-ruby-delivery-library)
|
49
49
|
- [Core Features](#core-features)
|
50
50
|
- [Getting started](#getting-started)
|
51
51
|
- [Installation](#installation)
|
52
52
|
- [Your first request](#your-first-request)
|
53
|
-
- [Using this
|
53
|
+
- [Using this library with the Preview API](#using-this-library-with-the-preview-api)
|
54
54
|
- [Authentication](#authentication)
|
55
55
|
- [Documentation & References](#documentation--references)
|
56
56
|
- [Configuration](#configuration)
|
@@ -94,11 +94,11 @@
|
|
94
94
|
|
95
95
|
## Getting started
|
96
96
|
|
97
|
-
In order to get started with the Contentful Ruby
|
97
|
+
In order to get started with the Contentful Ruby library you'll need not only to install it, but also to get credentials which will allow you to have access to your content in Contentful.
|
98
98
|
|
99
99
|
- [Installation](#installation)
|
100
100
|
- [Your first request](#your-first-request)
|
101
|
-
- [Using this
|
101
|
+
- [Using this library with the Preview API](#using-this-library-with-the-preview-api)
|
102
102
|
- [Authentication](#authentication)
|
103
103
|
- [Documentation & References](#documentation--references)
|
104
104
|
|
@@ -118,7 +118,7 @@ gem i contentful
|
|
118
118
|
|
119
119
|
### Your first request
|
120
120
|
|
121
|
-
The following code snippet is the most basic one you can use to get some content from Contentful with this
|
121
|
+
The following code snippet is the most basic one you can use to get some content from Contentful with this library:
|
122
122
|
|
123
123
|
```ruby
|
124
124
|
require 'contentful'
|
@@ -132,9 +132,9 @@ client = Contentful::Client.new(
|
|
132
132
|
entry = client.entry('nyancat')
|
133
133
|
```
|
134
134
|
|
135
|
-
### Using this
|
135
|
+
### Using this library with the Preview API
|
136
136
|
|
137
|
-
This
|
137
|
+
This library can also be used with the Preview API. In order to do so, you need to use the Preview API Access token, available on the same page where you get the Delivery API token, and specify the host of the preview API, such as:
|
138
138
|
|
139
139
|
```ruby
|
140
140
|
require 'contentful'
|
@@ -168,7 +168,7 @@ For more information, check the [Contentful REST API reference on Authentication
|
|
168
168
|
- [Migrating to 2.x](#migrating-to-2x)
|
169
169
|
|
170
170
|
|
171
|
-
To help you get the most out of this
|
171
|
+
To help you get the most out of this library, we've prepared all available client configuration options, reference documentation, tutorials and other examples that will help you learn and understand how to use this library.
|
172
172
|
|
173
173
|
### Configuration
|
174
174
|
|
@@ -287,7 +287,7 @@ client = Contentful::Client.new(
|
|
287
287
|
<td><code>max_include_resolution_depth</code></td>
|
288
288
|
<td><code>20</code></td>
|
289
289
|
<td>
|
290
|
-
Maximum amount of levels to resolve includes for
|
290
|
+
Maximum amount of levels to resolve includes for library entities
|
291
291
|
(this is independent of API-level includes - it represents the maximum depth the include resolution
|
292
292
|
tree is allowed to resolved before falling back to <code>Link</code> objects).
|
293
293
|
This include resolution strategy is in place in order to avoid having infinite circular recursion on resources with circular dependencies.
|
@@ -424,6 +424,15 @@ entry.color # 'rainbow'
|
|
424
424
|
entry.birthday # #<DateTime: 2011-04-04T22:00:00+00:00 ((2455656j,79200s,0n),+0s,2299161j)>
|
425
425
|
```
|
426
426
|
|
427
|
+
#### Accessing tags
|
428
|
+
|
429
|
+
Tags can be accessed via the `#_metadata` method.
|
430
|
+
|
431
|
+
```ruby
|
432
|
+
entry = client.entry 'nyancat'
|
433
|
+
entry._metadata[:tags] # => [<Contentful::Link id='tagID'>]
|
434
|
+
```
|
435
|
+
|
427
436
|
#### Dynamic entries
|
428
437
|
|
429
438
|
However, you can (and should) set `:dynamic_entries` to `:auto` in your client configuration.
|
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
module Contentful
|
2
4
|
# Useful methods for array-like resources that can be included if an
|
3
5
|
# :items property exists
|
@@ -47,5 +49,12 @@ module Contentful
|
|
47
49
|
def last
|
48
50
|
items.last
|
49
51
|
end
|
52
|
+
|
53
|
+
# Delegates to items#to_ary
|
54
|
+
#
|
55
|
+
# @return [Contentful::Entry, Contentful::Asset]
|
56
|
+
def to_ary
|
57
|
+
items
|
58
|
+
end
|
50
59
|
end
|
51
60
|
end
|
@@ -5,7 +5,7 @@ require_relative 'support'
|
|
5
5
|
module Contentful
|
6
6
|
# Base definition of a Contentful Resource containing Sys properties
|
7
7
|
class BaseResource
|
8
|
-
attr_reader :raw, :default_locale, :sys
|
8
|
+
attr_reader :raw, :default_locale, :sys, :_metadata
|
9
9
|
|
10
10
|
# rubocop:disable Metrics/ParameterLists
|
11
11
|
def initialize(item, configuration = {}, _localized = false, _includes = [], entries = {}, depth = 0, _errors = [])
|
@@ -15,6 +15,7 @@ module Contentful
|
|
15
15
|
@depth = depth
|
16
16
|
@configuration = configuration
|
17
17
|
@sys = hydrate_sys
|
18
|
+
@_metadata = hydrate_metadata
|
18
19
|
|
19
20
|
define_sys_methods!
|
20
21
|
end
|
@@ -57,6 +58,7 @@ module Contentful
|
|
57
58
|
@configuration = raw_object[:configuration]
|
58
59
|
@default_locale = @configuration[:default_locale]
|
59
60
|
@sys = hydrate_sys
|
61
|
+
@_metadata = hydrate_metadata
|
60
62
|
@depth = 0
|
61
63
|
define_sys_methods!
|
62
64
|
end
|
@@ -93,6 +95,15 @@ module Contentful
|
|
93
95
|
result
|
94
96
|
end
|
95
97
|
|
98
|
+
def hydrate_metadata
|
99
|
+
result = {}
|
100
|
+
raw.fetch('metadata', {}).each do |k, v|
|
101
|
+
v = v.map { |tag| build_link(tag) } if k == 'tags'
|
102
|
+
result[Support.snakify(k, @configuration[:use_camel_case]).to_sym] = v
|
103
|
+
end
|
104
|
+
result
|
105
|
+
end
|
106
|
+
|
96
107
|
protected
|
97
108
|
|
98
109
|
def repr_name
|
@@ -67,6 +67,7 @@ module Contentful
|
|
67
67
|
def raw_with_links
|
68
68
|
links = fields.keys.select { |property| known_link?(property) }
|
69
69
|
processed_raw = raw.clone
|
70
|
+
processed_raw['fields'] = raw['fields'].clone
|
70
71
|
raw['fields'].each do |k, v|
|
71
72
|
links_key = Support.snakify(k, @configuration[:use_camel_case])
|
72
73
|
processed_raw['fields'][k] = links.include?(links_key.to_sym) ? send(links_key) : v
|
data/lib/contentful/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: contentful
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.16.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Contentful GmbH (Jan Lelis)
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date:
|
13
|
+
date: 2022-01-26 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: http
|
@@ -248,127 +248,9 @@ executables: []
|
|
248
248
|
extensions: []
|
249
249
|
extra_rdoc_files: []
|
250
250
|
files:
|
251
|
-
- ".gitignore"
|
252
|
-
- ".rspec"
|
253
|
-
- ".rubocop.yml"
|
254
|
-
- ".rubocop_todo.yml"
|
255
|
-
- ".ruby-version"
|
256
|
-
- ".travis.yml"
|
257
|
-
- ".yardopts"
|
258
251
|
- CHANGELOG.md
|
259
|
-
- Gemfile
|
260
|
-
- Gemfile.lock
|
261
|
-
- Guardfile
|
262
252
|
- LICENSE.txt
|
263
253
|
- README.md
|
264
|
-
- RELEASE.md
|
265
|
-
- Rakefile
|
266
|
-
- contentful.gemspec
|
267
|
-
- contentful.rb.sublime-project
|
268
|
-
- contentful.rb.sublime-workspace
|
269
|
-
- coverage/.last_run.json
|
270
|
-
- coverage/.resultset.json
|
271
|
-
- coverage/.resultset.json.lock
|
272
|
-
- coverage/assets/0.12.2/DataTables-1.10.20/images/sort_asc.png
|
273
|
-
- coverage/assets/0.12.2/DataTables-1.10.20/images/sort_asc_disabled.png
|
274
|
-
- coverage/assets/0.12.2/DataTables-1.10.20/images/sort_both.png
|
275
|
-
- coverage/assets/0.12.2/DataTables-1.10.20/images/sort_desc.png
|
276
|
-
- coverage/assets/0.12.2/DataTables-1.10.20/images/sort_desc_disabled.png
|
277
|
-
- coverage/assets/0.12.2/application.css
|
278
|
-
- coverage/assets/0.12.2/application.js
|
279
|
-
- coverage/assets/0.12.2/colorbox/border.png
|
280
|
-
- coverage/assets/0.12.2/colorbox/controls.png
|
281
|
-
- coverage/assets/0.12.2/colorbox/loading.gif
|
282
|
-
- coverage/assets/0.12.2/colorbox/loading_background.png
|
283
|
-
- coverage/assets/0.12.2/favicon_green.png
|
284
|
-
- coverage/assets/0.12.2/favicon_red.png
|
285
|
-
- coverage/assets/0.12.2/favicon_yellow.png
|
286
|
-
- coverage/assets/0.12.2/images/ui-bg_flat_0_aaaaaa_40x100.png
|
287
|
-
- coverage/assets/0.12.2/images/ui-bg_flat_75_ffffff_40x100.png
|
288
|
-
- coverage/assets/0.12.2/images/ui-bg_glass_55_fbf9ee_1x400.png
|
289
|
-
- coverage/assets/0.12.2/images/ui-bg_glass_65_ffffff_1x400.png
|
290
|
-
- coverage/assets/0.12.2/images/ui-bg_glass_75_dadada_1x400.png
|
291
|
-
- coverage/assets/0.12.2/images/ui-bg_glass_75_e6e6e6_1x400.png
|
292
|
-
- coverage/assets/0.12.2/images/ui-bg_glass_95_fef1ec_1x400.png
|
293
|
-
- coverage/assets/0.12.2/images/ui-bg_highlight-soft_75_cccccc_1x100.png
|
294
|
-
- coverage/assets/0.12.2/images/ui-icons_222222_256x240.png
|
295
|
-
- coverage/assets/0.12.2/images/ui-icons_2e83ff_256x240.png
|
296
|
-
- coverage/assets/0.12.2/images/ui-icons_454545_256x240.png
|
297
|
-
- coverage/assets/0.12.2/images/ui-icons_888888_256x240.png
|
298
|
-
- coverage/assets/0.12.2/images/ui-icons_cd0a0a_256x240.png
|
299
|
-
- coverage/assets/0.12.2/loading.gif
|
300
|
-
- coverage/assets/0.12.2/magnify.png
|
301
|
-
- coverage/index.html
|
302
|
-
- doc/Contentful.html
|
303
|
-
- doc/Contentful/AccessDenied.html
|
304
|
-
- doc/Contentful/Array.html
|
305
|
-
- doc/Contentful/ArrayCoercion.html
|
306
|
-
- doc/Contentful/ArrayLike.html
|
307
|
-
- doc/Contentful/Asset.html
|
308
|
-
- doc/Contentful/BadGateway.html
|
309
|
-
- doc/Contentful/BadRequest.html
|
310
|
-
- doc/Contentful/BaseCoercion.html
|
311
|
-
- doc/Contentful/BaseResource.html
|
312
|
-
- doc/Contentful/BooleanCoercion.html
|
313
|
-
- doc/Contentful/Client.html
|
314
|
-
- doc/Contentful/ContentType.html
|
315
|
-
- doc/Contentful/ContentTypeCache.html
|
316
|
-
- doc/Contentful/DateCoercion.html
|
317
|
-
- doc/Contentful/DeletedAsset.html
|
318
|
-
- doc/Contentful/DeletedEntry.html
|
319
|
-
- doc/Contentful/EmptyFieldError.html
|
320
|
-
- doc/Contentful/Entry.html
|
321
|
-
- doc/Contentful/Error.html
|
322
|
-
- doc/Contentful/Field.html
|
323
|
-
- doc/Contentful/FieldsResource.html
|
324
|
-
- doc/Contentful/File.html
|
325
|
-
- doc/Contentful/FloatCoercion.html
|
326
|
-
- doc/Contentful/IntegerCoercion.html
|
327
|
-
- doc/Contentful/Link.html
|
328
|
-
- doc/Contentful/LinkCoercion.html
|
329
|
-
- doc/Contentful/Locale.html
|
330
|
-
- doc/Contentful/Location.html
|
331
|
-
- doc/Contentful/LocationCoercion.html
|
332
|
-
- doc/Contentful/NotFound.html
|
333
|
-
- doc/Contentful/ObjectCoercion.html
|
334
|
-
- doc/Contentful/RateLimitExceeded.html
|
335
|
-
- doc/Contentful/Request.html
|
336
|
-
- doc/Contentful/ResourceBuilder.html
|
337
|
-
- doc/Contentful/ResourceReferences.html
|
338
|
-
- doc/Contentful/Response.html
|
339
|
-
- doc/Contentful/RichTextCoercion.html
|
340
|
-
- doc/Contentful/ServerError.html
|
341
|
-
- doc/Contentful/ServiceUnavailable.html
|
342
|
-
- doc/Contentful/Space.html
|
343
|
-
- doc/Contentful/StringCoercion.html
|
344
|
-
- doc/Contentful/Support.html
|
345
|
-
- doc/Contentful/SymbolCoercion.html
|
346
|
-
- doc/Contentful/Sync.html
|
347
|
-
- doc/Contentful/SyncPage.html
|
348
|
-
- doc/Contentful/TextCoercion.html
|
349
|
-
- doc/Contentful/Unauthorized.html
|
350
|
-
- doc/Contentful/UnparsableJson.html
|
351
|
-
- doc/Contentful/UnparsableResource.html
|
352
|
-
- doc/_index.html
|
353
|
-
- doc/class_list.html
|
354
|
-
- doc/css/common.css
|
355
|
-
- doc/css/full_list.css
|
356
|
-
- doc/css/style.css
|
357
|
-
- doc/file.CHANGELOG.html
|
358
|
-
- doc/file.LICENSE.html
|
359
|
-
- doc/file.README.html
|
360
|
-
- doc/file_list.html
|
361
|
-
- doc/frames.html
|
362
|
-
- doc/index.html
|
363
|
-
- doc/js/app.js
|
364
|
-
- doc/js/full_list.js
|
365
|
-
- doc/js/jquery.js
|
366
|
-
- doc/method_list.html
|
367
|
-
- doc/top-level-namespace.html
|
368
|
-
- examples/custom_classes.rb
|
369
|
-
- examples/example_queries.rb
|
370
|
-
- examples/raise_errors.rb
|
371
|
-
- examples/raw_mode.rb
|
372
254
|
- lib/contentful.rb
|
373
255
|
- lib/contentful/array.rb
|
374
256
|
- lib/contentful/array_like.rb
|
@@ -397,132 +279,6 @@ files:
|
|
397
279
|
- lib/contentful/sync.rb
|
398
280
|
- lib/contentful/sync_page.rb
|
399
281
|
- lib/contentful/version.rb
|
400
|
-
- spec/array_spec.rb
|
401
|
-
- spec/asset_spec.rb
|
402
|
-
- spec/auto_includes_spec.rb
|
403
|
-
- spec/client_class_spec.rb
|
404
|
-
- spec/client_configuration_spec.rb
|
405
|
-
- spec/content_type_spec.rb
|
406
|
-
- spec/deleted_asset_spec.rb
|
407
|
-
- spec/deleted_entry_spec.rb
|
408
|
-
- spec/entry_spec.rb
|
409
|
-
- spec/error_class_spec.rb
|
410
|
-
- spec/error_requests_spec.rb
|
411
|
-
- spec/field_spec.rb
|
412
|
-
- spec/file_spec.rb
|
413
|
-
- spec/fixtures/json_responses/400_details_errors_object.json
|
414
|
-
- spec/fixtures/json_responses/400_details_errors_string.json
|
415
|
-
- spec/fixtures/json_responses/400_details_string.json
|
416
|
-
- spec/fixtures/json_responses/403_reasons.json
|
417
|
-
- spec/fixtures/json_responses/404_details_string.json
|
418
|
-
- spec/fixtures/json_responses/404_id.json
|
419
|
-
- spec/fixtures/json_responses/404_sys_type.json
|
420
|
-
- spec/fixtures/json_responses/404_type.json
|
421
|
-
- spec/fixtures/json_responses/content_type.json
|
422
|
-
- spec/fixtures/json_responses/default_400.json
|
423
|
-
- spec/fixtures/json_responses/default_401.json
|
424
|
-
- spec/fixtures/json_responses/default_403.json
|
425
|
-
- spec/fixtures/json_responses/default_404.json
|
426
|
-
- spec/fixtures/json_responses/default_429.json
|
427
|
-
- spec/fixtures/json_responses/default_500.json
|
428
|
-
- spec/fixtures/json_responses/default_502.json
|
429
|
-
- spec/fixtures/json_responses/default_503.json
|
430
|
-
- spec/fixtures/json_responses/includes.json
|
431
|
-
- spec/fixtures/json_responses/link_array.json
|
432
|
-
- spec/fixtures/json_responses/not_found.json
|
433
|
-
- spec/fixtures/json_responses/nyancat.json
|
434
|
-
- spec/fixtures/json_responses/other_error.json
|
435
|
-
- spec/fixtures/json_responses/other_error_no_details.json
|
436
|
-
- spec/fixtures/json_responses/other_error_no_message.json
|
437
|
-
- spec/fixtures/json_responses/other_error_no_request_id.json
|
438
|
-
- spec/fixtures/json_responses/other_error_nothing.json
|
439
|
-
- spec/fixtures/json_responses/self_link.json
|
440
|
-
- spec/fixtures/json_responses/unparsable.json
|
441
|
-
- spec/fixtures/vcr_cassettes/array.yml
|
442
|
-
- spec/fixtures/vcr_cassettes/array/marshal_custom_classes.yml
|
443
|
-
- spec/fixtures/vcr_cassettes/array/marshal_unpublished.yml
|
444
|
-
- spec/fixtures/vcr_cassettes/array/nested_resources.yml
|
445
|
-
- spec/fixtures/vcr_cassettes/arrayField.yml
|
446
|
-
- spec/fixtures/vcr_cassettes/array_page_1.yml
|
447
|
-
- spec/fixtures/vcr_cassettes/array_page_2.yml
|
448
|
-
- spec/fixtures/vcr_cassettes/asset.yml
|
449
|
-
- spec/fixtures/vcr_cassettes/asset/select_empty_array.yml
|
450
|
-
- spec/fixtures/vcr_cassettes/asset/select_no_sys.yml
|
451
|
-
- spec/fixtures/vcr_cassettes/asset/select_one_field.yml
|
452
|
-
- spec/fixtures/vcr_cassettes/asset/select_only_sys.yml
|
453
|
-
- spec/fixtures/vcr_cassettes/assets/issues_129.yml
|
454
|
-
- spec/fixtures/vcr_cassettes/assets/issues_jekyll_46.yml
|
455
|
-
- spec/fixtures/vcr_cassettes/bad_request.yml
|
456
|
-
- spec/fixtures/vcr_cassettes/content_type.yml
|
457
|
-
- spec/fixtures/vcr_cassettes/entries.yml
|
458
|
-
- spec/fixtures/vcr_cassettes/entries/empty_fields.yml
|
459
|
-
- spec/fixtures/vcr_cassettes/entries/issue_117.yml
|
460
|
-
- spec/fixtures/vcr_cassettes/entries/issue_125.yml
|
461
|
-
- spec/fixtures/vcr_cassettes/entries/rich_text.yml
|
462
|
-
- spec/fixtures/vcr_cassettes/entries/rich_text_hydration_issue.yml
|
463
|
-
- spec/fixtures/vcr_cassettes/entries/rich_text_nested_fields.yml
|
464
|
-
- spec/fixtures/vcr_cassettes/entries/rich_text_unresolved_relationships.yml
|
465
|
-
- spec/fixtures/vcr_cassettes/entries/unresolvable_assets.yml
|
466
|
-
- spec/fixtures/vcr_cassettes/entries/unresolvable_filter.yml
|
467
|
-
- spec/fixtures/vcr_cassettes/entries/unresolvable_filter_deeply_nested.yml
|
468
|
-
- spec/fixtures/vcr_cassettes/entry.yml
|
469
|
-
- spec/fixtures/vcr_cassettes/entry/custom_resource.yml
|
470
|
-
- spec/fixtures/vcr_cassettes/entry/include_resolution.yml
|
471
|
-
- spec/fixtures/vcr_cassettes/entry/include_resolution_uniques.yml
|
472
|
-
- spec/fixtures/vcr_cassettes/entry/json_objects.yml
|
473
|
-
- spec/fixtures/vcr_cassettes/entry/json_objects_client.yml
|
474
|
-
- spec/fixtures/vcr_cassettes/entry/marshal_138.yml
|
475
|
-
- spec/fixtures/vcr_cassettes/entry/marshal_unpublished.yml
|
476
|
-
- spec/fixtures/vcr_cassettes/entry/marshall.yml
|
477
|
-
- spec/fixtures/vcr_cassettes/entry/raw.yml
|
478
|
-
- spec/fixtures/vcr_cassettes/entry/search_link_to_asset.yml
|
479
|
-
- spec/fixtures/vcr_cassettes/entry/search_link_to_entry.yml
|
480
|
-
- spec/fixtures/vcr_cassettes/entry/search_link_to_entry_with_custom_query.yml
|
481
|
-
- spec/fixtures/vcr_cassettes/entry/select_empty_array.yml
|
482
|
-
- spec/fixtures/vcr_cassettes/entry/select_no_sys.yml
|
483
|
-
- spec/fixtures/vcr_cassettes/entry/select_one_field.yml
|
484
|
-
- spec/fixtures/vcr_cassettes/entry/select_one_field_proper.yml
|
485
|
-
- spec/fixtures/vcr_cassettes/entry/select_only_sys.yml
|
486
|
-
- spec/fixtures/vcr_cassettes/entry_cache.yml
|
487
|
-
- spec/fixtures/vcr_cassettes/entry_locales.yml
|
488
|
-
- spec/fixtures/vcr_cassettes/field.yml
|
489
|
-
- spec/fixtures/vcr_cassettes/human.yml
|
490
|
-
- spec/fixtures/vcr_cassettes/linkField.yml
|
491
|
-
- spec/fixtures/vcr_cassettes/locale.yml
|
492
|
-
- spec/fixtures/vcr_cassettes/locale_from_environment.yml
|
493
|
-
- spec/fixtures/vcr_cassettes/location.yml
|
494
|
-
- spec/fixtures/vcr_cassettes/multi_locale_array_reference.yml
|
495
|
-
- spec/fixtures/vcr_cassettes/multi_locale_reference.yml
|
496
|
-
- spec/fixtures/vcr_cassettes/not_found.yml
|
497
|
-
- spec/fixtures/vcr_cassettes/nyancat.yml
|
498
|
-
- spec/fixtures/vcr_cassettes/query_array_1.yml
|
499
|
-
- spec/fixtures/vcr_cassettes/query_array_2.yml
|
500
|
-
- spec/fixtures/vcr_cassettes/ratelimit.yml
|
501
|
-
- spec/fixtures/vcr_cassettes/ratelimit_retry.yml
|
502
|
-
- spec/fixtures/vcr_cassettes/reloaded_entry.yml
|
503
|
-
- spec/fixtures/vcr_cassettes/space.yml
|
504
|
-
- spec/fixtures/vcr_cassettes/sync_deleted_asset.yml
|
505
|
-
- spec/fixtures/vcr_cassettes/sync_deleted_entry.yml
|
506
|
-
- spec/fixtures/vcr_cassettes/sync_deletion.yml
|
507
|
-
- spec/fixtures/vcr_cassettes/sync_environment.yml
|
508
|
-
- spec/fixtures/vcr_cassettes/sync_page.yml
|
509
|
-
- spec/fixtures/vcr_cassettes/sync_page_2.yml
|
510
|
-
- spec/fixtures/vcr_cassettes/sync_page_short.yml
|
511
|
-
- spec/fixtures/vcr_cassettes/unauthorized.yml
|
512
|
-
- spec/fixtures/vcr_cassettes/unavailable.yml
|
513
|
-
- spec/link_spec.rb
|
514
|
-
- spec/locale_spec.rb
|
515
|
-
- spec/location_spec.rb
|
516
|
-
- spec/request_spec.rb
|
517
|
-
- spec/resource_building_spec.rb
|
518
|
-
- spec/response_spec.rb
|
519
|
-
- spec/space_spec.rb
|
520
|
-
- spec/spec_helper.rb
|
521
|
-
- spec/support/client.rb
|
522
|
-
- spec/support/json_responses.rb
|
523
|
-
- spec/support/vcr.rb
|
524
|
-
- spec/sync_page_spec.rb
|
525
|
-
- spec/sync_spec.rb
|
526
282
|
homepage: https://github.com/contentful/contentful.rb
|
527
283
|
licenses:
|
528
284
|
- MIT
|
@@ -546,130 +302,4 @@ rubygems_version: 3.1.2
|
|
546
302
|
signing_key:
|
547
303
|
specification_version: 4
|
548
304
|
summary: contentful
|
549
|
-
test_files:
|
550
|
-
- spec/array_spec.rb
|
551
|
-
- spec/asset_spec.rb
|
552
|
-
- spec/auto_includes_spec.rb
|
553
|
-
- spec/client_class_spec.rb
|
554
|
-
- spec/client_configuration_spec.rb
|
555
|
-
- spec/content_type_spec.rb
|
556
|
-
- spec/deleted_asset_spec.rb
|
557
|
-
- spec/deleted_entry_spec.rb
|
558
|
-
- spec/entry_spec.rb
|
559
|
-
- spec/error_class_spec.rb
|
560
|
-
- spec/error_requests_spec.rb
|
561
|
-
- spec/field_spec.rb
|
562
|
-
- spec/file_spec.rb
|
563
|
-
- spec/fixtures/json_responses/400_details_errors_object.json
|
564
|
-
- spec/fixtures/json_responses/400_details_errors_string.json
|
565
|
-
- spec/fixtures/json_responses/400_details_string.json
|
566
|
-
- spec/fixtures/json_responses/403_reasons.json
|
567
|
-
- spec/fixtures/json_responses/404_details_string.json
|
568
|
-
- spec/fixtures/json_responses/404_id.json
|
569
|
-
- spec/fixtures/json_responses/404_sys_type.json
|
570
|
-
- spec/fixtures/json_responses/404_type.json
|
571
|
-
- spec/fixtures/json_responses/content_type.json
|
572
|
-
- spec/fixtures/json_responses/default_400.json
|
573
|
-
- spec/fixtures/json_responses/default_401.json
|
574
|
-
- spec/fixtures/json_responses/default_403.json
|
575
|
-
- spec/fixtures/json_responses/default_404.json
|
576
|
-
- spec/fixtures/json_responses/default_429.json
|
577
|
-
- spec/fixtures/json_responses/default_500.json
|
578
|
-
- spec/fixtures/json_responses/default_502.json
|
579
|
-
- spec/fixtures/json_responses/default_503.json
|
580
|
-
- spec/fixtures/json_responses/includes.json
|
581
|
-
- spec/fixtures/json_responses/link_array.json
|
582
|
-
- spec/fixtures/json_responses/not_found.json
|
583
|
-
- spec/fixtures/json_responses/nyancat.json
|
584
|
-
- spec/fixtures/json_responses/other_error.json
|
585
|
-
- spec/fixtures/json_responses/other_error_no_details.json
|
586
|
-
- spec/fixtures/json_responses/other_error_no_message.json
|
587
|
-
- spec/fixtures/json_responses/other_error_no_request_id.json
|
588
|
-
- spec/fixtures/json_responses/other_error_nothing.json
|
589
|
-
- spec/fixtures/json_responses/self_link.json
|
590
|
-
- spec/fixtures/json_responses/unparsable.json
|
591
|
-
- spec/fixtures/vcr_cassettes/array.yml
|
592
|
-
- spec/fixtures/vcr_cassettes/array/marshal_custom_classes.yml
|
593
|
-
- spec/fixtures/vcr_cassettes/array/marshal_unpublished.yml
|
594
|
-
- spec/fixtures/vcr_cassettes/array/nested_resources.yml
|
595
|
-
- spec/fixtures/vcr_cassettes/arrayField.yml
|
596
|
-
- spec/fixtures/vcr_cassettes/array_page_1.yml
|
597
|
-
- spec/fixtures/vcr_cassettes/array_page_2.yml
|
598
|
-
- spec/fixtures/vcr_cassettes/asset.yml
|
599
|
-
- spec/fixtures/vcr_cassettes/asset/select_empty_array.yml
|
600
|
-
- spec/fixtures/vcr_cassettes/asset/select_no_sys.yml
|
601
|
-
- spec/fixtures/vcr_cassettes/asset/select_one_field.yml
|
602
|
-
- spec/fixtures/vcr_cassettes/asset/select_only_sys.yml
|
603
|
-
- spec/fixtures/vcr_cassettes/assets/issues_129.yml
|
604
|
-
- spec/fixtures/vcr_cassettes/assets/issues_jekyll_46.yml
|
605
|
-
- spec/fixtures/vcr_cassettes/bad_request.yml
|
606
|
-
- spec/fixtures/vcr_cassettes/content_type.yml
|
607
|
-
- spec/fixtures/vcr_cassettes/entries.yml
|
608
|
-
- spec/fixtures/vcr_cassettes/entries/empty_fields.yml
|
609
|
-
- spec/fixtures/vcr_cassettes/entries/issue_117.yml
|
610
|
-
- spec/fixtures/vcr_cassettes/entries/issue_125.yml
|
611
|
-
- spec/fixtures/vcr_cassettes/entries/rich_text.yml
|
612
|
-
- spec/fixtures/vcr_cassettes/entries/rich_text_hydration_issue.yml
|
613
|
-
- spec/fixtures/vcr_cassettes/entries/rich_text_nested_fields.yml
|
614
|
-
- spec/fixtures/vcr_cassettes/entries/rich_text_unresolved_relationships.yml
|
615
|
-
- spec/fixtures/vcr_cassettes/entries/unresolvable_assets.yml
|
616
|
-
- spec/fixtures/vcr_cassettes/entries/unresolvable_filter.yml
|
617
|
-
- spec/fixtures/vcr_cassettes/entries/unresolvable_filter_deeply_nested.yml
|
618
|
-
- spec/fixtures/vcr_cassettes/entry.yml
|
619
|
-
- spec/fixtures/vcr_cassettes/entry/custom_resource.yml
|
620
|
-
- spec/fixtures/vcr_cassettes/entry/include_resolution.yml
|
621
|
-
- spec/fixtures/vcr_cassettes/entry/include_resolution_uniques.yml
|
622
|
-
- spec/fixtures/vcr_cassettes/entry/json_objects.yml
|
623
|
-
- spec/fixtures/vcr_cassettes/entry/json_objects_client.yml
|
624
|
-
- spec/fixtures/vcr_cassettes/entry/marshal_138.yml
|
625
|
-
- spec/fixtures/vcr_cassettes/entry/marshal_unpublished.yml
|
626
|
-
- spec/fixtures/vcr_cassettes/entry/marshall.yml
|
627
|
-
- spec/fixtures/vcr_cassettes/entry/raw.yml
|
628
|
-
- spec/fixtures/vcr_cassettes/entry/search_link_to_asset.yml
|
629
|
-
- spec/fixtures/vcr_cassettes/entry/search_link_to_entry.yml
|
630
|
-
- spec/fixtures/vcr_cassettes/entry/search_link_to_entry_with_custom_query.yml
|
631
|
-
- spec/fixtures/vcr_cassettes/entry/select_empty_array.yml
|
632
|
-
- spec/fixtures/vcr_cassettes/entry/select_no_sys.yml
|
633
|
-
- spec/fixtures/vcr_cassettes/entry/select_one_field.yml
|
634
|
-
- spec/fixtures/vcr_cassettes/entry/select_one_field_proper.yml
|
635
|
-
- spec/fixtures/vcr_cassettes/entry/select_only_sys.yml
|
636
|
-
- spec/fixtures/vcr_cassettes/entry_cache.yml
|
637
|
-
- spec/fixtures/vcr_cassettes/entry_locales.yml
|
638
|
-
- spec/fixtures/vcr_cassettes/field.yml
|
639
|
-
- spec/fixtures/vcr_cassettes/human.yml
|
640
|
-
- spec/fixtures/vcr_cassettes/linkField.yml
|
641
|
-
- spec/fixtures/vcr_cassettes/locale.yml
|
642
|
-
- spec/fixtures/vcr_cassettes/locale_from_environment.yml
|
643
|
-
- spec/fixtures/vcr_cassettes/location.yml
|
644
|
-
- spec/fixtures/vcr_cassettes/multi_locale_array_reference.yml
|
645
|
-
- spec/fixtures/vcr_cassettes/multi_locale_reference.yml
|
646
|
-
- spec/fixtures/vcr_cassettes/not_found.yml
|
647
|
-
- spec/fixtures/vcr_cassettes/nyancat.yml
|
648
|
-
- spec/fixtures/vcr_cassettes/query_array_1.yml
|
649
|
-
- spec/fixtures/vcr_cassettes/query_array_2.yml
|
650
|
-
- spec/fixtures/vcr_cassettes/ratelimit.yml
|
651
|
-
- spec/fixtures/vcr_cassettes/ratelimit_retry.yml
|
652
|
-
- spec/fixtures/vcr_cassettes/reloaded_entry.yml
|
653
|
-
- spec/fixtures/vcr_cassettes/space.yml
|
654
|
-
- spec/fixtures/vcr_cassettes/sync_deleted_asset.yml
|
655
|
-
- spec/fixtures/vcr_cassettes/sync_deleted_entry.yml
|
656
|
-
- spec/fixtures/vcr_cassettes/sync_deletion.yml
|
657
|
-
- spec/fixtures/vcr_cassettes/sync_environment.yml
|
658
|
-
- spec/fixtures/vcr_cassettes/sync_page.yml
|
659
|
-
- spec/fixtures/vcr_cassettes/sync_page_2.yml
|
660
|
-
- spec/fixtures/vcr_cassettes/sync_page_short.yml
|
661
|
-
- spec/fixtures/vcr_cassettes/unauthorized.yml
|
662
|
-
- spec/fixtures/vcr_cassettes/unavailable.yml
|
663
|
-
- spec/link_spec.rb
|
664
|
-
- spec/locale_spec.rb
|
665
|
-
- spec/location_spec.rb
|
666
|
-
- spec/request_spec.rb
|
667
|
-
- spec/resource_building_spec.rb
|
668
|
-
- spec/response_spec.rb
|
669
|
-
- spec/space_spec.rb
|
670
|
-
- spec/spec_helper.rb
|
671
|
-
- spec/support/client.rb
|
672
|
-
- spec/support/json_responses.rb
|
673
|
-
- spec/support/vcr.rb
|
674
|
-
- spec/sync_page_spec.rb
|
675
|
-
- spec/sync_spec.rb
|
305
|
+
test_files: []
|
data/.gitignore
DELETED
data/.rspec
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
--color --format documentation
|
data/.rubocop.yml
DELETED
@@ -1,31 +0,0 @@
|
|
1
|
-
inherit_from: .rubocop_todo.yml
|
2
|
-
|
3
|
-
Encoding:
|
4
|
-
Enabled: false
|
5
|
-
|
6
|
-
Metrics/ClassLength:
|
7
|
-
CountComments: false
|
8
|
-
|
9
|
-
Metrics/MethodLength:
|
10
|
-
CountComments: false
|
11
|
-
|
12
|
-
AllCops:
|
13
|
-
Exclude:
|
14
|
-
- contentful.gemspec
|
15
|
-
- spec/**/*
|
16
|
-
- examples/**/*
|
17
|
-
- Guardfile
|
18
|
-
- Gemfile
|
19
|
-
- Rakefile
|
20
|
-
|
21
|
-
Metrics/ClassLength:
|
22
|
-
Max: 280
|
23
|
-
|
24
|
-
Metrics/ParameterLists:
|
25
|
-
Max: 6
|
26
|
-
|
27
|
-
Style/MutableConstant:
|
28
|
-
Enabled: false
|
29
|
-
|
30
|
-
Style/SignalException:
|
31
|
-
EnforcedStyle: 'semantic'
|