active_record_bitmask 1.0.0 → 3.0.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 624a3dadb88c65c2c87d3c4f3054b8e20d6b32d370df053e1d496ad1081fbb13
4
- data.tar.gz: 3fe828937fc5bb799e6e250d8d96248708825262df7ad1e8ee61d80d4d000b04
3
+ metadata.gz: 57258a4ca23b07d8e032b96d7b83e298cf70a9265dab6ef7f0305febbe959611
4
+ data.tar.gz: 8644af5ecd397870659de7603f8ee3debdb631554291f8e587b2ac3310fa4a5b
5
5
  SHA512:
6
- metadata.gz: c914453a693e29f98eb756956a33ddc2f2373cce35820863a1827531658a83bc902b5c8344e0561b1db7069f57da4e3500ce323450c7c9eb18e7410601d96817
7
- data.tar.gz: 24d72c973b8ed34f8017caa999b132d81a105fb679844054588196e4ae3b9545e93c8ba55de4fe1177df8632460daed6a4d10fe71aca8b100ca4afb638ac1d35
6
+ metadata.gz: 3a6c0be3db4553d19ba934b5e0d5c65d3cd4a5024108fe67c22d5b6434d63a0eb6d609d5ac14c39522213e40be8535c27f2f3f17dba0dc39259d3ae45490622e
7
+ data.tar.gz: 3552ba175b6ef839eb4d444d39ed84d053100d82f5a4720efcf4e23159eaf4f44a3981829e608ce1bda8360b6ec30429eecd7646733be96f76a903f5aebc6dfe
@@ -14,10 +14,10 @@ jobs:
14
14
  runs-on: ubuntu-latest
15
15
  strategy:
16
16
  matrix:
17
- ruby-version: ['3.1', '3.2']
17
+ ruby-version: ['3.1', '3.2', '3.3']
18
18
 
19
19
  steps:
20
- - uses: actions/checkout@v3
20
+ - uses: actions/checkout@v4
21
21
  - name: Set up Ruby
22
22
  uses: ruby/setup-ruby@v1
23
23
  with:
@@ -30,21 +30,15 @@ jobs:
30
30
  runs-on: ubuntu-latest
31
31
  strategy:
32
32
  matrix:
33
- gemfile: ['6.0_stable', '6.1_stable', '7.0_stable']
34
- ruby-version: ['2.5', '2.6', '2.7', '3.0', '3.1', '3.2']
33
+ gemfile: ['7.0_stable', '7.1_stable', '7.2_stable', '8.0_stable']
34
+ ruby-version: ['3.1', '3.2', '3.3']
35
35
  exclude:
36
- - ruby-version: '3.2'
37
- gemfile: '6.0_stable'
38
36
  - ruby-version: '3.1'
39
- gemfile: '6.0_stable'
40
- - ruby-version: '2.5'
41
- gemfile: '7.0_stable'
42
- - ruby-version: '2.6'
43
- gemfile: '7.0_stable'
37
+ gemfile: '8.0_stable'
44
38
  env:
45
39
  BUNDLE_GEMFILE: ${{ github.workspace }}/gemfiles/${{ matrix.gemfile }}.gemfile
46
40
  steps:
47
- - uses: actions/checkout@v3
41
+ - uses: actions/checkout@v4
48
42
  - name: Set up Ruby
49
43
  uses: ruby/setup-ruby@v1
50
44
  with:
data/.rubocop.yml CHANGED
@@ -13,7 +13,7 @@ AllCops:
13
13
  - 'vendor/**/*'
14
14
  - 'gemfiles/**/*'
15
15
  - Gemfile
16
- TargetRubyVersion: 2.5
16
+ TargetRubyVersion: 3.1
17
17
  DisplayCopNames: true
18
18
 
19
19
  Bundler:
data/Appraisals CHANGED
@@ -1,13 +1,19 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- appraise '6.0-stable' do
4
- gem 'activerecord', '~> 6.0.0'
3
+ appraise '7.0-stable' do
4
+ gem 'activerecord', '~> 7.0.0'
5
+ gem 'sqlite3', '~> 1.7.0'
5
6
  end
