hashid-rails 1.2.0 → 1.4.1

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
- SHA1:
3
- metadata.gz: 507694ba57b2e4a2bcdfa90869828753f0cb30d1
4
- data.tar.gz: 91496f73e9b29be5cb2a4c72693de1f60c545b08
2
+ SHA256:
3
+ metadata.gz: fd185250fd0af5aafc4c16778f0c75caa5a6d9e40e66a9f7cb4d80f72abbd695
4
+ data.tar.gz: 5cbf59b9d08b71d217b1fafac1259bc039997a7df1a71e0050df1b192e2a1b4a
5
5
  SHA512:
6
- metadata.gz: 661591b2767fae3adc5556e7e6c78fe912cbad133fedcd4266ee1d2317fc82cd29afe6fdf9d2870b2f4ce41d3f4e89fa7d56c0cc23ea5eed20c475eb96460006
7
- data.tar.gz: 01c86a260f13fa72a9a253175ff3728d583ee41a70fc2e1960546efe0f716994ef2c4c2b7abe59218745543c501542dcd2abf62f93e8b54fa037b32472eae0e1
6
+ metadata.gz: c8ee16a2e88d3efeca25e40e62215d95525e0f2e37428a3c6ae04bc19ff8977f1a8e48483ff4482467b43cf0cdc801bdacb12c9c6fe6790515633730b38e1661
7
+ data.tar.gz: 363076602dac93a35124cef3e5519a5e3544abdf97e35f8de67e245d04f213a0b4119b47cfe0cdb01cfcad17b2aebbc3cb8e08a9acce8e407661f583a19c4e9a
@@ -0,0 +1,51 @@
1
+ name: build
2
+
3
+ on: [push, pull_request]
4
+
5
+ jobs:
6
+ build:
7
+ name: Ruby ${{ matrix.ruby }} on Rails ${{ matrix.rails }}
8
+ runs-on: ubuntu-latest
9
+ strategy:
10
+ matrix:
11
+ ruby: ["2.5", "2.6"]
12
+ rails: ["4.2", "5.0", "5.1", "5.2", "6.0"]
13
+ include:
14
+ - ruby: "2.7"
15
+ rails: "6.0"
16
+
17
+ steps:
18
+ - uses: actions/checkout@v2
19
+
20
+ - name: Install Ruby (${{ matrix.ruby }})
21
+ uses: actions/setup-ruby@v1
22
+ with:
23
+ ruby-version: ${{ matrix.ruby }}
24
+
25
+ - name: Install SQLite
26
+ run: sudo apt install -y libsqlite3-dev
27
+
28
+ - name: Cache Ruby Gems
29
+ uses: actions/cache@v2
30
+ with:
31
+ path: vendor/bundle
32
+ key: ruby-${{ matrix.ruby }}-rails-${{ matrix.rails }}-gems-${{ hashFiles('hashid-rails.gemspec', 'Appraisals') }}
33
+ restore-keys: |
34
+ ruby-${{ matrix.ruby }}-rails-${{ matrix.rails }}-gems-
35
+
36
+ - name: Install Ruby dependencies
37
+ run: |
38
+ bundle config set path ../vendor/bundle
39
+ bundle install --gemfile gemfiles/rails_${{ matrix.rails }}.gemfile --jobs 4 --retry 3
40
+
41
+ - name: Test with RSpec
42
+ env:
43
+ BUNDLE_GEMFILE: gemfiles/rails_${{ matrix.rails }}.gemfile
44
+ run: bundle exec appraisal rails-${{ matrix.rails }} rspec
45
+
46
+ - name: Publish Test Coverage
47
+ uses: paambaati/codeclimate-action@v2.6.0
48
+ env:
49
+ CC_TEST_REPORTER_ID: 37aee70bb2e818f3bf4d2af88ea4a4355393901ba98b3876c244d42ed20fdbe1
50
+ with:
51
+ coverageCommand: true
data/.gitignore CHANGED
@@ -8,3 +8,4 @@
8
8
  /spec/reports/
9
9
  /tmp/
10
10
  /.ruby-version
11
+ *.gemfile.lock
@@ -1,10 +1,15 @@
1
- Style/StringLiterals:
2
- EnforcedStyle: double_quotes
3
- Style/IndentArray:
1
+ AllCops:
2
+ TargetRubyVersion: 2.3
3
+ Layout/IndentArray:
4
4
  EnforcedStyle: consistent
