sealink-param-validation 0.1.0 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 9e5cff0982bbc8a5852373b1ee1f107a75622da013973e92015ebd911217240c
4
- data.tar.gz: af56f88956411b92e1e30381c7cf3df60472feb1aa9f790f612c679987b9c9e8
3
+ metadata.gz: edc5542fea9023a7fd7aeafb06d095877b4b18674f582a1785a89620fca2e2af
4
+ data.tar.gz: 550f414d93a5950c3337277c75235f3e3d2892e02b55b85b481810eacdc7cfa2
5
5
  SHA512:
6
- metadata.gz: fc3f83d5da4ba310fe3ec86b8aee1688ac23d7737cda3321da5a2d3629c37a00921d7a4cb687c3d80db9cf41d8683a8bcf6bbb2ef232c6bf1098b80f782094f7
7
- data.tar.gz: ed7ceff1bec538adbbf395ba916bff8970a9c62ef913b06466973ff1caa4395e12b0e11a01f53788c71d6e732797011bd5b97427778bc88174a24c1f3e1014fa
6
+ metadata.gz: 3c9aad9891daf132312064b199077134d4954221ce7b06a095bce7e6cd768efb8c8d96038d4bb74e6c481a12b2cbe66d0271adf5a16c50193ea2b175bd203583
7
+ data.tar.gz: cc3310148f010f19c6e250b3d49def857ab30a93726258d37546b683662f916556d10e171d7638b38ff305eeebffb5eb35c2b87818e5b2628d39ed13339c62f4
@@ -0,0 +1,6 @@
1
+ version: 2
2
+ updates:
3
+ - package-ecosystem: "bundler"
4
+ directory: "/"
5
+ schedule:
6
+ interval: "daily"
@@ -0,0 +1,59 @@
1
+ name: Release
2
+
3
+ on:
4
+ push:
5
+ tags:
6
+ - "v*"
7
+
8
+ jobs:
9
+ build:
10
+ name: Build
11
+ runs-on: ubuntu-latest
12
+ steps:
13
+ - name: Checkout
14
+ uses: actions/checkout@v2
15
+ - uses: ruby/setup-ruby@v1
16
+ with:
17
+ bundler-cache: true
18
+ - run: bundle exec rake
19
+
20
+ release:
21
+ needs: build
22
+ name: Release
23
+ runs-on: ubuntu-latest
24
+ steps:
25
+ - name: Checkout
26
+ uses: actions/checkout@v2
27
+
28
+ - name: Generate Changelog
29
+ run: |
30
+ # Get version from github ref (remove 'refs/tags/' and prefix 'v')
31
+ version="${GITHUB_REF#refs/tags/v}"
32
+ npx changelog-parser CHANGELOG.md | jq -cr ".versions | .[] | select(.version == \"$version\") | .body" > ${{ github.workflow }}-CHANGELOG.txt
33
+
34
+ - name: Release
35
+ uses: softprops/action-gh-release@v1
36
+ with:
37
+ body_path: ${{ github.workflow }}-CHANGELOG.txt
38
+ env:
39
+ GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
40
+
41
+ publish:
42
+ needs: [build, release]
43
+ name: Publish
44
+ runs-on: ubuntu-latest
45
+
46
+ steps:
47
+ - uses: actions/checkout@v2
48
+ - uses: ruby/setup-ruby@v1
49
+
50
+ - name: Publish to RubyGems
51
+ run: |
52
+ mkdir -p $HOME/.gem
53
+ touch $HOME/.gem/credentials
54
+ chmod 0600 $HOME/.gem/credentials
55
+ printf -- "---\n:rubygems_api_key: ${GEM_HOST_API_KEY}\n" > $HOME/.gem/credentials
56
+ gem build *.gemspec
57
+ gem push *.gem
58
+ env:
59
+ GEM_HOST_API_KEY: "${{secrets.RUBYGEMS_AUTH_TOKEN}}"
@@ -0,0 +1,19 @@
1
+ name: Build and Test
2
+ on: [push, pull_request]
3
+ jobs:
4
+ test:
5
+ strategy:
6
+ fail-fast: false
7
+ matrix:
8
+ gemfile: [rails60, rails61]
9
+ ruby: ["2.6", "2.7", "3.0"]
10
+ runs-on: ubuntu-latest
11
+ env:
12
+ BUNDLE_GEMFILE: gemfiles/${{ matrix.gemfile }}.gemfile
13
+ steps:
14
+ - uses: actions/checkout@v2
15
+ - uses: ruby/setup-ruby@v1
16
+ with:
17
+ ruby-version: ${{ matrix.ruby }}
18
+ bundler-cache: true
19
+ - run: bundle exec rake
data/.gitignore CHANGED
@@ -2,3 +2,4 @@ pkg
2
2
  coverage
3
3
  Gemfile.lock
4
4
  tmp
5
+ vendor
@@ -0,0 +1 @@
1
+ 3.0.0
@@ -1,5 +1,9 @@
1
1
  # Sealink Param Validation
