arturo 3.0.2.pre.2 → 4.0.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: 5af32fa5bd93a762cb57e3da2899776f6aaddf83e7dff2ff960c7a3d3823410a
4
- data.tar.gz: db4d6c96ebfb8d3ee16f3d8286d11faad2105b349fbb83e995d442b876ea9e62
3
+ metadata.gz: d10fff2eec2850ddf264d8c718160e17d05a1d04c2c0b62cab1c4fb6f6cecf0d
4
+ data.tar.gz: d10b0bcbd89d7e63c3e27c6ae679d44ebae9f6287174f078205bd44e6fb402b2
5
5
  SHA512:
6
- metadata.gz: 85acd4700922566f23a71d816fe508277a3ee060f06571df9856155b312682c1bd62519af0c908dba1dab7ba645785459c9f908d122eb88297a673eb9f197f83
7
- data.tar.gz: 8abd9907f994ee4ae10dcb4bca7f01d83b7f02d606f8bedb532da584df561eb8afbdfc962db53734449e1e5c360a90abda64870b69e1bce913d645e38411cedb
6
+ metadata.gz: 3e1d5c33c1fd71d8e1d927db48fbf8a68d3479736752c78ff057255e32c29886c2ef511797520b1ce6d22272e470ac97c60edc6519ec95b3a1a300344a2f388f
7
+ data.tar.gz: f2f7a5ed46507f91872d5ac798cbf2811e460f795a57f11acd71d367e9545479934b885300584976641aa2474777e8a5310be90b04ad1f474aea2d7b9f0d7bd7
data/CHANGELOG.md CHANGED
@@ -1,19 +1,14 @@
1
1
  ## Unreleased
2
2
 
3
3
  ## v4.0.0
4
-
5
4
  Stops loading the Rails engine automatically. If you are using the engine, you need to require it explicitly by adding `require 'arturo/engine'` to `application.rb`.
6
-
7
5
  Adds support for Ruby 3.3.
8
-
9
6
  Returns false immediately for `feature_enabled_for?` calls with `nil` recipients.
10
7
 
11
8
  ## v3.0.0
12
9
 
13
10
  Converts the Feature model into a mixin that should be used by services via a model generator.
14
-
15
11
  Brings back the `warm_cache!` method.
16
-
17
12
  Adds support for Rails 7.1.
18
13
 
19
14
  ## v2.8.0
data/README.md CHANGED
@@ -43,7 +43,7 @@ $(function() {
43
43
  updatePostingsList();
44
44
  }
45
45
  });
46
- ```
46
+ ````
47
47
 
48
48
  Trish uses Arturo's Controller filters to control who has access to
49
49
  the feature:
@@ -70,6 +70,7 @@ feature and deploy it to all users.
70
70
 
71
71
  ## Installation
72
72
 
73
+
73
74
  ```Ruby
74
75
  gem 'arturo'
75
76
  ```
@@ -100,7 +101,7 @@ rake db:migrate
100
101
 
101
102
  #### Edit the Feature model
102
103
 
103
- By default, the generated model `Arturo::Feature` inherits from `ActiveRecord::Base`. However, if you’re using multiple databases your models should inherit from an abstract class that specifies a database connection, not directly from `ActiveRecord::Base`. Update the generated model in `app/models/arturo/feature.rb` to make it use a correct database.
104
+ By default, the generated model `Arturo::Feature` inherits from `ActiveRecord::Base`. However, if you’re using multiple databases your models should inherit from an abstract class that specifies a database connection, not directly from `ActiveRecord::Base`. Update the generated model in `app/models/arturo/feature.rb` to make it use a correct database.
104
105
 
105
106
  ##### Initializer
106
107
 
@@ -319,7 +320,7 @@ initializer:
319
320
  ```Ruby
320
321
  Arturo::Feature.extend(Arturo::FeatureCaching)
321
322
  Arturo::Feature.cache_ttl = 10.minutes
322
- ```
323
+ ````
323
324
 
324
325
  You can also warm the cache on startup:
325
326
 
data/lib/arturo/engine.rb CHANGED
@@ -9,11 +9,13 @@ module Arturo
9
9
  include Arturo::FeatureAvailability
10
10
  include Arturo::ControllerFilters
11
11
  if respond_to?(:helper)
12
- helper Arturo::FeatureAvailability
13
- helper Arturo::FeatureManagement
12
+ helper Arturo::FeatureAvailability
13
+ helper Arturo::FeatureManagement
14
14
  end
15
15
  end
16
16
 
17
- config.paths['app/controllers'] = []
17
+ root = File.expand_path("../../..", __FILE__)
18
+ config.autoload_paths = ["#{root}/app/helpers", "#{root}/app/controllers"]
19
+ config.eager_load_paths = []
18
20
  end
19
21
  end
@@ -1,4 +1,4 @@
1
1
  # frozen_string_literal: true
2
2
  module Arturo
3
- VERSION = '3.0.2.pre.2'
3
+ VERSION = '4.0.0'
4
4
  end
data/lib/arturo.rb CHANGED
@@ -6,7 +6,6 @@ require_relative 'arturo/feature_methods'
6
6
  require_relative 'arturo/feature_availability'
7
7
  require_relative 'arturo/feature_management'
8
8
  require_relative 'arturo/feature_caching'
9
- require_relative 'arturo/engine' if defined?(Rails)
10
9
 
11
10
  module Arturo
12
11
  class << self
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: arturo
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.2.pre.2
4
+ version: 4.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - James A. Rosen
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-04-16 00:00:00.000000000 Z
11
+ date: 2024-04-12 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activerecord