6
7
 
7
- appraise '6.1-stable' do
8
- gem 'activerecord', '~> 6.1.0'
8
+ appraise '7.1-stable' do
9
+ gem 'activerecord', '~> 7.1.0'
10
+ gem 'sqlite3', '~> 1.7.0'
9
11
  end
10
12
 
11
- appraise '7.0-stable' do
12
- gem 'activerecord', '~> 7.0.0'
13
+ appraise '7.2-stable' do
14
+ gem 'activerecord', '~> 7.2.0'
15
+ end
16
+
17
+ appraise '8.0-stable' do
18
+ gem 'activerecord', '~> 8.0.0'
13
19
  end
data/CHANGELOG.md CHANGED
@@ -1,4 +1,12 @@
1
- ## Next Version
1
+ ## 3.0.0
2
+
3
+ * **Breaking Changes** Rails 6.1 is no longer supported. #30
4
+ * Support Rails 8.0.0 #30
5
+
6
+ ## 2.0.0
7
+
8
+ * **Breaking Changes** Rails 6.0 is no longer supported. #28
9
+ * Support Rails 7.2.0 #27
2
10
 
3
11
  ## 1.0.0
4
12
 
@@ -14,7 +14,7 @@ Gem::Specification.new do |spec|
14
14
  spec.summary = 'Simple bitmask attribute support for ActiveRecord'
15
15
  spec.homepage = 'https://github.com/alpaca-tc/active_record_bitmask'
16
16
 
17
- spec.required_ruby_version = '>= 2.5.0'
17
+ spec.required_ruby_version = '>= 3.1.0'
18
18
 