2
2
 
3
+ ## 0.2.0
4
+
5
+ - [TT-8621] Update to build with github actions / ruby 3.0 / rails 6.1
6
+
3
7
  ## 0.1.0
4
8
 
5
9
  * [TT-6430] Extract our param validation from QuickTravel
data/README.md CHANGED
@@ -1,5 +1,8 @@
1
1
  # Sealink Param Validation
2
2
 
3
+ [![Gem Version](https://badge.fury.io/rb/sealink-param-validation.svg)](http://badge.fury.io/rb/sealink-param-validation)
4
+ [![Build Status](https://github.com/sealink/sealink-param-validation/workflows/Build%20and%20Test/badge.svg?branch=master)](https://github.com/sealink/sealink-param-validation/actions)
5
+
3
6
  This is our gem for validation our params with schemas.
4
7
 
5
8
  ## Development Environment
@@ -15,3 +18,15 @@ This is our gem for validation our params with schemas.
15
18
  ### Testing
16
19
 
17
20
  1. bundle exec rspec
21
+
22
+ ### Release
23
+
24
+ To publish a new version of this gem the following steps must be taken.
25
+
26
+ * Update the version in the following files
27
+ ```
28
+ CHANGELOG.md
29
+ lib/sealink_param_validation/version.rb
30
+ ````
31
+ * Create a tag using the format v0.1.0
32
+ * Follow build progress in GitHub actions
data/Rakefile CHANGED
@@ -1 +1,12 @@
1
1
  require "bundler/gem_tasks"
2
+
3
+ desc 'Default: run specs.'
4
+ task default: :spec
5
+
6
+ require 'rspec/core/rake_task'
7
+
8
+ desc "Run specs"
9
+ RSpec::Core::RakeTask.new do |t|
10
+ t.pattern = "./spec/**/*_spec.rb" # don't need this, it's default.
11
+ # Put spec opts in a file named .rspec in root
12
+ end
@@ -7,5 +7,5 @@ group :development, :test do
7
7
  gem 'rspec-rails'
8
8
  gem 'simplecov'
9
9
  gem 'simplecov-rcov'
10
- gem 'rails', '~> 5.0'
10
+ gem 'rails', '~> 6.1'
11
11
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module SealinkParamValidation
4
- VERSION = '0.1.0'
4
+ VERSION = '0.2.0'
5
5
  end
@@ -18,6 +18,7 @@ Gem::Specification.new do |spec|
18
18
  spec.files = `git ls-files`.split($/)
19
19
  spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
20
20
  spec.require_paths = ['lib']
21
+ spec.required_ruby_version = '>= 2.6.0'
21
22
 
22
23
  spec.add_dependency 'rails'
23
24
  spec.add_dependency 'dry-schema', '>= 1.0.0'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sealink-param-validation
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Sean Earle
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-12-03 00:00:00.000000000 Z
11
+ date: 2021-01-06 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -156,15 +156,18 @@ executables: []
156
156
  extensions: []
157
157
  extra_rdoc_files: []
158
158
  files:
159
+ - ".github/dependabot.yml"
160
+ - ".github/workflows/release.yml"
161
+ - ".github/workflows/ruby.yml"
159
162
  - ".gitignore"
160
- - ".travis.yml"
163
+ - ".ruby-version"
161
164
  - CHANGELOG.md
162
165
  - Gemfile
163
166
  - README.md
164
167
  - Rakefile
165
168
  - config/secrets.yml
166
- - gemfiles/rails5.gemfile
167
- - gemfiles/rails6.gemfile
169
+ - gemfiles/rails60.gemfile
170
+ - gemfiles/rails61.gemfile
168
171
  - lib/sealink-param-validation.rb
169
172
  - lib/sealink_param_validation/concern.rb
170
173
  - lib/sealink_param_validation/error.rb
@@ -186,14 +189,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
186
189
  requirements:
187
190
  - - ">="
188
191
  - !ruby/object:Gem::Version
189
- version: '0'
192
+ version: 2.6.0
190
193
  required_rubygems_version: !ruby/object:Gem::Requirement
191
194
  requirements:
192
195
  - - ">="
193
196
  - !ruby/object:Gem::Version
194
197
  version: '0'
195
198
  requirements: []
196
- rubygems_version: 3.0.3
199
+ rubygems_version: 3.2.3
197
200
  signing_key:
198
201
  specification_version: 4
199
202
  summary: This is some logic we want to use across many projects so we have extracted
@@ -1,13 +0,0 @@
1
- language: ruby
2
- rvm:
3
- - 2.6
4
- - ruby-head
5
- script: bundle exec rspec
6
- gemfile:
7
- - gemfiles/rails5.gemfile
8
- - gemfiles/rails6.gemfile
9
- notifications:
10
- email:
11
- - support@travellink.com.au
12
- sudo: false
13
- cache: bundler