grape-swagger-representable 0.2.2 → 0.3.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.
- checksums.yaml +5 -5
- data/.editorconfig +14 -0
- data/.github/workflows/danger-comment.yml +16 -0
- data/.github/workflows/danger.yml +15 -0
- data/.github/workflows/rubocop.yml +17 -0
- data/.github/workflows/test.yml +48 -0
- data/.rspec +2 -0
- data/.rubocop.yml +7 -3
- data/.rubocop_todo.yml +1 -1
- data/.simplecov +13 -0
- data/CHANGELOG.md +46 -0
- data/Dangerfile +10 -0
- data/Gemfile +18 -1
- data/README.md +19 -7
- data/RELEASING.md +80 -0
- data/bin/pry +1 -5
- data/grape-swagger-representable.gemspec +18 -18
- data/lib/grape-swagger/representable/parser.rb +48 -33
- data/lib/grape-swagger/representable/version.rb +1 -1
- data/lib/grape-swagger/representable.rb +3 -3
- data/lib/grape-swagger-representable.rb +1 -1
- metadata +28 -173
- data/.travis.yml +0 -30
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
|
-
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
2
|
+
SHA256:
|
|
3
|
+
metadata.gz: 44362c5a48cb9109ec550ebc8d2face95801d9e0464929856454ac6309c81218
|
|
4
|
+
data.tar.gz: eb9f6e0962aee963907d9953b7b8aba9d9b5caaff24a78a370459f2f6b4fcbc1
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 2be378bd6bdc2b8963373a83efa30f408979572376fd3f460d5495b92306315b007b3f837f4ef8dc6e2883772a0ef78935a1e30fcecf02f0ee670b8137e46132
|
|
7
|
+
data.tar.gz: 65dadaa81529fed71e46898f9078aab0d1ce6c3d448cfb6ac9e074adffee0a0b0ba553bd1ee2c15af701ba077f11b68dbedaa3aef6f27034f22d0c8fb3ba6cd1
|
data/.editorconfig
ADDED
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
name: Danger Comment
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
workflow_run:
|
|
5
|
+
workflows: [Danger]
|
|
6
|
+
types: [completed]
|
|
7
|
+
|
|
8
|
+
permissions:
|
|
9
|
+
contents: read
|
|
10
|
+
actions: read
|
|
11
|
+
issues: write
|
|
12
|
+
pull-requests: write
|
|
13
|
+
|
|
14
|
+
jobs:
|
|
15
|
+
comment:
|
|
16
|
+
uses: numbata/danger-pr-comment/.github/workflows/danger-comment.yml@v0.1.0
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
name: Danger
|
|
2
|
+
|
|
3
|
+
on:
|
|
4
|
+
pull_request:
|
|
5
|
+
types: [opened, reopened, edited, synchronize]
|
|
6
|
+
|
|
7
|
+
permissions:
|
|
8
|
+
contents: read
|
|
9
|
+
|
|
10
|
+
jobs:
|
|
11
|
+
danger:
|
|
12
|
+
uses: numbata/danger-pr-comment/.github/workflows/danger-run.yml@v0.1.0
|
|
13
|
+
with:
|
|
14
|
+
ruby-version: '3.4'
|
|
15
|
+
bundler-cache: true
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
name: RuboCop
|
|
2
|
+
on: [push, pull_request]
|
|
3
|
+
permissions:
|
|
4
|
+
contents: read
|
|
5
|
+
concurrency:
|
|
6
|
+
group: ${{ github.workflow }}-${{ github.ref }}
|
|
7
|
+
cancel-in-progress: true
|
|
8
|
+
jobs:
|
|
9
|
+
rubocop:
|
|
10
|
+
runs-on: ubuntu-latest
|
|
11
|
+
steps:
|
|
12
|
+
- uses: actions/checkout@v7
|
|
13
|
+
- uses: ruby/setup-ruby@v1
|
|
14
|
+
with:
|
|
15
|
+
ruby-version: '4.0'
|
|
16
|
+
bundler-cache: true
|
|
17
|
+
- run: bundle exec rubocop
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
name: Tests
|
|
2
|
+
on: [push, pull_request]
|
|
3
|
+
permissions:
|
|
4
|
+
contents: read
|
|
5
|
+
concurrency:
|
|
6
|
+
group: ${{ github.workflow }}-${{ github.ref }}
|
|
7
|
+
cancel-in-progress: true
|
|
8
|
+
jobs:
|
|
9
|
+
test:
|
|
10
|
+
runs-on: ubuntu-latest
|
|
11
|
+
timeout-minutes: 20
|
|
12
|
+
strategy:
|
|
13
|
+
fail-fast: false
|
|
14
|
+
matrix:
|
|
15
|
+
include:
|
|
16
|
+
- { ruby: '3.1', grape: '~> 2.4', representable: '~> 3.2.0' }
|
|
17
|
+
- { ruby: '3.3', grape: '~> 2.4', representable: '~> 3.3' }
|
|
18
|
+
- { ruby: '3.3', grape: '~> 3.0', representable: '~> 3.3' }
|
|
19
|
+
- { ruby: '3.4', grape: '~> 4.0', representable: '~> 3.3' }
|
|
20
|
+
- { ruby: '4.0', grape: '~> 4.0', representable: '~> 3.3' }
|
|
21
|
+
name: Ruby ${{ matrix.ruby }} / Grape ${{ matrix.grape }}
|
|
22
|
+
env:
|
|
23
|
+
GRAPE_VERSION: ${{ matrix.grape }}
|
|
24
|
+
REPRESENTABLE_VERSION: ${{ matrix.representable }}
|
|
25
|
+
steps:
|
|
26
|
+
- uses: actions/checkout@v7
|
|
27
|
+
- uses: ruby/setup-ruby@v1
|
|
28
|
+
with:
|
|
29
|
+
ruby-version: ${{ matrix.ruby }}
|
|
30
|
+
bundler-cache: true
|
|
31
|
+
- run: bundle exec rake spec
|
|
32
|
+
- name: Coveralls
|
|
33
|
+
uses: coverallsapp/github-action@v2
|
|
34
|
+
with:
|
|
35
|
+
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
36
|
+
file: coverage/lcov.info
|
|
37
|
+
format: lcov
|
|
38
|
+
flag-name: ruby-${{ matrix.ruby }}-grape-${{ strategy.job-index }}
|
|
39
|
+
parallel: true
|
|
40
|
+
finish:
|
|
41
|
+
name: Finish Coveralls
|
|
42
|
+
needs: test
|
|
43
|
+
runs-on: ubuntu-latest
|
|
44
|
+
steps:
|
|
45
|
+
- uses: coverallsapp/github-action@v2
|
|
46
|
+
with:
|
|
47
|
+
github-token: ${{ secrets.GITHUB_TOKEN }}
|
|
48
|
+
parallel-finished: true
|
data/.rspec
CHANGED
data/.rubocop.yml
CHANGED
|
@@ -1,16 +1,20 @@
|
|
|
1
1
|
AllCops:
|
|
2
|
+
NewCops: enable
|
|
2
3
|
Exclude:
|
|
3
4
|
- vendor/**/*
|
|
4
|
-
TargetRubyVersion:
|
|
5
|
+
TargetRubyVersion: 3.1
|
|
5
6
|
|
|
6
7
|
inherit_from: .rubocop_todo.yml
|
|
7
8
|
|
|
8
9
|
Layout/EmptyLinesAroundArguments:
|
|
9
10
|
Enabled: false
|
|
10
11
|
|
|
11
|
-
Layout/
|
|
12
|
+
Layout/FirstHashElementIndentation:
|
|
12
13
|
EnforcedStyle: consistent
|
|
13
14
|
|
|
15
|
+
Layout/MultilineMethodCallIndentation:
|
|
16
|
+
EnforcedStyle: indented
|
|
17
|
+
|
|
14
18
|
Metrics/BlockLength:
|
|
15
19
|
Exclude:
|
|
16
20
|
- spec/**/*
|
|
@@ -18,7 +22,7 @@ Metrics/BlockLength:
|
|
|
18
22
|
Metrics/ClassLength:
|
|
19
23
|
Max: 300
|
|
20
24
|
|
|
21
|
-
|
|
25
|
+
Layout/LineLength:
|
|
22
26
|
Max: 120
|
|
23
27
|
Exclude:
|
|
24
28
|
- spec/**/*
|
data/.rubocop_todo.yml
CHANGED
|
@@ -17,7 +17,7 @@ Metrics/CyclomaticComplexity:
|
|
|
17
17
|
# Offense count: 2
|
|
18
18
|
# Configuration parameters: AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns.
|
|
19
19
|
# URISchemes: http, https
|
|
20
|
-
|
|
20
|
+
Layout/LineLength:
|
|
21
21
|
Max: 130
|
|
22
22
|
|
|
23
23
|
# Offense count: 2
|
data/.simplecov
ADDED
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
require 'simplecov-lcov'
|
|
4
|
+
|
|
5
|
+
SimpleCov::Formatter::LcovFormatter.config.report_with_single_file = true
|
|
6
|
+
SimpleCov::Formatter::LcovFormatter.config.single_report_path = 'coverage/lcov.info'
|
|
7
|
+
SimpleCov.formatter = ENV['CI'] ? SimpleCov::Formatter::LcovFormatter : SimpleCov::Formatter::HTMLFormatter
|
|
8
|
+
|
|
9
|
+
SimpleCov.configure do
|
|
10
|
+
enable_coverage :branch
|
|
11
|
+
add_filter '/spec/'
|
|
12
|
+
track_files 'lib/**/*.rb'
|
|
13
|
+
end
|
data/CHANGELOG.md
ADDED
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
### 0.3.0 (2026/10/27)
|
|
2
|
+
|
|
3
|
+
* [#14](https://github.com/ruby-grape/grape-swagger-representable/pull/14): Modernize dependencies, gem metadata, and specifications - [@AlexWayfer](https://github.com/AlexWayfer).
|
|
4
|
+
* [#14](https://github.com/ruby-grape/grape-swagger-representable/pull/14): Require Ruby 3.1 or newer, support Ruby 4.0, and replace Travis with GitHub Actions testing Grape 2/3/4 and Representable 3.2/latest 3.x with Coveralls coverage - [@dblock](https://github.com/dblock).
|
|
5
|
+
* [#15](https://github.com/ruby-grape/grape-swagger-representable/pull/15): Add a changelog and tokenless Danger checks for pull request changelog entries - [@dblock](https://github.com/dblock).
|
|
6
|
+
* Add release preparation and publication instructions in `RELEASING.md` - [@dblock](https://github.com/dblock).
|
|
7
|
+
|
|
8
|
+
### 0.2.2 (2018/09/22)
|
|
9
|
+
|
|
10
|
+
* [#13](https://github.com/ruby-grape/grape-swagger-representable/pull/13): Support hidden properties - [@onemanstartup](https://github.com/onemanstartup).
|
|
11
|
+
|
|
12
|
+
### 0.2.1 (2018/09/01)
|
|
13
|
+
|
|
14
|
+
* [#12](https://github.com/ruby-grape/grape-swagger-representable/pull/12): Support Procs for enum values - [@onemanstartup](https://github.com/onemanstartup).
|
|
15
|
+
|
|
16
|
+
### 0.2.0 (2018/08/22)
|
|
17
|
+
|
|
18
|
+
* [#11](https://github.com/ruby-grape/grape-swagger-representable/pull/11): Document required properties, including nested representers - [@kzaitsev](https://github.com/kzaitsev).
|
|
19
|
+
|
|
20
|
+
### 0.1.6 (2018/03/14)
|
|
21
|
+
|
|
22
|
+
* [#9](https://github.com/ruby-grape/grape-swagger-representable/pull/9): Honor property aliases specified with `:as` - [@jpsikorra](https://github.com/jpsikorra).
|
|
23
|
+
|
|
24
|
+
### 0.1.5 (2017/11/21)
|
|
25
|
+
|
|
26
|
+
* [#7](https://github.com/ruby-grape/grape-swagger-representable/pull/7): Support property examples - [@yewton](https://github.com/yewton).
|
|
27
|
+
|
|
28
|
+
### 0.1.4 (2017/03/10)
|
|
29
|
+
|
|
30
|
+
* [#4](https://github.com/ruby-grape/grape-swagger-representable/pull/4): Use property attributes when the corresponding documentation attributes are absent - [@Kris-LIBIS](https://github.com/Kris-LIBIS).
|
|
31
|
+
|
|
32
|
+
### 0.1.3 (2016/05/16)
|
|
33
|
+
|
|
34
|
+
* [#3](https://github.com/ruby-grape/grape-swagger-representable/pull/3): Update the minimum grape-swagger version - [@kzaitsev](https://github.com/kzaitsev).
|
|
35
|
+
|
|
36
|
+
### 0.1.2 (2016/05/11)
|
|
37
|
+
|
|
38
|
+
* Version-only release - [@kzaitsev](https://github.com/kzaitsev).
|
|
39
|
+
|
|
40
|
+
### 0.1.1 (2016/05/11)
|
|
41
|
+
|
|
42
|
+
* [#1](https://github.com/ruby-grape/grape-swagger-representable/pull/1): Add autoload support - [@kzaitsev](https://github.com/kzaitsev).
|
|
43
|
+
|
|
44
|
+
### 0.1.0 (2016/05/11)
|
|
45
|
+
|
|
46
|
+
* Initial public release - [@kzaitsev](https://github.com/kzaitsev).
|
data/Dangerfile
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
# frozen_string_literal: true
|
|
2
|
+
|
|
3
|
+
danger.import_dangerfile(gem: 'danger-pr-comment')
|
|
4
|
+
|
|
5
|
+
if git.added_files.include?('CHANGELOG.md')
|
|
6
|
+
# Allow the initial changelog to document previously released versions.
|
|
7
|
+
changelog.check!(unreleased_heading: nil)
|
|
8
|
+
else
|
|
9
|
+
changelog.check!
|
|
10
|
+
end
|
data/Gemfile
CHANGED
|
@@ -5,4 +5,21 @@ source 'https://rubygems.org'
|
|
|
5
5
|
# Specify your gem's dependencies in grape-swagger-representable.gemspec
|
|
6
6
|
gemspec
|
|
7
7
|
|
|
8
|
-
gem 'grape
|
|
8
|
+
gem 'grape', ENV.fetch('GRAPE_VERSION', '>= 2.1')
|
|
9
|
+
gem 'grape-swagger', ENV.fetch('GRAPE_SWAGGER_VERSION', '>= 0')
|
|
10
|
+
gem 'json', '< 3' if Gem::Version.new(RUBY_VERSION) < Gem::Version.new('3.2')
|
|
11
|
+
gem 'multi_json'
|
|
12
|
+
gem 'pry'
|
|
13
|
+
gem 'rack-test'
|
|
14
|
+
gem 'rake'
|
|
15
|
+
gem 'representable', ENV.fetch('REPRESENTABLE_VERSION', '>= 0')
|
|
16
|
+
gem 'rspec', '~> 3.0'
|
|
17
|
+
gem 'rubocop'
|
|
18
|
+
gem 'simplecov', require: false
|
|
19
|
+
gem 'simplecov-lcov', require: false
|
|
20
|
+
|
|
21
|
+
group :danger do
|
|
22
|
+
gem 'danger', require: false
|
|
23
|
+
gem 'danger-changelog', require: false
|
|
24
|
+
gem 'danger-pr-comment', '~> 0.1.0', require: false
|
|
25
|
+
end
|
data/README.md
CHANGED
|
@@ -1,6 +1,9 @@
|
|
|
1
|
-
# GrapeSwagger::Representable
|
|
1
|
+
# GrapeSwagger::Representable
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
[](https://github.com/ruby-grape/grape-swagger-representable/actions/workflows/test.yml)
|
|
4
|
+
[](https://coveralls.io/github/ruby-grape/grape-swagger-representable?branch=master)
|
|
5
|
+
|
|
6
|
+
A [grape-swagger](https://github.com/ruby-grape/grape-swagger) adapter that documents [Representable](https://github.com/trailblazer/representable) decorators as Swagger response models.
|
|
4
7
|
|
|
5
8
|
## Installation
|
|
6
9
|
|
|
@@ -20,15 +23,24 @@ Or install it yourself as:
|
|
|
20
23
|
|
|
21
24
|
## Development
|
|
22
25
|
|
|
23
|
-
After checking out the repo, run `bin/setup` to install dependencies.
|
|
26
|
+
Requires Ruby 3.1 or newer, grape-swagger 2.x, and Representable 3.2 or newer within the 3.x series. After checking out the repo, run `bin/setup` to install dependencies. Run `bundle exec rake spec` for tests and `bundle exec rubocop` for lint. You can also run `bin/pry` for an interactive prompt.
|
|
27
|
+
|
|
28
|
+
GitHub Actions tests Ruby 3.1, 3.3, 3.4, and 4.0 across Grape 2, 3, and 4, including Representable 3.2 and the latest 3.x. Dependencies resolve from released gems rather than grape-swagger's development branch. Ruby 3.1 uses JSON 2.x for compatibility with its supported MultiJson versions.
|
|
29
|
+
|
|
30
|
+
To select dependencies locally, run, for example, `GRAPE_VERSION='~> 2.4' REPRESENTABLE_VERSION='~> 3.2.0' bundle update`, and set the same variables when running tests. `GRAPE_SWAGGER_VERSION` can select a particular supported grape-swagger release.
|
|
31
|
+
|
|
32
|
+
SimpleCov starts before loading the library and tracks all Ruby files under `lib/`. Local reports are written to `coverage/index.html`; CI uploads `coverage/lcov.info` to Coveralls using parallel matrix flags and a completion job.
|
|
24
33
|
|
|
25
|
-
To install this gem onto your local machine, run `bundle exec rake install`.
|
|
34
|
+
To install this gem onto your local machine, run `bundle exec rake install`. Follow [RELEASING.md](RELEASING.md) to prepare and publish a release.
|
|
26
35
|
|
|
27
36
|
## Contributing
|
|
28
37
|
|
|
29
|
-
Bug reports and pull requests are welcome on GitHub at https://github.com/
|
|
38
|
+
Bug reports and pull requests are welcome on GitHub at https://github.com/ruby-grape/grape-swagger-representable.
|
|
30
39
|
|
|
31
|
-
|
|
40
|
+
Add a pull request entry to the next release section of [CHANGELOG.md](CHANGELOG.md), including the PR link, a short description, and author attribution. Leave the `Your contribution here.` placeholder for the next contributor.
|
|
41
|
+
|
|
42
|
+
Danger checks changelog updates on pull requests. Its read-only workflow generates a report, and a separate workflow posts the report as a PR comment using GitHub's built-in token; no personal access token or repository secret is required.
|
|
32
43
|
|
|
33
|
-
|
|
44
|
+
## License
|
|
34
45
|
|
|
46
|
+
The gem is available as open source under the terms of the [MIT License](https://opensource.org/licenses/MIT).
|
data/RELEASING.md
ADDED
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
# Releasing Grape-Swagger-Representable
|
|
2
|
+
|
|
3
|
+
Publishing requires push access to the canonical repository, RubyGems ownership, and RubyGems multi-factor authentication.
|
|
4
|
+
|
|
5
|
+
## Prepare the release
|
|
6
|
+
|
|
7
|
+
Start with a clean checkout whose `origin` points to `ruby-grape/grape-swagger-representable`, not a fork:
|
|
8
|
+
|
|
9
|
+
```sh
|
|
10
|
+
git remote get-url origin
|
|
11
|
+
git switch master
|
|
12
|
+
git pull --ff-only origin master
|
|
13
|
+
git status --short
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
Set `GrapeSwagger::Representable::VERSION` in [lib/grape-swagger/representable/version.rb](lib/grape-swagger/representable/version.rb). Use a patch version for fixes and a minor version for new features or breaking changes while the gem is below 1.0.
|
|
17
|
+
|
|
18
|
+
Change the next-release heading in [CHANGELOG.md](CHANGELOG.md) to the release version and date, and remove `Your contribution here.`:
|
|
19
|
+
|
|
20
|
+
```markdown
|
|
21
|
+
### 0.3.0 (2026/10/27)
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
Review compatibility changes before publishing. Version 0.3.0 requires Ruby 3.1 or newer, grape-swagger 2.x, and Representable 3.2 or newer within the 3.x series.
|
|
25
|
+
|
|
26
|
+
Resolve dependencies if needed, then run lint and specs:
|
|
27
|
+
|
|
28
|
+
```sh
|
|
29
|
+
bundle install
|
|
30
|
+
bundle exec rubocop
|
|
31
|
+
bundle exec rake spec
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
Commit and push the release preparation normally:
|
|
35
|
+
|
|
36
|
+
```sh
|
|
37
|
+
git add CHANGELOG.md README.md RELEASING.md lib/grape-swagger/representable/version.rb
|
|
38
|
+
git commit -m "Prepare grape-swagger-representable 0.3.0"
|
|
39
|
+
git push origin master
|
|
40
|
+
```
|
|
41
|
+
|
|
42
|
+
Wait for the [test matrix](https://github.com/ruby-grape/grape-swagger-representable/actions/workflows/test.yml) and [RuboCop](https://github.com/ruby-grape/grape-swagger-representable/actions/workflows/rubocop.yml) to pass for that exact commit. Danger runs on pull requests, not direct release-preparation pushes to `master`.
|
|
43
|
+
|
|
44
|
+
## Publish
|
|
45
|
+
|
|
46
|
+
Confirm that the worktree is clean and that the version is not already published. Bundler's release task builds the gem, creates and pushes the version tag, and publishes to RubyGems:
|
|
47
|
+
|
|
48
|
+
```sh
|
|
49
|
+
bundle exec rake release
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
Supply a fresh RubyGems one-time password when requested. Never write credentials or one-time passwords to repository files. If publishing fails after pushing the tag, diagnose the failure and resume with `gem push pkg/grape-swagger-representable-0.3.0.gem`; do not move an existing release tag.
|
|
53
|
+
|
|
54
|
+
Verify the published gem's version and SHA256 against the local artifact, and confirm the remote tag points to the release commit:
|
|
55
|
+
|
|
56
|
+
```sh
|
|
57
|
+
gem specification pkg/grape-swagger-representable-0.3.0.gem version
|
|
58
|
+
shasum -a 256 pkg/grape-swagger-representable-0.3.0.gem
|
|
59
|
+
curl --fail https://rubygems.org/api/v2/rubygems/grape-swagger-representable/versions/0.3.0.json
|
|
60
|
+
git ls-remote origin 'refs/tags/v0.3.0*'
|
|
61
|
+
```
|
|
62
|
+
|
|
63
|
+
Create a non-draft GitHub release from that existing tag, using the matching changelog section for its notes:
|
|
64
|
+
|
|
65
|
+
```sh
|
|
66
|
+
gh release create v0.3.0 --repo ruby-grape/grape-swagger-representable \
|
|
67
|
+
--verify-tag --title "grape-swagger-representable 0.3.0" --notes-file /path/to/release-notes.txt
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
## Prepare the next development version
|
|
71
|
+
|
|
72
|
+
After confirming publication, bump the version to the next patch development iteration and add a fresh changelog section. For example, after 0.3.0, set the version to `0.3.1` and prepend:
|
|
73
|
+
|
|
74
|
+
```markdown
|
|
75
|
+
### 0.3.1 (Next)
|
|
76
|
+
|
|
77
|
+
* Your contribution here.
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
Commit the version and changelog changes, and push `master` normally. Never force-push `master`, overwrite a published gem, or move an existing release tag.
|
data/bin/pry
CHANGED
|
@@ -2,14 +2,10 @@
|
|
|
2
2
|
# frozen_string_literal: true
|
|
3
3
|
|
|
4
4
|
require 'bundler/setup'
|
|
5
|
-
|
|
5
|
+
require_relative '../lib/grape-swagger/representable'
|
|
6
6
|
|
|
7
7
|
# You can add fixtures and/or initialization code here to make experimenting
|
|
8
8
|
# with your gem easier. You can also use a different console, if you like.
|
|
9
9
|
|
|
10
|
-
# (If you use this, don't forget to add pry to your Gemfile!)
|
|
11
|
-
# require "pry"
|
|
12
|
-
# Pry.start
|
|
13
|
-
|
|
14
10
|
require 'pry'
|
|
15
11
|
Pry.start
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
$LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
|
5
|
-
require 'grape-swagger/representable/version'
|
|
3
|
+
require_relative 'lib/grape-swagger/representable/version'
|
|
6
4
|
|
|
7
5
|
Gem::Specification.new do |s|
|
|
8
6
|
s.name = 'grape-swagger-representable'
|
|
@@ -11,7 +9,6 @@ Gem::Specification.new do |s|
|
|
|
11
9
|
s.email = ['kirik910@gmail.com']
|
|
12
10
|
|
|
13
11
|
s.summary = 'Grape swagger adapter to support representable object parsing'
|
|
14
|
-
s.homepage = 'https://github.com/Bugagazavr/grape-swagger-representable'
|
|
15
12
|
s.license = 'MIT'
|
|
16
13
|
|
|
17
14
|
s.files = `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
|
|
@@ -19,18 +16,21 @@ Gem::Specification.new do |s|
|
|
|
19
16
|
s.executables = s.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
|
20
17
|
s.require_paths = ['lib']
|
|
21
18
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
s.
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
s.
|
|
19
|
+
github_uri = "https://github.com/ruby-grape/#{s.name}"
|
|
20
|
+
|
|
21
|
+
s.homepage = github_uri
|
|
22
|
+
|
|
23
|
+
s.metadata = {
|
|
24
|
+
'rubygems_mfa_required' => 'true',
|
|
25
|
+
'bug_tracker_uri' => "#{github_uri}/issues",
|
|
26
|
+
'changelog_uri' => "#{github_uri}/blob/master/CHANGELOG.md",
|
|
27
|
+
'documentation_uri' => "https://www.rubydoc.info/gems/#{s.name}/#{s.version}",
|
|
28
|
+
'homepage_uri' => s.homepage,
|
|
29
|
+
'source_code_uri' => github_uri
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
s.required_ruby_version = '>= 3.1'
|
|
33
|
+
|
|
34
|
+
s.add_dependency 'grape-swagger', '~> 2.0'
|
|
35
|
+
s.add_dependency 'representable', '~> 3.2'
|
|
36
36
|
end
|
|
@@ -3,8 +3,7 @@
|
|
|
3
3
|
module GrapeSwagger
|
|
4
4
|
module Representable
|
|
5
5
|
class Parser
|
|
6
|
-
attr_reader :model
|
|
7
|
-
attr_reader :endpoint
|
|
6
|
+
attr_reader :model, :endpoint
|
|
8
7
|
|
|
9
8
|
def initialize(model, endpoint)
|
|
10
9
|
@model = model
|
|
@@ -22,33 +21,19 @@ module GrapeSwagger
|
|
|
22
21
|
documentation = property[:documentation] ? property[:documentation].dup : {}
|
|
23
22
|
|
|
24
23
|
if property[:decorator] && property[:nested]
|
|
25
|
-
representer_mapping(
|
|
24
|
+
representer_mapping(
|
|
25
|
+
property[:decorator], documentation, property,
|
|
26
|
+
is_a_collection: is_a_collection, nested: property[:nested]
|
|
27
|
+
)
|
|
26
28
|
elsif property[:decorator]
|
|
27
|
-
representer_mapping(
|
|
29
|
+
representer_mapping(
|
|
30
|
+
property[:decorator], documentation, property,
|
|
31
|
+
is_a_collection: is_a_collection, is_a_decorator: true
|
|
32
|
+
)
|
|
28
33
|
elsif property[:nested]
|
|
29
|
-
representer_mapping(property[:nested], documentation, property, is_a_collection)
|
|
34
|
+
representer_mapping(property[:nested], documentation, property, is_a_collection: is_a_collection)
|
|
30
35
|
else
|
|
31
|
-
memo =
|
|
32
|
-
description: documentation[:desc] || property[:desc] || ''
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
data_type = GrapeSwagger::DocMethods::DataType.call(documentation[:type] || property[:type])
|
|
36
|
-
if GrapeSwagger::DocMethods::DataType.primitive?(data_type)
|
|
37
|
-
data = GrapeSwagger::DocMethods::DataType.mapping(data_type)
|
|
38
|
-
memo[:type] = data.first
|
|
39
|
-
memo[:format] = data.last
|
|
40
|
-
else
|
|
41
|
-
memo[:type] = data_type
|
|
42
|
-
end
|
|
43
|
-
|
|
44
|
-
default_value = documentation[:default] || property[:default] || nil
|
|
45
|
-
memo[:default] = default_value unless default_value.nil?
|
|
46
|
-
|
|
47
|
-
values = documentation[:values] || property[:values] || nil
|
|
48
|
-
memo[:enum] = values.is_a?(Proc) ? values.call : values if values
|
|
49
|
-
|
|
50
|
-
example = documentation[:example] || property[:example] || nil
|
|
51
|
-
memo[:example] = example.is_a?(Proc) ? example.call : example if example
|
|
36
|
+
memo = primitive_mapping(property, documentation)
|
|
52
37
|
|
|
53
38
|
if is_a_collection || documentation[:is_array]
|
|
54
39
|
memo = {
|
|
@@ -61,7 +46,31 @@ module GrapeSwagger
|
|
|
61
46
|
end
|
|
62
47
|
end
|
|
63
48
|
|
|
64
|
-
def
|
|
49
|
+
def primitive_mapping(property, documentation)
|
|
50
|
+
memo = { description: documentation[:desc] || property[:desc] || '' }
|
|
51
|
+
data_type = GrapeSwagger::DocMethods::DataType.call(documentation[:type] || property[:type])
|
|
52
|
+
if GrapeSwagger::DocMethods::DataType.primitive?(data_type)
|
|
53
|
+
data = GrapeSwagger::DocMethods::DataType.mapping(data_type)
|
|
54
|
+
memo[:type] = data.first
|
|
55
|
+
memo[:format] = data.last
|
|
56
|
+
else
|
|
57
|
+
memo[:type] = data_type
|
|
58
|
+
end
|
|
59
|
+
|
|
60
|
+
default_value = documentation[:default] || property[:default] || nil
|
|
61
|
+
memo[:default] = default_value unless default_value.nil?
|
|
62
|
+
|
|
63
|
+
values = documentation[:values] || property[:values] || nil
|
|
64
|
+
memo[:enum] = values.is_a?(Proc) ? values.call : values if values
|
|
65
|
+
|
|
66
|
+
example = documentation[:example] || property[:example] || nil
|
|
67
|
+
memo[:example] = example.is_a?(Proc) ? example.call : example if example
|
|
68
|
+
memo
|
|
69
|
+
end
|
|
70
|
+
|
|
71
|
+
def representer_mapping(
|
|
72
|
+
representer, documentation, property, is_a_collection: false, is_a_decorator: false, nested: nil
|
|
73
|
+
)
|
|
65
74
|
if nested.nil? && is_a_decorator
|
|
66
75
|
name = endpoint.send(:expose_params_from_model, representer)
|
|
67
76
|
|
|
@@ -105,13 +114,17 @@ module GrapeSwagger
|
|
|
105
114
|
properties = representer.map.each_with_object({}) do |value, property|
|
|
106
115
|
property_name = value[:as].try(:call) || value.name
|
|
107
116
|
hidden_property = value[:documentation]&.[](:hidden)
|
|
117
|
+
|
|
108
118
|
next if hidden_property && (hidden_property.is_a?(Proc) ? hidden_property.call : hidden_property)
|
|
119
|
+
|
|
109
120
|
property[property_name] = parse_representer_property(value)
|
|
110
121
|
end
|
|
111
122
|
|
|
112
|
-
required =
|
|
113
|
-
|
|
114
|
-
|
|
123
|
+
required =
|
|
124
|
+
representer
|
|
125
|
+
.map
|
|
126
|
+
.select { |value| value[:documentation] && value[:documentation][:required] }
|
|
127
|
+
.map { |value| value[:as] || value.name }
|
|
115
128
|
|
|
116
129
|
[properties, required]
|
|
117
130
|
end
|
|
@@ -125,15 +138,17 @@ module GrapeSwagger
|
|
|
125
138
|
|
|
126
139
|
overrided = (attributes.keys & nested_attributes.keys)
|
|
127
140
|
|
|
128
|
-
final_required =
|
|
129
|
-
|
|
130
|
-
|
|
141
|
+
final_required =
|
|
142
|
+
(required + nested_required)
|
|
143
|
+
.uniq
|
|
144
|
+
.select { |k| (overrided.include?(k) && nested_required.include?(k)) || !overrided.include?(k) }
|
|
131
145
|
|
|
132
146
|
[final_attributes, final_required]
|
|
133
147
|
end
|
|
134
148
|
|
|
135
149
|
def with_required(hash, required)
|
|
136
150
|
return hash if required.empty?
|
|
151
|
+
|
|
137
152
|
hash[:required] = required
|
|
138
153
|
hash
|
|
139
154
|
end
|
|
@@ -3,12 +3,12 @@
|
|
|
3
3
|
require 'grape-swagger'
|
|
4
4
|
require 'representable'
|
|
5
5
|
|
|
6
|
-
|
|
7
|
-
|
|
6
|
+
require_relative 'representable/version'
|
|
7
|
+
require_relative 'representable/parser'
|
|
8
8
|
|
|
9
9
|
module GrapeSwagger
|
|
10
10
|
module Representable
|
|
11
11
|
end
|
|
12
12
|
end
|
|
13
13
|
|
|
14
|
-
GrapeSwagger.model_parsers.register(
|
|
14
|
+
GrapeSwagger.model_parsers.register(GrapeSwagger::Representable::Parser, Representable::Decorator)
|
metadata
CHANGED
|
@@ -1,212 +1,64 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: grape-swagger-representable
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.
|
|
4
|
+
version: 0.3.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Kirill Zaitsev
|
|
8
|
-
autorequire:
|
|
9
8
|
bindir: exe
|
|
10
9
|
cert_chain: []
|
|
11
|
-
date:
|
|
10
|
+
date: 1980-01-02 00:00:00.000000000 Z
|
|
12
11
|
dependencies:
|
|
13
12
|
- !ruby/object:Gem::Dependency
|
|
14
13
|
name: grape-swagger
|
|
15
|
-
requirement: !ruby/object:Gem::Requirement
|
|
16
|
-
requirements:
|
|
17
|
-
- - ">="
|
|
18
|
-
- !ruby/object:Gem::Version
|
|
19
|
-
version: 0.31.0
|
|
20
|
-
type: :runtime
|
|
21
|
-
prerelease: false
|
|
22
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
23
|
-
requirements:
|
|
24
|
-
- - ">="
|
|
25
|
-
- !ruby/object:Gem::Version
|
|
26
|
-
version: 0.31.0
|
|
27
|
-
- !ruby/object:Gem::Dependency
|
|
28
|
-
name: representable
|
|
29
|
-
requirement: !ruby/object:Gem::Requirement
|
|
30
|
-
requirements:
|
|
31
|
-
- - ">="
|
|
32
|
-
- !ruby/object:Gem::Version
|
|
33
|
-
version: '0'
|
|
34
|
-
type: :runtime
|
|
35
|
-
prerelease: false
|
|
36
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
37
|
-
requirements:
|
|
38
|
-
- - ">="
|
|
39
|
-
- !ruby/object:Gem::Version
|
|
40
|
-
version: '0'
|
|
41
|
-
- !ruby/object:Gem::Dependency
|
|
42
|
-
name: bundler
|
|
43
14
|
requirement: !ruby/object:Gem::Requirement
|
|
44
15
|
requirements:
|
|
45
16
|
- - "~>"
|
|
46
17
|
- !ruby/object:Gem::Version
|
|
47
|
-
version: '
|
|
48
|
-
type: :
|
|
49
|
-
prerelease: false
|
|
50
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
51
|
-
requirements:
|
|
52
|
-
- - "~>"
|
|
53
|
-
- !ruby/object:Gem::Version
|
|
54
|
-
version: '1.12'
|
|
55
|
-
- !ruby/object:Gem::Dependency
|
|
56
|
-
name: multi_json
|
|
57
|
-
requirement: !ruby/object:Gem::Requirement
|
|
58
|
-
requirements:
|
|
59
|
-
- - ">="
|
|
60
|
-
- !ruby/object:Gem::Version
|
|
61
|
-
version: '0'
|
|
62
|
-
type: :development
|
|
63
|
-
prerelease: false
|
|
64
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
65
|
-
requirements:
|
|
66
|
-
- - ">="
|
|
67
|
-
- !ruby/object:Gem::Version
|
|
68
|
-
version: '0'
|
|
69
|
-
- !ruby/object:Gem::Dependency
|
|
70
|
-
name: pry
|
|
71
|
-
requirement: !ruby/object:Gem::Requirement
|
|
72
|
-
requirements:
|
|
73
|
-
- - ">="
|
|
74
|
-
- !ruby/object:Gem::Version
|
|
75
|
-
version: '0'
|
|
76
|
-
type: :development
|
|
77
|
-
prerelease: false
|
|
78
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
79
|
-
requirements:
|
|
80
|
-
- - ">="
|
|
81
|
-
- !ruby/object:Gem::Version
|
|
82
|
-
version: '0'
|
|
83
|
-
- !ruby/object:Gem::Dependency
|
|
84
|
-
name: pry-byebug
|
|
85
|
-
requirement: !ruby/object:Gem::Requirement
|
|
86
|
-
requirements:
|
|
87
|
-
- - ">="
|
|
88
|
-
- !ruby/object:Gem::Version
|
|
89
|
-
version: '0'
|
|
90
|
-
type: :development
|
|
91
|
-
prerelease: false
|
|
92
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
93
|
-
requirements:
|
|
94
|
-
- - ">="
|
|
95
|
-
- !ruby/object:Gem::Version
|
|
96
|
-
version: '0'
|
|
97
|
-
- !ruby/object:Gem::Dependency
|
|
98
|
-
name: rack-cors
|
|
99
|
-
requirement: !ruby/object:Gem::Requirement
|
|
100
|
-
requirements:
|
|
101
|
-
- - ">="
|
|
102
|
-
- !ruby/object:Gem::Version
|
|
103
|
-
version: '0'
|
|
104
|
-
type: :development
|
|
105
|
-
prerelease: false
|
|
106
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
107
|
-
requirements:
|
|
108
|
-
- - ">="
|
|
109
|
-
- !ruby/object:Gem::Version
|
|
110
|
-
version: '0'
|
|
111
|
-
- !ruby/object:Gem::Dependency
|
|
112
|
-
name: rack-test
|
|
113
|
-
requirement: !ruby/object:Gem::Requirement
|
|
114
|
-
requirements:
|
|
115
|
-
- - ">="
|
|
116
|
-
- !ruby/object:Gem::Version
|
|
117
|
-
version: '0'
|
|
118
|
-
type: :development
|
|
119
|
-
prerelease: false
|
|
120
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
121
|
-
requirements:
|
|
122
|
-
- - ">="
|
|
123
|
-
- !ruby/object:Gem::Version
|
|
124
|
-
version: '0'
|
|
125
|
-
- !ruby/object:Gem::Dependency
|
|
126
|
-
name: rake
|
|
127
|
-
requirement: !ruby/object:Gem::Requirement
|
|
128
|
-
requirements:
|
|
129
|
-
- - "~>"
|
|
130
|
-
- !ruby/object:Gem::Version
|
|
131
|
-
version: '10.0'
|
|
132
|
-
type: :development
|
|
18
|
+
version: '2.0'
|
|
19
|
+
type: :runtime
|
|
133
20
|
prerelease: false
|
|
134
21
|
version_requirements: !ruby/object:Gem::Requirement
|
|
135
22
|
requirements:
|
|
136
23
|
- - "~>"
|
|
137
24
|
- !ruby/object:Gem::Version
|
|
138
|
-
version: '
|
|
139
|
-
- !ruby/object:Gem::Dependency
|
|
140
|
-
name: redcarpet
|
|
141
|
-
requirement: !ruby/object:Gem::Requirement
|
|
142
|
-
requirements:
|
|
143
|
-
- - ">="
|
|
144
|
-
- !ruby/object:Gem::Version
|
|
145
|
-
version: '0'
|
|
146
|
-
type: :development
|
|
147
|
-
prerelease: false
|
|
148
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
149
|
-
requirements:
|
|
150
|
-
- - ">="
|
|
151
|
-
- !ruby/object:Gem::Version
|
|
152
|
-
version: '0'
|
|
153
|
-
- !ruby/object:Gem::Dependency
|
|
154
|
-
name: rouge
|
|
155
|
-
requirement: !ruby/object:Gem::Requirement
|
|
156
|
-
requirements:
|
|
157
|
-
- - ">="
|
|
158
|
-
- !ruby/object:Gem::Version
|
|
159
|
-
version: '0'
|
|
160
|
-
type: :development
|
|
161
|
-
prerelease: false
|
|
162
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
163
|
-
requirements:
|
|
164
|
-
- - ">="
|
|
165
|
-
- !ruby/object:Gem::Version
|
|
166
|
-
version: '0'
|
|
25
|
+
version: '2.0'
|
|
167
26
|
- !ruby/object:Gem::Dependency
|
|
168
|
-
name:
|
|
27
|
+
name: representable
|
|
169
28
|
requirement: !ruby/object:Gem::Requirement
|
|
170
29
|
requirements:
|
|
171
30
|
- - "~>"
|
|
172
31
|
- !ruby/object:Gem::Version
|
|
173
|
-
version: '3.
|
|
174
|
-
type: :
|
|
32
|
+
version: '3.2'
|
|
33
|
+
type: :runtime
|
|
175
34
|
prerelease: false
|
|
176
35
|
version_requirements: !ruby/object:Gem::Requirement
|
|
177
36
|
requirements:
|
|
178
37
|
- - "~>"
|
|
179
38
|
- !ruby/object:Gem::Version
|
|
180
|
-
version: '3.
|
|
181
|
-
- !ruby/object:Gem::Dependency
|
|
182
|
-
name: rubocop
|
|
183
|
-
requirement: !ruby/object:Gem::Requirement
|
|
184
|
-
requirements:
|
|
185
|
-
- - ">="
|
|
186
|
-
- !ruby/object:Gem::Version
|
|
187
|
-
version: '0'
|
|
188
|
-
type: :development
|
|
189
|
-
prerelease: false
|
|
190
|
-
version_requirements: !ruby/object:Gem::Requirement
|
|
191
|
-
requirements:
|
|
192
|
-
- - ">="
|
|
193
|
-
- !ruby/object:Gem::Version
|
|
194
|
-
version: '0'
|
|
195
|
-
description:
|
|
39
|
+
version: '3.2'
|
|
196
40
|
email:
|
|
197
41
|
- kirik910@gmail.com
|
|
198
42
|
executables: []
|
|
199
43
|
extensions: []
|
|
200
44
|
extra_rdoc_files: []
|
|
201
45
|
files:
|
|
46
|
+
- ".editorconfig"
|
|
47
|
+
- ".github/workflows/danger-comment.yml"
|
|
48
|
+
- ".github/workflows/danger.yml"
|
|
49
|
+
- ".github/workflows/rubocop.yml"
|
|
50
|
+
- ".github/workflows/test.yml"
|
|
202
51
|
- ".gitignore"
|
|
203
52
|
- ".rspec"
|
|
204
53
|
- ".rubocop.yml"
|
|
205
54
|
- ".rubocop_todo.yml"
|
|
206
|
-
- ".
|
|
55
|
+
- ".simplecov"
|
|
56
|
+
- CHANGELOG.md
|
|
57
|
+
- Dangerfile
|
|
207
58
|
- Gemfile
|
|
208
59
|
- LICENSE.txt
|
|
209
60
|
- README.md
|
|
61
|
+
- RELEASING.md
|
|
210
62
|
- Rakefile
|
|
211
63
|
- bin/pry
|
|
212
64
|
- bin/setup
|
|
@@ -215,11 +67,16 @@ files:
|
|
|
215
67
|
- lib/grape-swagger/representable.rb
|
|
216
68
|
- lib/grape-swagger/representable/parser.rb
|
|
217
69
|
- lib/grape-swagger/representable/version.rb
|
|
218
|
-
homepage: https://github.com/
|
|
70
|
+
homepage: https://github.com/ruby-grape/grape-swagger-representable
|
|
219
71
|
licenses:
|
|
220
72
|
- MIT
|
|
221
|
-
metadata:
|
|
222
|
-
|
|
73
|
+
metadata:
|
|
74
|
+
rubygems_mfa_required: 'true'
|
|
75
|
+
bug_tracker_uri: https://github.com/ruby-grape/grape-swagger-representable/issues
|
|
76
|
+
changelog_uri: https://github.com/ruby-grape/grape-swagger-representable/blob/master/CHANGELOG.md
|
|
77
|
+
documentation_uri: https://www.rubydoc.info/gems/grape-swagger-representable/0.3.0
|
|
78
|
+
homepage_uri: https://github.com/ruby-grape/grape-swagger-representable
|
|
79
|
+
source_code_uri: https://github.com/ruby-grape/grape-swagger-representable
|
|
223
80
|
rdoc_options: []
|
|
224
81
|
require_paths:
|
|
225
82
|
- lib
|
|
@@ -227,16 +84,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
227
84
|
requirements:
|
|
228
85
|
- - ">="
|
|
229
86
|
- !ruby/object:Gem::Version
|
|
230
|
-
version: '
|
|
87
|
+
version: '3.1'
|
|
231
88
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
232
89
|
requirements:
|
|
233
90
|
- - ">="
|
|
234
91
|
- !ruby/object:Gem::Version
|
|
235
92
|
version: '0'
|
|
236
93
|
requirements: []
|
|
237
|
-
|
|
238
|
-
rubygems_version: 2.5.2
|
|
239
|
-
signing_key:
|
|
94
|
+
rubygems_version: 4.0.20
|
|
240
95
|
specification_version: 4
|
|
241
96
|
summary: Grape swagger adapter to support representable object parsing
|
|
242
97
|
test_files: []
|
data/.travis.yml
DELETED
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
language: ruby
|
|
2
|
-
|
|
3
|
-
sudo: false
|
|
4
|
-
|
|
5
|
-
before_install:
|
|
6
|
-
- gem update --system
|
|
7
|
-
- gem install bundler
|
|
8
|
-
|
|
9
|
-
rvm:
|
|
10
|
-
- 2.4.2
|
|
11
|
-
- 2.3.5
|
|
12
|
-
|
|
13
|
-
matrix:
|
|
14
|
-
fast_finish: true
|
|
15
|
-
|
|
16
|
-
include:
|
|
17
|
-
- rvm: 2.2.8
|
|
18
|
-
env:
|
|
19
|
-
- rvm: ruby-head
|
|
20
|
-
env:
|
|
21
|
-
- rvm: jruby-head
|
|
22
|
-
env:
|
|
23
|
-
- rvm: rbx-2
|
|
24
|
-
env:
|
|
25
|
-
|
|
26
|
-
allow_failures:
|
|
27
|
-
- rvm: 2.2.8
|
|
28
|
-
- rvm: ruby-head
|
|
29
|
-
- rvm: jruby-head
|
|
30
|
-
- rvm: rbx-2
|