19
19
  spec.metadata = {
20
20
  'homepage_uri' => 'https://github.com/alpaca-tc/active_record_bitmask',
@@ -28,5 +28,5 @@ Gem::Specification.new do |spec|
28
28
  end
29
29
  spec.require_paths = ['lib']
30
30
 
31
- spec.add_dependency 'activerecord', '>= 6.0'
31
+ spec.add_dependency 'activerecord', '>= 7.0'
32
32
  end
@@ -7,7 +7,7 @@ gem "rubocop", "1.28.2"
7
7
  gem "appraisal"
8
8
  gem "rake"
9
9
  gem "rspec"
10
- gem "sqlite3"
10
+ gem "sqlite3", "~> 1.7.0"
11
11
  gem "activerecord", "~> 7.0.0"
12
12
 
13
13
  gemspec path: "../"
@@ -3,11 +3,11 @@
3
3
  source "https://rubygems.org"
4
4
 
5
5
  gem "pry"
6
- gem "rubocop", "0.86.0"
6
+ gem "rubocop", "1.28.2"
7
7
  gem "appraisal"
8
8
  gem "rake"
9
9
  gem "rspec"
10
- gem "sqlite3"
11
- gem "activerecord", "~> 5.1.0"
10
+ gem "sqlite3", "~> 1.7.0"
11
+ gem "activerecord", "~> 7.1.0"
12
12
 
13
13
  gemspec path: "../"
@@ -8,6 +8,6 @@ gem "appraisal"
8
8
  gem "rake"
9
9
  gem "rspec"
10
10
  gem "sqlite3"
11
- gem "activerecord", "~> 6.1.0"
11
+ gem "activerecord", "~> 7.2.0"
12
12
 
13
13
  gemspec path: "../"
@@ -8,6 +8,6 @@ gem "appraisal"
8
8
  gem "rake"
9
9
  gem "rspec"
10
10
  gem "sqlite3"
11
- gem "activerecord", "~> 6.0.0"
11
+ gem "activerecord", "~> 8.0.0"
12
12
 
13
13
  gemspec path: "../"
@@ -51,19 +51,14 @@ module ActiveRecordBitmask
51
51
  private
52
52
 
53
53
  def define_bitmask_attribute(attribute, map)
54
- if ActiveRecord.gem_version >= Gem::Version.new('7.0.0.alpha1')
55
- # Greater than or equal to 7.0.0
56
- attribute(attribute) do |subtype|
57
- ActiveRecordBitmask::BitmaskType.new(attribute, map, subtype)
58
- end
59
- elsif ActiveRecord.gem_version >= Gem::Version.new('6.1.0')
60
- # Equal to 6.1.0
61
- decorate_attribute_type(attribute) do |subtype|
62
- ActiveRecordBitmask::BitmaskType.new(attribute, map, subtype)
54
+ if ActiveRecord.gem_version >= Gem::Version.new('7.2.0')
55
+ # Greater than or equal to 7.2.0
56
+ decorate_attributes([attribute]) do |name, subtype|
57
+ ActiveRecordBitmask::BitmaskType.new(name, map, subtype)
63
58
  end
64
59
  else
65
- # Less than 6.1.0
66
- decorate_attribute_type(attribute, :bitmask) do |subtype|
60
+ # Greater than or equal to 7.0.0
61
+ attribute(attribute) do |subtype|
67
62
  ActiveRecordBitmask::BitmaskType.new(attribute, map, subtype)
68
63
  end
69
64
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module ActiveRecordBitmask
4
- VERSION = '1.0.0'
4
+ VERSION = '3.0.0'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: active_record_bitmask
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 3.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - alpaca-tc
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-01-18 00:00:00.000000000 Z
11
+ date: 2024-11-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activerecord
@@ -16,14 +16,14 @@ dependencies:
16
16
  requirements:
17
17
  - - ">="
18
18
  - !ruby/object:Gem::Version
19
- version: '6.0'
19
+ version: '7.0'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
24
  - - ">="
25
25
  - !ruby/object:Gem::Version
26
- version: '6.0'
26
+ version: '7.0'
27
27
  description:
28
28
  email:
29
29
  - alpaca-tc@alpaca.tc
@@ -41,12 +41,10 @@ files:
41
41
  - README.md
42
42
  - Rakefile
43
43
  - active_record_bitmask.gemspec
44
- - gemfiles/5.0_stable.gemfile
45
- - gemfiles/5.1_stable.gemfile
46
- - gemfiles/5.2_stable.gemfile
47
- - gemfiles/6.0_stable.gemfile
48
- - gemfiles/6.1_stable.gemfile
49
44
  - gemfiles/7.0_stable.gemfile
45
+ - gemfiles/7.1_stable.gemfile
46
+ - gemfiles/7.2_stable.gemfile
47
+ - gemfiles/8.0_stable.gemfile
50
48
  - lib/active_record_bitmask.rb
51
49
  - lib/active_record_bitmask/attribute_methods.rb
52
50
  - lib/active_record_bitmask/attribute_methods/query.rb
@@ -70,14 +68,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
70
68
  requirements:
71
69
  - - ">="
72
70
  - !ruby/object:Gem::Version
73
- version: 2.5.0
71
+ version: 3.1.0
74
72
  required_rubygems_version: !ruby/object:Gem::Requirement
75
73
  requirements:
76
74
  - - ">="
77
75
  - !ruby/object:Gem::Version
78
76
  version: '0'
79
77
  requirements: []
80
- rubygems_version: 3.4.1
78
+ rubygems_version: 3.5.16
81
79
  signing_key:
82
80
  specification_version: 4
83
81
  summary: Simple bitmask attribute support for ActiveRecord
@@ -1,13 +0,0 @@
1
- # This file was generated by Appraisal
2
-
3
- source "https://rubygems.org"
4
-
5
- gem "pry"
6
- gem "rubocop", "0.86.0"
7
- gem "appraisal"
8
- gem "rake"
9
- gem "rspec"
10
- gem "sqlite3", "~> 1.3.6"
11
- gem "activerecord", "~> 5.0.0"
12
-
13
- gemspec path: "../"
@@ -1,13 +0,0 @@
1
- # This file was generated by Appraisal
2
-
3
- source "https://rubygems.org"
4
-
5
- gem "pry"
6
- gem "rubocop", "0.86.0"
7
- gem "appraisal"
8
- gem "rake"
9
- gem "rspec"
10
- gem "sqlite3"
11
- gem "activerecord", "~> 5.2.0"
12
-
13
- gemspec path: "../"