5
- Style/Documentation:
6
- Enabled: false
7
5
  Metrics/BlockLength:
8
6
  Exclude:
9
7
  - "*.gemspec"
10
8
  - "spec/**/*.rb"
9
+ Naming/PredicateName:
10
+ NameWhitelist:
11
+ - has_many
12
+ Style/Documentation:
13
+ Enabled: false
14
+ Style/StringLiterals:
15
+ EnforcedStyle: double_quotes
@@ -0,0 +1,23 @@
1
+ # frozen_string_literal: true
2
+
3
+ appraise "rails-4.2" do
4
+ gem "activerecord", "~> 4.2.0"
5
+ gem "sqlite3", "< 1.4"
6
+ end
7
+
8
+ appraise "rails-5.0" do
9
+ gem "activerecord", "~> 5.0.0"
10
+ gem "sqlite3", "< 1.4"
11
+ end
12
+
13
+ appraise "rails-5.1" do
14
+ gem "activerecord", "~> 5.1.0"
15
+ end
16
+
17
+ appraise "rails-5.2" do
18
+ gem "activerecord", "~> 5.2.0"
19
+ end
20
+
21
+ appraise "rails-6.0" do
22
+ gem "activerecord", "~> 6.0.0"
23
+ end
@@ -1,5 +1,28 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.4.1 (2020-08-09)
4
+
5
+ - Use ** splat operator to address deprecation warning in Ruby 2.7 ([#72](https://github.com/jcypret/hashid-rails/pull/72)) by [alexford](https://github.com/alexford)
6
+ - Use codeclimate-action to improve edge-case handling ([#73](https://github.com/jcypret/hashid-rails/pull/73))
7
+ - Add matrix testing for supported Ruby ([#74](https://github.com/jcypret/hashid-rails/pull/74)) and Rails ([#75](https://github.com/jcypret/hashid-rails/pull/75)) versions.
8
+
9
+ ## 1.4.0 (2019-10-30)
10
+ - Add support for disabling the overriding of `to_param` ([#68](https://github.com/jcypret/hashid-rails/pull/68))
11
+ - Fix exception raised when calling `hashid` on an model with a `nil` id
12
+ ([#63](https://github.com/jcypret/hashid-rails/pull/63)) by [fauxparse](https://github.com/fauxparse)
13
+
14
+ ## 1.3.0 (2019-10-29)
15
+ - Add support for model-level config ([#67](https://github.com/jcypret/hashid-rails/pull/67))
16
+
17
+ ## 1.2.2 (2018-07-29)
18
+ ### Fixed
19
+ - Handle exception raised when using a letter-only alphabet and attempting to
20
+ decode an integer ID from [@Drakula2k](https://github.com/Drakula2k) ([#54](https://github.com/jcypret/hashid-rails/pull/54)).
21
+
22
+ ## 1.2.1 (2018-01-13)
23
+ - Found issue where unsigned hashids with `find` did not fall back to passed in ID ([#46](https://github.com/jcypret/hashid-rails/pull/46)).
24
+ - Move finder specs to a shared example run against both the signed and unsigned hashids.
25
+
3
26
  ## 1.2.0 (2017-11-17)
4
27
  - Fix regression where `find_by_hashid` and `find_by_hashid!` attempt to decode
5
28
  values that are not hashids. ([#41](https://github.com/jcypret/hashid-rails/pull/41))
data/Gemfile CHANGED
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  source "https://rubygems.org"
2
4
 
3
5
  # Specify your gem's dependencies in hashid-rails.gemspec
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Hashid Rails
2
2
  [![Gem Version](https://badge.fury.io/rb/hashid-rails.svg)](https://badge.fury.io/rb/hashid-rails)
3
- [![Build Status](https://travis-ci.org/jcypret/hashid-rails.svg?branch=master)](https://travis-ci.org/jcypret/hashid-rails)
3
+ ![Build Status](https://github.com/jcypret/hashid-rails/workflows/build/badge.svg?branch=master)
4
4
  [![Code Climate](https://codeclimate.com/github/jcypret/hashid-rails/badges/gpa.svg)](https://codeclimate.com/github/jcypret/hashid-rails)
5
5
  [![Test Coverage](https://codeclimate.com/github/jcypret/hashid-rails/badges/coverage.svg)](https://codeclimate.com/github/jcypret/hashid-rails/coverage)
6
6
 
@@ -18,7 +18,7 @@ be added or removed at any time.
18
18
  Add this line to your application's Gemfile:
19
19
 
20
20
  ```ruby
21
- gem 'hashid-rails', '~> 1.0'
21
+ gem "hashid-rails", "~> 1.0"
22
22
  ```
23
23
 
24
24
  And then execute:
@@ -27,12 +27,6 @@ And then execute:
27
27
  $ bundle
28
28
  ```
29
29
 
30
- Or install it yourself as:
31
-
32
- ```shell
33
- $ gem install hashid-rails -v 1.0
34
- ```
35
-
36
30
  ## Basic Usage
37
31
 
38
32
  1. Include Hashid Rails in the ActiveRecord model you'd like to enable hashids.
@@ -60,7 +54,7 @@ model.hashid
60
54
  #=> "yLA6m0oM"
61
55
  ```
62
56
 
63
- Additionally, the `to_param` method is overriden to use hashid instead of id.
57
+ Additionally, the `to_param` method is overridden to use hashid instead of id.
64
58
  This means methods that take advantage of implicit ID will automatically work
65
59
  with hashids.
66
60
 
@@ -100,8 +94,9 @@ default options.
100
94
 
101
95
  ```ruby
102
96
  Hashid::Rails.configure do |config|
103
- # The salt to use for generating hashid. Prepended with table name.
97
+ # The salt to use for generating hashid. Prepended with pepper (table name).
104
98
  config.salt = ""
99
+ config.pepper = table_name
105
100
 
106
101
  # The minimum length of generated hashids
107
102
  config.min_hash_length = 6
@@ -114,11 +109,30 @@ Hashid::Rails.configure do |config|
114
109
  # Whether to override the `find` method
115
110
  config.override_find = true
116
111
 
112
+ # Whether to override the `to_param` method
113
+ config.override_to_param = true
114
+
117
115
  # Whether to sign hashids to prevent conflicts with regular IDs (see https://github.com/jcypret/hashid-rails/issues/30)
118
116
  config.sign_hashids = true
119
117
  end
120
118
  ```
121
119
 
120
+ ### Model-Level Config
121
+
122
+ You can also customize the hashid configuration at the model level.
123
+ `hashid_config` supports all the same options as the `Hashid::Rails.configure`
124
+ block and allows for each model to have a different config. This can be useful
125
+ for setting a custom salt/pepper. For instance, the pepper defaults to the table
126
+ name, so if you rename the table, you can keep the same hashids by setting the
127
+ pepper to the old table name.
128
+
129
+ ```ruby
130
+ class Model < ActiveRecord::Base
131
+ include Hashid::Rails
132
+ hashid_config pepper: "old_table_name"
133
+ end
134
+ ```
135
+
122
136
  ## Upgrading from Pre-1.0
123
137
 
124
138
  The 1.0 release of this gem introduced hashid signing to prevent
@@ -153,3 +167,6 @@ and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
153
167
  3. Commit your changes (`git commit -am 'Add some feature'`)
154
168
  4. Push to the branch (`git push origin my-new-feature`)
155
169
  5. Create a new Pull Request
170
+
171
+ > NOTE: If it's a significant feature or change, consider creating an Issue for
172
+ > discussion before opening a PR.
data/Rakefile CHANGED
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require "bundler/gem_tasks"
2
4
  require "rspec/core/rake_task"
3
5
 
@@ -1,4 +1,5 @@
1
1
  #!/usr/bin/env ruby
2
+ # frozen_string_literal: true
2
3
 
3
4
  require "bundler/setup"
4
5
  require "hashid/rails"
@@ -0,0 +1,8 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "activerecord", "~> 4.2.0"
6
+ gem "sqlite3", "< 1.4"
7
+
8
+ gemspec path: "../"
@@ -0,0 +1,8 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "activerecord", "~> 5.0.0"
6
+ gem "sqlite3", "< 1.4"
7
+
8
+ gemspec path: "../"
@@ -0,0 +1,7 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "activerecord", "~> 5.1.0"
6
+
7
+ gemspec path: "../"
@@ -0,0 +1,7 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "activerecord", "~> 5.2.0"
6
+
7
+ gemspec path: "../"
@@ -0,0 +1,7 @@
1
+ # This file was generated by Appraisal
2
+
3
+ source "https://rubygems.org"
4
+
5
+ gem "activerecord", "~> 6.0.0"
6
+
7
+ gemspec path: "../"
@@ -1,4 +1,5 @@
1
- # coding: utf-8
1
+ # frozen_string_literal: true
2
+
2
3
  lib = File.expand_path("../lib", __FILE__)
3
4
  $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
5
  require "hashid/rails/version"
@@ -10,13 +11,13 @@ Gem::Specification.new do |spec|
10
11
  spec.email = ["jcypret@gmail.com"]
11
12
 
12
13
  spec.summary = "Use Hashids in your Rails app models."
13
- spec.description = <<-EOM
14
+ spec.description = <<-DESCRIPTION
14
15
  This gem allows you to easily use [Hashids](http://hashids.org/ruby/)
15
16
  in your Rails app. Instead of your models using sequential numbers like 1,
16
17
  2, 3, they will instead have unique short hashes like "yLA6m0oM",
17
18
  "5bAyD0LO", and "wz3MZ49l". The database will still use integers under
18
19
  the hood, so this gem can be added or removed at any time.
19
- EOM
20
+ DESCRIPTION
20
21
  spec.homepage = "https://github.com/jcypret/hashid-rails"
21
22
  spec.license = "MIT"
22
23
 
@@ -27,13 +28,14 @@ Gem::Specification.new do |spec|
27
28
  spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
28
29
  spec.require_paths = ["lib"]
29
30
 
31
+ spec.add_development_dependency "appraisal"
30
32
  spec.add_development_dependency "bundler"
33
+ spec.add_development_dependency "byebug"
31
34
  spec.add_development_dependency "rake"
32
35
  spec.add_development_dependency "rspec", "~> 3.4.0"
33
- spec.add_development_dependency "codeclimate-test-reporter", "~> 1.0.0"
34
- spec.add_development_dependency "sqlite3"
35
36
  spec.add_development_dependency "rubocop"
36
- spec.add_development_dependency "byebug"
37
+ spec.add_development_dependency "simplecov", "~> 0.17.1"
38
+ spec.add_development_dependency "sqlite3"
37
39
 
38
40
  spec.add_runtime_dependency "activerecord", ">= 4.0"
39
41
  spec.add_runtime_dependency "hashids", "~> 1.0"
@@ -1,3 +1,5 @@
1
+ # frozen_string_literal: true
2
+
1
3
  require "hashid/rails/version"
2
4
  require "hashid/rails/configuration"
3
5
  require "hashids"
@@ -31,17 +33,37 @@ module Hashid
31
33
  def hashid
32
34
  self.class.encode_id(id)
33
35
  end
34
- alias to_param hashid
36
+
37
+ def to_param
38
+ self.class.hashid_configuration.override_to_param ? hashid : super
39
+ end
35
40
 
36
41
  module ClassMethods
42
+ def hashid_config(options = {})
43
+ config = Hashid::Rails.configuration.dup
44
+ config.pepper = table_name
45
+ options.each do |attr, value|
46
+ config.public_send("#{attr}=", value)
47
+ end
48
+ @hashid_configuration = config
49
+ end
50
+
51
+ def hashid_configuration
52
+ @hashid_configuration || hashid_config
53
+ end
54
+
55
+ def reset_hashid_config
56
+ @hashid_configuration = nil
57
+ end
58
+
37
59
  def relation
38
60
  super.tap { |r| r.extend ClassMethods }
39
61
  end
40
62
 
41
- def has_many(*args, &block) # rubocop:disable Style/PredicateName
63
+ def has_many(*args, &block)
42
64
  options = args.extract_options!
43
65
  options[:extend] = Array(options[:extend]).push(ClassMethods)
44
- super(*args, options, &block)
66
+ super(*args, **options, &block)
45
67
  end
46
68
 
47
69
  def encode_id(ids)
@@ -69,7 +91,7 @@ module Hashid
69
91
  uniq_ids = ids.flatten.compact.uniq
70
92
  uniq_ids = uniq_ids.first unless expects_array || uniq_ids.size > 1
71
93
 
72
- if Hashid::Rails.configuration.override_find
94
+ if hashid_configuration.override_find
73
95
  super(decode_id(uniq_ids, fallback: true))
74
96
  else
75
97
  super
@@ -87,11 +109,13 @@ module Hashid
87
109
  private
88
110
 
89
111
  def hashids
90
- Hashids.new(*Hashid::Rails.configuration.for_table(table_name))
112
+ Hashids.new(*hashid_configuration.to_args)
91
113
  end
92
114
 
93
115
  def hashid_encode(id)
94
- if Hashid::Rails.configuration.sign_hashids
116
+ return nil if id.nil?
117
+
118
+ if hashid_configuration.sign_hashids
95
119
  hashids.encode(HASHID_TOKEN, id)
96
120
  else
97
121
  hashids.encode(id)
@@ -99,14 +123,16 @@ module Hashid
99
123
  end
100
124
 
101
125
  def hashid_decode(id, fallback:)
102
- decoded_hashid = hashids.decode(id.to_s)
103
126
  fallback_value = fallback ? id : nil
127
+ decoded_hashid = hashids.decode(id.to_s)
104
128
 
105
- if Hashid::Rails.configuration.sign_hashids
129
+ if hashid_configuration.sign_hashids
106
130
  valid_hashid?(decoded_hashid) ? decoded_hashid.last : fallback_value
107
131
  else
108
- decoded_hashid.first
132
+ decoded_hashid.first || fallback_value
109
133
  end
134
+ rescue Hashids::InputError
135
+ fallback_value
110
136
  end
111
137
 
112
138
  def valid_hashid?(decoded_hashid)
@@ -1,24 +1,30 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module Hashid
2
4
  module Rails
3
5
  class Configuration
4
6
  attr_accessor :salt,
7
+ :pepper,
5
8
  :min_hash_length,
6
9
  :alphabet,
7
10
  :override_find,
11
+ :override_to_param,
8
12
  :sign_hashids
9
13
 
10
14
  def initialize
11
15
  @salt = ""
16
+ @pepper = ""
12
17
  @min_hash_length = 6
13
18
  @alphabet = "abcdefghijklmnopqrstuvwxyz" \
14
19
  "ABCDEFGHIJKLMNOPQRSTUVWXYZ" \
15
20
  "1234567890"
16
21
  @override_find = true
22
+ @override_to_param = true
17
23
  @sign_hashids = true
18
24
  end
19
25
 
20
- def for_table(table_name)
21
- ["#{table_name}#{salt}", min_hash_length, alphabet]
26
+ def to_args
27
+ ["#{pepper}#{salt}", min_hash_length, alphabet]
22
28
  end
23
29
  end
24
30
  end
@@ -1,5 +1,7 @@
1
+ # frozen_string_literal: true
2
+
1
3
  module Hashid
2
4
  module Rails
3
- VERSION = "1.2.0".freeze
5
+ VERSION = "1.4.1"
4
6
  end
5
7
  end
metadata CHANGED
@@ -1,15 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hashid-rails
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0
4
+ version: 1.4.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Justin Cypret
8
- autorequire:
8
+ autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2017-11-18 00:00:00.000000000 Z
11
+ date: 2020-08-10 00:00:00.000000000 Z
12
12
  dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: appraisal
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: '0'
20
+ type: :development
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: '0'
13
27
  - !ruby/object:Gem::Dependency
14
28
  name: bundler
15
29
  requirement: !ruby/object:Gem::Requirement
@@ -25,7 +39,7 @@ dependencies:
25
39
  - !ruby/object:Gem::Version
26
40
  version: '0'
27
41
  - !ruby/object:Gem::Dependency
28
- name: rake
42
+ name: byebug
29
43
  requirement: !ruby/object:Gem::Requirement
30
44
  requirements:
31
45
  - - ">="
@@ -39,35 +53,35 @@ dependencies:
39
53
  - !ruby/object:Gem::Version
40
54
  version: '0'
41
55
  - !ruby/object:Gem::Dependency
42
- name: rspec
56
+ name: rake
43
57
  requirement: !ruby/object:Gem::Requirement
44
58
  requirements:
45
- - - "~>"
59
+ - - ">="
46
60
  - !ruby/object:Gem::Version
47
- version: 3.4.0
61
+ version: '0'
48
62
  type: :development
49
63
  prerelease: false
50
64
  version_requirements: !ruby/object:Gem::Requirement
51
65
  requirements:
52
- - - "~>"
66
+ - - ">="
53
67
  - !ruby/object:Gem::Version
54
- version: 3.4.0
68
+ version: '0'
55
69
  - !ruby/object:Gem::Dependency
56
- name: codeclimate-test-reporter
70
+ name: rspec
57
71
  requirement: !ruby/object:Gem::Requirement
58
72
  requirements:
59
73
  - - "~>"
60
74
  - !ruby/object:Gem::Version
61
- version: 1.0.0
75
+ version: 3.4.0
62
76
  type: :development
63
77
  prerelease: false
64
78
  version_requirements: !ruby/object:Gem::Requirement
65
79
  requirements:
66
80
  - - "~>"
67
81
  - !ruby/object:Gem::Version
68
- version: 1.0.0
82
+ version: 3.4.0
69
83
  - !ruby/object:Gem::Dependency
70
- name: sqlite3
84
+ name: rubocop
71
85
  requirement: !ruby/object:Gem::Requirement
72
86
  requirements:
73
87
  - - ">="
@@ -81,21 +95,21 @@ dependencies:
81
95
  - !ruby/object:Gem::Version
82
96
  version: '0'
83
97
  - !ruby/object:Gem::Dependency
84
- name: rubocop
98
+ name: simplecov
85
99
  requirement: !ruby/object:Gem::Requirement
86
100
  requirements:
87
- - - ">="
101
+ - - "~>"
88
102
  - !ruby/object:Gem::Version
89
- version: '0'
103
+ version: 0.17.1
90
104
  type: :development
91
105
  prerelease: false
92
106
  version_requirements: !ruby/object:Gem::Requirement
93
107
  requirements:
94
- - - ">="
108
+ - - "~>"
95
109
  - !ruby/object:Gem::Version
96
- version: '0'
110
+ version: 0.17.1
97
111
  - !ruby/object:Gem::Dependency
98
- name: byebug
112
+ name: sqlite3
99
113
  requirement: !ruby/object:Gem::Requirement
100
114
  requirements:
101
115
  - - ">="
@@ -148,10 +162,11 @@ executables: []
148
162
  extensions: []
149
163
  extra_rdoc_files: []
150
164
  files:
165
+ - ".github/workflows/ruby.yml"
151
166
  - ".gitignore"
152
167
  - ".rspec"
153
168
  - ".rubocop.yml"
154
- - ".travis.yml"
169
+ - Appraisals
155
170
  - CHANGELOG.md
156
171
  - Gemfile
157
172
  - LICENSE.txt
@@ -159,6 +174,11 @@ files:
159
174
  - Rakefile
160
175
  - bin/console
161
176
  - bin/setup
177
+ - gemfiles/rails_4.2.gemfile
178
+ - gemfiles/rails_5.0.gemfile
179
+ - gemfiles/rails_5.1.gemfile
180
+ - gemfiles/rails_5.2.gemfile
181
+ - gemfiles/rails_6.0.gemfile
162
182
  - hashid-rails.gemspec
163
183
  - lib/hashid/rails.rb
164
184
  - lib/hashid/rails/configuration.rb
@@ -167,7 +187,7 @@ homepage: https://github.com/jcypret/hashid-rails
167
187
  licenses:
168
188
  - MIT
169
189
  metadata: {}
170
- post_install_message:
190
+ post_install_message:
171
191
  rdoc_options: []
172
192
  require_paths:
173
193
  - lib
@@ -182,9 +202,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
182
202
  - !ruby/object:Gem::Version
183
203
  version: '0'
184
204
  requirements: []
185
- rubyforge_project:
186
- rubygems_version: 2.5.2
187
- signing_key:
205
+ rubygems_version: 3.0.3
206
+ signing_key:
188
207
  specification_version: 4
189
208
  summary: Use Hashids in your Rails app models.
190
209
  test_files: []
@@ -1,9 +0,0 @@
1
- language: ruby
2
- cache: bundler
3
- rvm:
4
- - 2.3.0
5
- addons:
6
- code_climate:
7
- repo_token: 37aee70bb2e818f3bf4d2af88ea4a4355393901ba98b3876c244d42ed20fdbe1
8
- after_success:
9
- - bundle exec codeclimate-test-reporter